diff --git a/README.md b/README.md index c3891c5d..995688ee 100644 --- a/README.md +++ b/README.md @@ -1,3 +1,5 @@ +[![Build Status](https://travis-ci.org/ax5ui/ax5ui-kernel.svg?branch=master)](https://travis-ci.org/ax5ui/ax5ui-kernel) + ![ax5ui preview](src/preview.png) # What is it!! diff --git a/dist/ax5ui.all.css b/dist/ax5ui.all.css index 7f46e1eb..324e8aef 100644 --- a/dist/ax5ui.all.css +++ b/dist/ax5ui.all.css @@ -1,6 +1,6 @@ @-webkit-keyframes ax-dialog{0%{opacity:0.0;-webkit-transform:scale(1)}1%{opacity:0.0;-webkit-transform:scale(0.3)}100%{opacity:1.0;-webkit-transform:scale(1)}}@-moz-keyframes ax-dialog{0%{opacity:0.0;-moz-transform:scale(1)}1%{opacity:0.0;-moz-transform:scale(0.3)}100%{opacity:1.0;-moz-transform:scale(1)}}@keyframes ax-dialog{0%{opacity:0.0;-webkit-transform:scale(1);-moz-transform:scale(1);-ms-transform:scale(1);-o-transform:scale(1);transform:scale(1)}1%{opacity:0.0;-webkit-transform:scale(0.3);-moz-transform:scale(0.3);-ms-transform:scale(0.3);-o-transform:scale(0.3);transform:scale(0.3)}100%{opacity:1.0;-webkit-transform:scale(1);-moz-transform:scale(1);-ms-transform:scale(1);-o-transform:scale(1);transform:scale(1)}}@-webkit-keyframes ax-dialog-destroy{from{-webkit-transform:scale(1);opacity:1.0}to{-webkit-transform:scale(0.5);opacity:0.0}}@-moz-keyframes ax-dialog-destroy{from{-moz-transform:scale(1);opacity:1.0}to{-moz-transform:scale(0.5);opacity:0.0}}@keyframes ax-dialog-destroy{from{-webkit-transform:scale(1);-moz-transform:scale(1);-ms-transform:scale(1);-o-transform:scale(1);transform:scale(1);opacity:1.0}to{-webkit-transform:scale(0.5);-moz-transform:scale(0.5);-ms-transform:scale(0.5);-o-transform:scale(0.5);transform:scale(0.5);opacity:0.0}}.ax5-ui-dialog{-webkit-animation:ax-dialog .15s cubic-bezier(0.645, 0.045, 0.355, 1);-moz-animation:ax-dialog .15s cubic-bezier(0.645, 0.045, 0.355, 1);animation:ax-dialog .15s cubic-bezier(0.645, 0.045, 0.355, 1);-webkit-transform:translateZ(0);-moz-transform:translateZ(0);-ms-transform:translateZ(0);-o-transform:translateZ(0);transform:translateZ(0);box-sizing:border-box;background-color:#fff;border:1px solid #ddd;border-radius:4px;box-shadow:0px 0px 3px 0px rgba(0,0,0,0.175);z-index:2000;position:fixed;left:0px;top:0px;overflow:hidden;border:1px solid #ddd}.ax5-ui-dialog .ax-dialog-header{font-weight:600;padding:10px 15px;border-bottom:1px solid transparent}.ax5-ui-dialog .ax-dialog-header .badge{font-size:0.8em;color:#f5f5f5;background-color:#333}.ax5-ui-dialog .ax-dialog-body{padding:15px;text-align:center}.ax5-ui-dialog .ax-dialog-body .ax-dialog-msg{padding-top:15px;padding-bottom:15px}.ax5-ui-dialog .ax-dialog-body .ax-dialog-prompt{text-align:left;padding-bottom:7.5px}.ax5-ui-dialog .ax-dialog-body .ax-dialog-buttons{margin-top:15px}.ax5-ui-dialog .ax-dialog-body .ax-dialog-buttons button:not(:last-child){margin-right:3px}.ax5-ui-dialog .ax-dialog-header{color:#333;background:#f5f5f5}.ax5-ui-dialog .ax-dialog-header .badge{color:#f5f5f5;background-color:#333}.ax5-ui-dialog.primary{border:1px solid #ddd}.ax5-ui-dialog.primary .ax-dialog-header{color:#fff;background:#337ab7}.ax5-ui-dialog.primary .ax-dialog-header .badge{color:#337ab7;background-color:#fff}.ax5-ui-dialog.success{border:1px solid #ddd}.ax5-ui-dialog.success .ax-dialog-header{color:#3c763d;background:#dff0d8}.ax5-ui-dialog.success .ax-dialog-header .badge{color:#dff0d8;background-color:#3c763d}.ax5-ui-dialog.info{border:1px solid #ddd}.ax5-ui-dialog.info .ax-dialog-header{color:#31708f;background:#d9edf7}.ax5-ui-dialog.info .ax-dialog-header .badge{color:#d9edf7;background-color:#31708f}.ax5-ui-dialog.warning{border:1px solid #ddd}.ax5-ui-dialog.warning .ax-dialog-header{color:#8a6d3b;background:#fcf8e3}.ax5-ui-dialog.warning .ax-dialog-header .badge{color:#fcf8e3;background-color:#8a6d3b}.ax5-ui-dialog.danger{border:1px solid #ddd}.ax5-ui-dialog.danger .ax-dialog-header{color:#a94442;background:#f2dede}.ax5-ui-dialog.danger .ax-dialog-header .badge{color:#f2dede;background-color:#a94442}.ax5-ui-dialog.destroy{-webkit-animation:ax-dialog-destroy .15s cubic-bezier(0.645, 0.045, 0.355, 1) forwards;-moz-animation:ax-dialog-destroy .15s cubic-bezier(0.645, 0.045, 0.355, 1) forwards;animation:ax-dialog-destroy .15s cubic-bezier(0.645, 0.045, 0.355, 1) forwards} -@-webkit-keyframes ax-mask{from{opacity:0.0}to{opacity:.6}}@-moz-keyframes ax-mask{from{opacity:0.0}to{opacity:.6}}@keyframes ax-mask{from{opacity:0.0}to{opacity:.6}}.ax-masking{-webkit-filter:blur(3px);-webkit-transform:scale(0.96);-moz-transform:scale(0.96);-ms-transform:scale(0.96);-o-transform:scale(0.96);transform:scale(0.96);-webkit-transform:translateZ(0);-moz-transform:translateZ(0);-ms-transform:translateZ(0);-o-transform:translateZ(0);transform:translateZ(0)}.ax-mask{z-index:1000;position:fixed;left:0px;top:0px;width:100%;height:100%}.ax-mask .ax-mask-bg{z-index:1;position:absolute;left:0px;top:0px;width:100%;height:100%;background:#000;opacity:.6}.ax-mask .ax-mask-content{z-index:2;position:absolute;left:0px;top:0px;width:100%;height:100%;display:table;vertical-align:middle;text-align:center;color:#fff;text-shadow:0px 1px 0px #000}.ax-mask .ax-mask-content *{color:inherit}.ax-mask .ax-mask-content div{display:table-cell;vertical-align:middle;text-align:center} +@-webkit-keyframes ax-mask{from{opacity:0.0}to{opacity:.6}}@-moz-keyframes ax-mask{from{opacity:0.0}to{opacity:.6}}@keyframes ax-mask{from{opacity:0.0}to{opacity:.6}}@-webkit-keyframes ax-mask-fade-out{from{opacity:.6}to{opacity:0.0}}@-moz-keyframes ax-mask-fade-out{from{opacity:.6}to{opacity:0.0}}@keyframes ax-mask-fade-out{from{opacity:.6}to{opacity:0.0}}.ax-masking{-webkit-filter:blur(3px);-webkit-transform:scale(0.96);-moz-transform:scale(0.96);-ms-transform:scale(0.96);-o-transform:scale(0.96);transform:scale(0.96);-webkit-transform:translateZ(0);-moz-transform:translateZ(0);-ms-transform:translateZ(0);-o-transform:translateZ(0);transform:translateZ(0)}.ax-mask{z-index:1000;position:fixed;left:0px;top:0px;width:100%;height:100%}.ax-mask .ax-mask-bg{z-index:1;position:absolute;left:0px;top:0px;width:100%;height:100%;background:#000;opacity:.6}.ax-mask .ax-mask-content{z-index:2;position:absolute;left:0px;top:0px;width:100%;height:100%;display:table;vertical-align:middle;text-align:center;color:#fff;text-shadow:0px 1px 0px #000}.ax-mask .ax-mask-content *{color:inherit}.ax-mask .ax-mask-content div{display:table-cell;vertical-align:middle;text-align:center}.ax-mask.fade-out{-webkit-animation:ax-mask-fade-out .25s;-moz-animation:ax-mask-fade-out .25s;animation:ax-mask-fade-out .25s;opacity:0.0} @-webkit-keyframes ax-toast-bottom{from{-webkit-transform:translateY(-100px) scale(0.7)}to{-webkit-transform:translateY(0px) scale(1)}}@-moz-keyframes ax-toast-bottom{from{-moz-transform:translateY(-100px) scale(0.7)}to{-moz-transform:translateY(0px) scale(1)}}@keyframes ax-toast-bottom{from{-webkit-transform:translateY(-100px) scale(0.7);-moz-transform:translateY(-100px) scale(0.7);-ms-transform:translateY(-100px) scale(0.7);-o-transform:translateY(-100px) scale(0.7);transform:translateY(-100px) scale(0.7)}to{-webkit-transform:translateY(0px) scale(1);-moz-transform:translateY(0px) scale(1);-ms-transform:translateY(0px) scale(1);-o-transform:translateY(0px) scale(1);transform:translateY(0px) scale(1)}}@-webkit-keyframes ax-toast-top{from{-webkit-transform:translateY(100px) scale(0.7)}to{-webkit-transform:translateY(0px) scale(1)}}@-moz-keyframes ax-toast-top{from{-moz-transform:translateY(100px) scale(0.7)}to{-moz-transform:translateY(0px) scale(1)}}@keyframes ax-toast-top{from{-webkit-transform:translateY(100px) scale(0.7);-moz-transform:translateY(100px) scale(0.7);-ms-transform:translateY(100px) scale(0.7);-o-transform:translateY(100px) scale(0.7);transform:translateY(100px) scale(0.7)}to{-webkit-transform:translateY(0px) scale(1);-moz-transform:translateY(0px) scale(1);-ms-transform:translateY(0px) scale(1);-o-transform:translateY(0px) scale(1);transform:translateY(0px) scale(1)}}@-webkit-keyframes ax-toast-removed-bottom{from{-webkit-transform:translateY(0px);opacity:1.0}to{-webkit-transform:translateY(10px) scale(0.7);opacity:0.0}}@-moz-keyframes ax-toast-removed-bottom{from{-moz-transform:translateY(0px);opacity:1.0}to{-moz-transform:translateY(10px) scale(0.7);opacity:0.0}}@keyframes ax-toast-removed-bottom{from{-webkit-transform:translateY(0px);-moz-transform:translateY(0px);-ms-transform:translateY(0px);-o-transform:translateY(0px);transform:translateY(0px);opacity:1.0}to{-webkit-transform:translateY(10px) scale(0.7);-moz-transform:translateY(10px) scale(0.7);-ms-transform:translateY(10px) scale(0.7);-o-transform:translateY(10px) scale(0.7);transform:translateY(10px) scale(0.7);opacity:0.0}}@-webkit-keyframes ax-toast-removed-top{from{-webkit-transform:translateY(0px);opacity:1.0}to{-webkit-transform:translateY(-10px) scale(0.7);opacity:0.0}}@-moz-keyframes ax-toast-removed-top{from{-moz-transform:translateY(0px);opacity:1.0}to{-moz-transform:translateY(-10px) scale(0.7);opacity:0.0}}@keyframes ax-toast-removed-top{from{-webkit-transform:translateY(0px);-moz-transform:translateY(0px);-ms-transform:translateY(0px);-o-transform:translateY(0px);transform:translateY(0px);opacity:1.0}to{-webkit-transform:translateY(-10px) scale(0.7);-moz-transform:translateY(-10px) scale(0.7);-ms-transform:translateY(-10px) scale(0.7);-o-transform:translateY(-10px) scale(0.7);transform:translateY(-10px) scale(0.7);opacity:0.0}}@-webkit-keyframes ax-toast-destroy{from{-webkit-transform:scale(1);opacity:1.0}to{-webkit-transform:scale(1.5);opacity:0.0}}@-moz-keyframes ax-toast-destroy{from{-moz-transform:scale(1);opacity:1.0}to{-moz-transform:scale(1.5);opacity:0.0}}@keyframes ax-toast-destroy{from{-webkit-transform:scale(1);-moz-transform:scale(1);-ms-transform:scale(1);-o-transform:scale(1);transform:scale(1);opacity:1.0}to{-webkit-transform:scale(1.5);-moz-transform:scale(1.5);-ms-transform:scale(1.5);-o-transform:scale(1.5);transform:scale(1.5);opacity:0.0}}.ax5-ui-toast-container{z-index:2000;position:fixed;width:auto;padding:10px}.ax5-ui-toast-container .ax5-ui-toast{box-sizing:border-box;border:1px solid gray;opacity:.9;border-radius:8px;box-shadow:0px 0px 5px 0px rgba(0,0,0,0.175);position:relative;margin:5px 0px 5px 0px;display:table;padding:6px;-webkit-transition:all .3s ease-in-out;-moz-transition:all .3s ease-in-out;transition:all .3s ease-in-out;background:#fff;color:#333}.ax5-ui-toast-container .ax5-ui-toast .ax-toast-icon{display:table-cell;padding:6px;text-align:left;font-size:24px;width:24px;vertical-align:middle}.ax5-ui-toast-container .ax5-ui-toast .ax-toast-body{display:table-cell;padding:6px;text-align:left;vertical-align:middle}.ax5-ui-toast-container .ax5-ui-toast .ax-toast-buttons{display:table-cell;padding:6px;text-align:right;vertical-align:middle}.ax5-ui-toast-container .ax5-ui-toast .ax-toast-buttons button:not(:last-child){margin-right:3px}.ax5-ui-toast-container .ax5-ui-toast .ax-toast-close{display:table-cell;padding:6px;text-align:right;vertical-align:top;text-decoration:none;cursor:pointer}.ax5-ui-toast-container .ax5-ui-toast .ax-toast-icon{color:#333}.ax5-ui-toast-container .ax5-ui-toast .ax-toast-close{color:#333}.ax5-ui-toast-container .ax5-ui-toast.primary{background:#fff;color:#337ab7}.ax5-ui-toast-container .ax5-ui-toast.primary .ax-toast-icon{color:#337ab7}.ax5-ui-toast-container .ax5-ui-toast.primary .ax-toast-close{color:#337ab7}.ax5-ui-toast-container .ax5-ui-toast.success{background:#fff;color:#5cb85c}.ax5-ui-toast-container .ax5-ui-toast.success .ax-toast-icon{color:#5cb85c}.ax5-ui-toast-container .ax5-ui-toast.success .ax-toast-close{color:#5cb85c}.ax5-ui-toast-container .ax5-ui-toast.info{background:#fff;color:#5bc0de}.ax5-ui-toast-container .ax5-ui-toast.info .ax-toast-icon{color:#5bc0de}.ax5-ui-toast-container .ax5-ui-toast.info .ax-toast-close{color:#5bc0de}.ax5-ui-toast-container .ax5-ui-toast.warning{background:#fff;color:#f0ad4e}.ax5-ui-toast-container .ax5-ui-toast.warning .ax-toast-icon{color:#f0ad4e}.ax5-ui-toast-container .ax5-ui-toast.warning .ax-toast-close{color:#f0ad4e}.ax5-ui-toast-container .ax5-ui-toast.danger{background:#fff;color:#d9534f}.ax5-ui-toast-container .ax5-ui-toast.danger .ax-toast-icon{color:#d9534f}.ax5-ui-toast-container .ax5-ui-toast.danger .ax-toast-close{color:#d9534f}.ax5-ui-toast-container.bottom-left{left:0;bottom:0}.ax5-ui-toast-container.bottom-left .ax5-ui-toast{-webkit-animation:ax-toast-top .3s cubic-bezier(0.86, 0, 0.07, 1);-moz-animation:ax-toast-top .3s cubic-bezier(0.86, 0, 0.07, 1);animation:ax-toast-top .3s cubic-bezier(0.86, 0, 0.07, 1)}.ax5-ui-toast-container.bottom-left .ax5-ui-toast.removed{-webkit-animation:ax-toast-removed-bottom .3s ease forwards;-moz-animation:ax-toast-removed-bottom .3s ease forwards;animation:ax-toast-removed-bottom .3s ease forwards}.ax5-ui-toast-container.bottom-left .ax5-ui-toast.destroy{-webkit-animation:ax-toast-destroy .3s ease forwards;-moz-animation:ax-toast-destroy .3s ease forwards;animation:ax-toast-destroy .3s ease forwards}.ax5-ui-toast-container.bottom-right{right:0;bottom:0}.ax5-ui-toast-container.bottom-right .ax5-ui-toast{-webkit-animation:ax-toast-top .3s cubic-bezier(0.86, 0, 0.07, 1);-moz-animation:ax-toast-top .3s cubic-bezier(0.86, 0, 0.07, 1);animation:ax-toast-top .3s cubic-bezier(0.86, 0, 0.07, 1)}.ax5-ui-toast-container.bottom-right .ax5-ui-toast.removed{-webkit-animation:ax-toast-removed-bottom .3s ease forwards;-moz-animation:ax-toast-removed-bottom .3s ease forwards;animation:ax-toast-removed-bottom .3s ease forwards}.ax5-ui-toast-container.bottom-right .ax5-ui-toast.destroy{-webkit-animation:ax-toast-destroy .3s ease forwards;-moz-animation:ax-toast-destroy .3s ease forwards;animation:ax-toast-destroy .3s ease forwards}.ax5-ui-toast-container.top-left{left:0;top:0}.ax5-ui-toast-container.top-left .ax5-ui-toast{-webkit-animation:ax-toast-bottom .3s cubic-bezier(0.86, 0, 0.07, 1);-moz-animation:ax-toast-bottom .3s cubic-bezier(0.86, 0, 0.07, 1);animation:ax-toast-bottom .3s cubic-bezier(0.86, 0, 0.07, 1)}.ax5-ui-toast-container.top-left .ax5-ui-toast.removed{-webkit-animation:ax-toast-removed-top .3s ease forwards;-moz-animation:ax-toast-removed-top .3s ease forwards;animation:ax-toast-removed-top .3s ease forwards}.ax5-ui-toast-container.top-left .ax5-ui-toast.destroy{-webkit-animation:ax-toast-destroy .3s ease forwards;-moz-animation:ax-toast-destroy .3s ease forwards;animation:ax-toast-destroy .3s ease forwards}.ax5-ui-toast-container.top-right{right:0;top:0}.ax5-ui-toast-container.top-right .ax5-ui-toast{-webkit-animation:ax-toast-bottom .3s cubic-bezier(0.86, 0, 0.07, 1);-moz-animation:ax-toast-bottom .3s cubic-bezier(0.86, 0, 0.07, 1);animation:ax-toast-bottom .3s cubic-bezier(0.86, 0, 0.07, 1)}.ax5-ui-toast-container.top-right .ax5-ui-toast.removed{-webkit-animation:ax-toast-removed-top .3s ease forwards;-moz-animation:ax-toast-removed-top .3s ease forwards;animation:ax-toast-removed-top .3s ease forwards}.ax5-ui-toast-container.top-right .ax5-ui-toast.destroy{-webkit-animation:ax-toast-destroy .3s ease forwards;-moz-animation:ax-toast-destroy .3s ease forwards;animation:ax-toast-destroy .3s ease forwards} @@ -19,7 +19,7 @@ @-webkit-keyframes ax-media-viewer{from{-webkit-transform:translateY(-10%) scaleY(0);opacity:0}to{-webkit-transform:translateY(0%) scaleY(1);opacity:1}}@-moz-keyframes ax-media-viewer{from{-moz-transform:translateY(-10%) scaleY(0);opacity:0}to{-moz-transform:translateY(0%) scaleY(1);opacity:1}}@keyframes ax-media-viewer{from{-webkit-transform:translateY(-10%) scaleY(0);-moz-transform:translateY(-10%) scaleY(0);-ms-transform:translateY(-10%) scaleY(0);-o-transform:translateY(-10%) scaleY(0);transform:translateY(-10%) scaleY(0);opacity:0}to{-webkit-transform:translateY(0%) scaleY(1);-moz-transform:translateY(0%) scaleY(1);-ms-transform:translateY(0%) scaleY(1);-o-transform:translateY(0%) scaleY(1);transform:translateY(0%) scaleY(1);opacity:1}}@-webkit-keyframes ax-media-viewer-option-destroy{from{-webkit-transform:translateY(0%) scaleY(1);opacity:1}to{-webkit-transform:translateY(-10%) scaleY(0);opacity:0}}@-moz-keyframes ax-media-viewer-option-destroy{from{-moz-transform:translateY(0%) scaleY(1);opacity:1}to{-moz-transform:translateY(-10%) scaleY(0);opacity:0}}@keyframes ax-media-viewer-option-destroy{from{-webkit-transform:translateY(0%) scaleY(1);-moz-transform:translateY(0%) scaleY(1);-ms-transform:translateY(0%) scaleY(1);-o-transform:translateY(0%) scaleY(1);transform:translateY(0%) scaleY(1);opacity:1}to{-webkit-transform:translateY(-10%) scaleY(0);-moz-transform:translateY(-10%) scaleY(0);-ms-transform:translateY(-10%) scaleY(0);-o-transform:translateY(-10%) scaleY(0);transform:translateY(-10%) scaleY(0);opacity:0}}[data-ax5-ui-media-viewer]{position:relative;overflow:hidden}[data-ax5-ui-media-viewer] *{box-sizing:border-box}[data-ax5-ui-media-viewer] [data-media-viewer-els="viewer-holder"]{position:relative}[data-ax5-ui-media-viewer] [data-media-viewer-els="viewer"]{position:absolute;left:0;top:0;overflow:hidden;text-align:center;width:100%;height:100%}[data-ax5-ui-media-viewer] [data-media-viewer-els="viewer"] img{position:absolute;left:0;top:0;border:0}[data-ax5-ui-media-viewer] [data-media-viewer-els="viewer-loading"]{display:none;position:absolute;width:100%;height:100%;left:0px;top:0px;box-sizing:border-box;background:#eee}[data-ax5-ui-media-viewer] [data-media-viewer-els="viewer-loading"] .ax5-ui-media-viewer-loading-holder{display:table;width:100%;height:100%}[data-ax5-ui-media-viewer] [data-media-viewer-els="viewer-loading"] .ax5-ui-media-viewer-loading-holder .ax5-ui-media-viewer-loading-cell{display:table-cell;text-align:center;vertical-align:middle;height:100%}[data-ax5-ui-media-viewer] [data-media-viewer-els="media-list-holder"]{margin:10px 0px;display:table;table-layout:fixed;width:100%;border-collapse:collapse}[data-ax5-ui-media-viewer] [data-media-viewer-els="media-list-holder"] [data-media-viewer-els]{display:table-cell;vertical-align:middle}[data-ax5-ui-media-viewer] [data-media-viewer-els="media-list-holder"] [data-media-viewer-els="media-list-prev-handle"],[data-ax5-ui-media-viewer] [data-media-viewer-els="media-list-holder"] [data-media-viewer-els="media-list-next-handle"]{text-align:center;font-size:20px;cursor:pointer}[data-ax5-ui-media-viewer] [data-media-viewer-els="media-list-holder"] [data-media-viewer-els="media-list-prev-handle"]:hover,[data-ax5-ui-media-viewer] [data-media-viewer-els="media-list-holder"] [data-media-viewer-els="media-list-next-handle"]:hover{color:#337ab7}[data-ax5-ui-media-viewer] [data-media-viewer-els="media-list-holder"] [data-media-viewer-els="media-list"]{overflow:hidden;position:relative}[data-ax5-ui-media-viewer] [data-media-viewer-els="media-list-holder"] [data-media-viewer-els="media-list"] [data-media-viewer-els="media-list-table"]{position:absolute;left:0px;top:0px;display:table;border-collapse:collapse}[data-ax5-ui-media-viewer] [data-media-viewer-els="media-list-holder"] [data-media-viewer-els="media-list"] [data-media-viewer-els="media-list-table"] [data-media-viewer-els="media-list-table-td"]{display:table-cell;vertical-align:middle;padding:0px 1px}[data-ax5-ui-media-viewer] [data-media-viewer-els="media-list-holder"] [data-media-viewer-els="media-list"] [data-media-viewer-els="media-list-table"] [data-media-thumbnail]{overflow:hidden;cursor:pointer;border:2px solid;border-color:transparent;overflow:hidden}[data-ax5-ui-media-viewer] [data-media-viewer-els="media-list-holder"] [data-media-viewer-els="media-list"] [data-media-viewer-els="media-list-table"] [data-media-thumbnail]:hover,[data-ax5-ui-media-viewer] [data-media-viewer-els="media-list-holder"] [data-media-viewer-els="media-list"] [data-media-viewer-els="media-list-table"] [data-media-thumbnail].selected{border-color:#ccc}[data-ax5-ui-media-viewer] [data-media-viewer-els="media-list-holder"] [data-media-viewer-els="media-list"] [data-media-viewer-els="media-list-table"] [data-media-thumbnail] [data-media-thumbnail-image]{width:100%;height:100%}[data-ax5-ui-media-viewer] [data-media-viewer-els="media-list-holder"] [data-media-viewer-els="media-list"] [data-media-viewer-els="media-list-table"] [data-media-thumbnail] [data-media-thumbnail-video]{display:table-cell;text-align:center;vertical-align:middle;background:#eee}[data-ax5-ui-media-viewer].default [data-media-viewer-els="viewer-loading"]{background:#eee}[data-ax5-ui-media-viewer].default [data-media-viewer-els="media-list-holder"] [data-media-viewer-els="media-list-prev-handle"]:hover,[data-ax5-ui-media-viewer].default [data-media-viewer-els="media-list-holder"] [data-media-viewer-els="media-list-next-handle"]:hover{color:#555}[data-ax5-ui-media-viewer].default [data-media-viewer-els="media-list-holder"] [data-media-viewer-els="media-list"] [data-media-viewer-els="media-list-table"] [data-media-thumbnail]:hover,[data-ax5-ui-media-viewer].default [data-media-viewer-els="media-list-holder"] [data-media-viewer-els="media-list"] [data-media-viewer-els="media-list-table"] [data-media-thumbnail].selected{border-color:#ccc}[data-ax5-ui-media-viewer].primary [data-media-viewer-els="viewer-loading"]{background:#eee}[data-ax5-ui-media-viewer].primary [data-media-viewer-els="media-list-holder"] [data-media-viewer-els="media-list-prev-handle"]:hover,[data-ax5-ui-media-viewer].primary [data-media-viewer-els="media-list-holder"] [data-media-viewer-els="media-list-next-handle"]:hover{color:#337ab7}[data-ax5-ui-media-viewer].primary [data-media-viewer-els="media-list-holder"] [data-media-viewer-els="media-list"] [data-media-viewer-els="media-list-table"] [data-media-thumbnail]:hover,[data-ax5-ui-media-viewer].primary [data-media-viewer-els="media-list-holder"] [data-media-viewer-els="media-list"] [data-media-viewer-els="media-list-table"] [data-media-thumbnail].selected{border-color:#337ab7}[data-ax5-ui-media-viewer].success [data-media-viewer-els="viewer-loading"]{background:#eee}[data-ax5-ui-media-viewer].success [data-media-viewer-els="media-list-holder"] [data-media-viewer-els="media-list-prev-handle"]:hover,[data-ax5-ui-media-viewer].success [data-media-viewer-els="media-list-holder"] [data-media-viewer-els="media-list-next-handle"]:hover{color:#5cb85c}[data-ax5-ui-media-viewer].success [data-media-viewer-els="media-list-holder"] [data-media-viewer-els="media-list"] [data-media-viewer-els="media-list-table"] [data-media-thumbnail]:hover,[data-ax5-ui-media-viewer].success [data-media-viewer-els="media-list-holder"] [data-media-viewer-els="media-list"] [data-media-viewer-els="media-list-table"] [data-media-thumbnail].selected{border-color:#5cb85c}[data-ax5-ui-media-viewer].info [data-media-viewer-els="viewer-loading"]{background:#eee}[data-ax5-ui-media-viewer].info [data-media-viewer-els="media-list-holder"] [data-media-viewer-els="media-list-prev-handle"]:hover,[data-ax5-ui-media-viewer].info [data-media-viewer-els="media-list-holder"] [data-media-viewer-els="media-list-next-handle"]:hover{color:#5bc0de}[data-ax5-ui-media-viewer].info [data-media-viewer-els="media-list-holder"] [data-media-viewer-els="media-list"] [data-media-viewer-els="media-list-table"] [data-media-thumbnail]:hover,[data-ax5-ui-media-viewer].info [data-media-viewer-els="media-list-holder"] [data-media-viewer-els="media-list"] [data-media-viewer-els="media-list-table"] [data-media-thumbnail].selected{border-color:#5bc0de}[data-ax5-ui-media-viewer].warning [data-media-viewer-els="viewer-loading"]{background:#eee}[data-ax5-ui-media-viewer].warning [data-media-viewer-els="media-list-holder"] [data-media-viewer-els="media-list-prev-handle"]:hover,[data-ax5-ui-media-viewer].warning [data-media-viewer-els="media-list-holder"] [data-media-viewer-els="media-list-next-handle"]:hover{color:#f0ad4e}[data-ax5-ui-media-viewer].warning [data-media-viewer-els="media-list-holder"] [data-media-viewer-els="media-list"] [data-media-viewer-els="media-list-table"] [data-media-thumbnail]:hover,[data-ax5-ui-media-viewer].warning [data-media-viewer-els="media-list-holder"] [data-media-viewer-els="media-list"] [data-media-viewer-els="media-list-table"] [data-media-thumbnail].selected{border-color:#f0ad4e}[data-ax5-ui-media-viewer].danger [data-media-viewer-els="viewer-loading"]{background:#eee}[data-ax5-ui-media-viewer].danger [data-media-viewer-els="media-list-holder"] [data-media-viewer-els="media-list-prev-handle"]:hover,[data-ax5-ui-media-viewer].danger [data-media-viewer-els="media-list-holder"] [data-media-viewer-els="media-list-next-handle"]:hover{color:#d9534f}[data-ax5-ui-media-viewer].danger [data-media-viewer-els="media-list-holder"] [data-media-viewer-els="media-list"] [data-media-viewer-els="media-list-table"] [data-media-thumbnail]:hover,[data-ax5-ui-media-viewer].danger [data-media-viewer-els="media-list-holder"] [data-media-viewer-els="media-list"] [data-media-viewer-els="media-list-table"] [data-media-thumbnail].selected{border-color:#d9534f} -@-webkit-keyframes ax-progressbox{0%{opacity:0.0;-webkit-transform:scale(0)}100%{opacity:1.0;-webkit-transform:scale(1)}}@-moz-keyframes ax-progressbox{0%{opacity:0.0;-moz-transform:scale(0)}100%{opacity:1.0;-moz-transform:scale(1)}}@keyframes ax-progressbox{0%{opacity:0.0;-webkit-transform:scale(0);-moz-transform:scale(0);-ms-transform:scale(0);-o-transform:scale(0);transform:scale(0)}100%{opacity:1.0;-webkit-transform:scale(1);-moz-transform:scale(1);-ms-transform:scale(1);-o-transform:scale(1);transform:scale(1)}}@-webkit-keyframes ax-progressbox-destroy{from{-webkit-transform:scale(1);opacity:1.0}to{-webkit-transform:scale(0.95);opacity:0.0}}@-moz-keyframes ax-progressbox-destroy{from{-moz-transform:scale(1);opacity:1.0}to{-moz-transform:scale(0.95);opacity:0.0}}@keyframes ax-progressbox-destroy{from{-webkit-transform:scale(1);-moz-transform:scale(1);-ms-transform:scale(1);-o-transform:scale(1);transform:scale(1);opacity:1.0}to{-webkit-transform:scale(0.95);-moz-transform:scale(0.95);-ms-transform:scale(0.95);-o-transform:scale(0.95);transform:scale(0.95);opacity:0.0}}[data-ax5uploader]{position:relative}[data-ax5uploader] [data-ax5uploader-button="selector"]{position:relative}[data-ax5uploader-uploaded-box]{background:#f3f3f3;border:1px solid #ccc;border-radius:5px;margin:10px 0;padding:7px;min-height:100px}[data-ax5uploader-uploaded-box][data-ax5uploader-uploaded-box="inline"]{margin:10px 0}[data-ax5uploader-uploaded-box][data-ax5uploader-uploaded-box="inline"]:after{content:" ";display:block;clear:both}[data-ax5uploader-uploaded-box][data-ax5uploader-uploaded-box="inline"] [data-ax5uploader-uploaded-item]{display:block;float:left;color:#333;border:0px solid #ccc;border-radius:4px;padding:6px 12px;margin:3px;background:#fff}[data-ax5uploader-uploaded-box][data-ax5uploader-uploaded-box="inline"] [data-ax5uploader-uploaded-item]:hover,[data-ax5uploader-uploaded-box][data-ax5uploader-uploaded-box="inline"] [data-ax5uploader-uploaded-item]:focus,[data-ax5uploader-uploaded-box][data-ax5uploader-uploaded-box="inline"] [data-ax5uploader-uploaded-item].focus{color:#333;text-decoration:none}[data-ax5uploader-uploaded-box][data-ax5uploader-uploaded-box="inline"] [data-ax5uploader-uploaded-item]:active,[data-ax5uploader-uploaded-box][data-ax5uploader-uploaded-box="inline"] [data-ax5uploader-uploaded-item].active{outline:0;background-image:none;box-shadow:inset 0 3px 5px rgba(0,0,0,0.125)}[data-ax5uploader-uploaded-box][data-ax5uploader-uploaded-box="inline"] [data-ax5uploader-uploaded-item].disabled,[data-ax5uploader-uploaded-box][data-ax5uploader-uploaded-box="inline"] [data-ax5uploader-uploaded-item][disabled],fieldset[disabled] [data-ax5uploader-uploaded-box][data-ax5uploader-uploaded-box="inline"] [data-ax5uploader-uploaded-item]{cursor:not-allowed;opacity:.65;box-shadow:none}[data-ax5uploader-uploaded-box][data-ax5uploader-uploaded-box="inline"] [data-ax5uploader-uploaded-item] .uploaded-item-holder{display:table}[data-ax5uploader-uploaded-box][data-ax5uploader-uploaded-box="inline"] [data-ax5uploader-uploaded-item] .uploaded-item-holder .uploaded-item-cell{display:table-cell;padding:0 3px}[data-ax5uploader-uploaded-box][data-ax5uploader-uploaded-box="inline"] [data-ax5uploader-uploaded-item] .uploaded-item-holder [data-uploaded-item-cell="download"]{cursor:pointer}[data-ax5uploader-uploaded-box][data-ax5uploader-uploaded-box="inline"] [data-ax5uploader-uploaded-item] .uploaded-item-holder [data-uploaded-item-cell="download"]:hover,[data-ax5uploader-uploaded-box][data-ax5uploader-uploaded-box="inline"] [data-ax5uploader-uploaded-item] .uploaded-item-holder [data-uploaded-item-cell="download"]:focus,[data-ax5uploader-uploaded-box][data-ax5uploader-uploaded-box="inline"] [data-ax5uploader-uploaded-item] .uploaded-item-holder [data-uploaded-item-cell="download"].focus{color:#337ab7;text-decoration:none}[data-ax5uploader-uploaded-box][data-ax5uploader-uploaded-box="inline"] [data-ax5uploader-uploaded-item] .uploaded-item-holder [data-uploaded-item-cell="delete"]{cursor:pointer}[data-ax5uploader-uploaded-box][data-ax5uploader-uploaded-box="inline"] [data-ax5uploader-uploaded-item] .uploaded-item-holder [data-uploaded-item-cell="delete"]:hover,[data-ax5uploader-uploaded-box][data-ax5uploader-uploaded-box="inline"] [data-ax5uploader-uploaded-item] .uploaded-item-holder [data-uploaded-item-cell="delete"]:focus,[data-ax5uploader-uploaded-box][data-ax5uploader-uploaded-box="inline"] [data-ax5uploader-uploaded-item] .uploaded-item-holder [data-uploaded-item-cell="delete"].focus{color:#337ab7;text-decoration:none}[data-ax5uploader-dropzone]{background:#f3f3f3;border:2px dashed #0087F7;border-radius:5px;margin:10px 0;padding:7px;cursor:pointer}[data-ax5uploader-dropzone].dragover{background:#fff;border:2px solid #0087F7;opacity:0.6}[data-ax5uploader-input]{position:absolute;left:-1000;top:-1000;opacity:0}[data-ax5uploader-progressbox]{box-sizing:border-box;z-index:1000;position:absolute;left:0px;top:0px;width:200px;-webkit-perspective:1000px;-moz-perspective:1000px;perspective:1000px;-webkit-transform-style:preserve-3d;-moz-transform-style:preserve-3d;-ms-transform-style:preserve-3d;-o-transform-style:preserve-3d;transform-style:preserve-3d;-webkit-animation:ax-progressbox .1s;-moz-animation:ax-progressbox .1s;animation:ax-progressbox .1s;-webkit-transform:translateZ(0);-moz-transform:translateZ(0);-ms-transform:translateZ(0);-o-transform:translateZ(0);transform:translateZ(0);-webkit-transform-origin:center top;-moz-transform-origin:center top;-ms-transform-origin:center top;-o-transform-origin:center top;transform-origin:center top;background-color:#fff;background-image:-webkit-linear-gradient(bottom, #fff);background-image:linear-gradient(to top,#fff);border:1px solid;border-color:#ddd;border-radius:5px;box-shadow:0px 0px 3px 0px rgba(0,0,0,0.175)}[data-ax5uploader-progressbox] .progress{height:12px;margin-bottom:0}[data-ax5uploader-progressbox] .ax-progressbox-body{padding:10px;text-align:center}[data-ax5uploader-progressbox] .ax-progressbox-body .ax-picker-content{min-width:50px}[data-ax5uploader-progressbox] .ax-progressbox-body .ax-picker-content .ax-picker-progressbox-box{border:0px solid;border-color:none;border-radius:0px;padding:0px;overflow:hidden}[data-ax5uploader-progressbox] .ax-progressbox-body .ax-progressbox-buttons{text-align:right;padding:5px 0px 0px 0px}[data-ax5uploader-progressbox] .ax-progressbox-body .ax-progressbox-buttons button.btn{padding:3px 7px;font-size:.8em}[data-ax5uploader-progressbox] .ax-progressbox-body .ax-progressbox-buttons button:not(:last-child){margin-right:3px}[data-ax5uploader-progressbox].direction-top .ax-progressbox-arrow{position:absolute;width:0;height:0;left:50%;top:0}[data-ax5uploader-progressbox].direction-top .ax-progressbox-arrow:before{content:' ';position:absolute;width:0;height:0;left:-6px;top:-12px;border-left:6px solid transparent;border-right:6px solid transparent;border-top:0 none;border-bottom:12px solid #ddd}[data-ax5uploader-progressbox].direction-top .ax-progressbox-arrow:after{content:' ';position:absolute;width:0;height:0;left:-6px;top:-10px;border-left:6px solid transparent;border-right:6px solid transparent;border-top:0 none;border-bottom:12px solid #fff}[data-ax5uploader-progressbox].direction-right .ax-progressbox-arrow{position:absolute;width:0;height:0;right:0;top:50%}[data-ax5uploader-progressbox].direction-right .ax-progressbox-arrow:before{content:' ';position:absolute;width:0;height:0;right:-12px;top:-6px;border-left:12px solid #ddd;border-right:0 none;border-top:6px solid transparent;border-bottom:6px solid transparent}[data-ax5uploader-progressbox].direction-right .ax-progressbox-arrow:after{content:' ';position:absolute;width:0;height:0;right:-10px;top:-6px;border-left:12px solid #fff;border-right:0 none;border-top:6px solid transparent;border-bottom:6px solid transparent}[data-ax5uploader-progressbox].direction-bottom .ax-progressbox-arrow{position:absolute;width:0;height:0;left:50%;bottom:0}[data-ax5uploader-progressbox].direction-bottom .ax-progressbox-arrow:before{content:' ';position:absolute;width:0;height:0;left:-6px;bottom:-12px;border-left:6px solid transparent;border-right:6px solid transparent;border-top:12px solid #ddd;border-bottom:0 none}[data-ax5uploader-progressbox].direction-bottom .ax-progressbox-arrow:after{content:' ';position:absolute;width:0;height:0;left:-6px;bottom:-10px;border-left:6px solid transparent;border-right:6px solid transparent;border-top:12px solid #fff;border-bottom:0 none}[data-ax5uploader-progressbox].direction-left .ax-progressbox-arrow{position:absolute;width:0;height:0;left:0;top:50%}[data-ax5uploader-progressbox].direction-left .ax-progressbox-arrow:before{content:' ';position:absolute;width:0;height:0;left:-12px;top:-6px;border-left:0 none;border-right:12px solid #ddd;border-top:6px solid transparent;border-bottom:6px solid transparent}[data-ax5uploader-progressbox].direction-left .ax-progressbox-arrow:after{content:' ';position:absolute;width:0;height:0;left:-10px;top:-6px;border-left:0 none;border-right:12px solid #fff;border-top:6px solid transparent;border-bottom:6px solid transparent}[data-ax5uploader-progressbox].primary{background-color:#fff;background-image:-webkit-linear-gradient(bottom, #fff);background-image:linear-gradient(to top,#fff);border:1px solid;border-color:#337ab7;border-radius:5px;box-shadow:0px 0px 3px 0px rgba(0,0,0,0.175)}[data-ax5uploader-progressbox].primary .ax-progressbox-body{padding:10px;text-align:center}[data-ax5uploader-progressbox].primary .ax-progressbox-body .ax-picker-content{min-width:50px}[data-ax5uploader-progressbox].primary .ax-progressbox-body .ax-picker-content .ax-picker-progressbox-box{border:0px solid;border-color:none;border-radius:0px;padding:0px;overflow:hidden}[data-ax5uploader-progressbox].primary .ax-progressbox-body .ax-progressbox-buttons{text-align:right;padding:5px 0px 0px 0px}[data-ax5uploader-progressbox].primary .ax-progressbox-body .ax-progressbox-buttons button.btn{padding:3px 7px;font-size:.8em}[data-ax5uploader-progressbox].primary .ax-progressbox-body .ax-progressbox-buttons button:not(:last-child){margin-right:3px}[data-ax5uploader-progressbox].primary.direction-top .ax-progressbox-arrow{position:absolute;width:0;height:0;left:50%;top:0}[data-ax5uploader-progressbox].primary.direction-top .ax-progressbox-arrow:before{content:' ';position:absolute;width:0;height:0;left:-6px;top:-12px;border-left:6px solid transparent;border-right:6px solid transparent;border-top:0 none;border-bottom:12px solid #337ab7}[data-ax5uploader-progressbox].primary.direction-top .ax-progressbox-arrow:after{content:' ';position:absolute;width:0;height:0;left:-6px;top:-10px;border-left:6px solid transparent;border-right:6px solid transparent;border-top:0 none;border-bottom:12px solid #fff}[data-ax5uploader-progressbox].primary.direction-right .ax-progressbox-arrow{position:absolute;width:0;height:0;right:0;top:50%}[data-ax5uploader-progressbox].primary.direction-right .ax-progressbox-arrow:before{content:' ';position:absolute;width:0;height:0;right:-12px;top:-6px;border-left:12px solid #337ab7;border-right:0 none;border-top:6px solid transparent;border-bottom:6px solid transparent}[data-ax5uploader-progressbox].primary.direction-right .ax-progressbox-arrow:after{content:' ';position:absolute;width:0;height:0;right:-10px;top:-6px;border-left:12px solid #fff;border-right:0 none;border-top:6px solid transparent;border-bottom:6px solid transparent}[data-ax5uploader-progressbox].primary.direction-bottom .ax-progressbox-arrow{position:absolute;width:0;height:0;left:50%;bottom:0}[data-ax5uploader-progressbox].primary.direction-bottom .ax-progressbox-arrow:before{content:' ';position:absolute;width:0;height:0;left:-6px;bottom:-12px;border-left:6px solid transparent;border-right:6px solid transparent;border-top:12px solid #337ab7;border-bottom:0 none}[data-ax5uploader-progressbox].primary.direction-bottom .ax-progressbox-arrow:after{content:' ';position:absolute;width:0;height:0;left:-6px;bottom:-10px;border-left:6px solid transparent;border-right:6px solid transparent;border-top:12px solid #fff;border-bottom:0 none}[data-ax5uploader-progressbox].primary.direction-left .ax-progressbox-arrow{position:absolute;width:0;height:0;left:0;top:50%}[data-ax5uploader-progressbox].primary.direction-left .ax-progressbox-arrow:before{content:' ';position:absolute;width:0;height:0;left:-12px;top:-6px;border-left:0 none;border-right:12px solid #337ab7;border-top:6px solid transparent;border-bottom:6px solid transparent}[data-ax5uploader-progressbox].primary.direction-left .ax-progressbox-arrow:after{content:' ';position:absolute;width:0;height:0;left:-10px;top:-6px;border-left:0 none;border-right:12px solid #fff;border-top:6px solid transparent;border-bottom:6px solid transparent}[data-ax5uploader-progressbox].success{background-color:#fff;background-image:-webkit-linear-gradient(bottom, #fff);background-image:linear-gradient(to top,#fff);border:1px solid;border-color:#d6e9c6;border-radius:5px;box-shadow:0px 0px 3px 0px rgba(0,0,0,0.175)}[data-ax5uploader-progressbox].success .ax-progressbox-body{padding:10px;text-align:center}[data-ax5uploader-progressbox].success .ax-progressbox-body .ax-picker-content{min-width:50px}[data-ax5uploader-progressbox].success .ax-progressbox-body .ax-picker-content .ax-picker-progressbox-box{border:0px solid;border-color:none;border-radius:0px;padding:0px;overflow:hidden}[data-ax5uploader-progressbox].success .ax-progressbox-body .ax-progressbox-buttons{text-align:right;padding:5px 0px 0px 0px}[data-ax5uploader-progressbox].success .ax-progressbox-body .ax-progressbox-buttons button.btn{padding:3px 7px;font-size:.8em}[data-ax5uploader-progressbox].success .ax-progressbox-body .ax-progressbox-buttons button:not(:last-child){margin-right:3px}[data-ax5uploader-progressbox].success.direction-top .ax-progressbox-arrow{position:absolute;width:0;height:0;left:50%;top:0}[data-ax5uploader-progressbox].success.direction-top .ax-progressbox-arrow:before{content:' ';position:absolute;width:0;height:0;left:-6px;top:-12px;border-left:6px solid transparent;border-right:6px solid transparent;border-top:0 none;border-bottom:12px solid #d6e9c6}[data-ax5uploader-progressbox].success.direction-top .ax-progressbox-arrow:after{content:' ';position:absolute;width:0;height:0;left:-6px;top:-10px;border-left:6px solid transparent;border-right:6px solid transparent;border-top:0 none;border-bottom:12px solid #fff}[data-ax5uploader-progressbox].success.direction-right .ax-progressbox-arrow{position:absolute;width:0;height:0;right:0;top:50%}[data-ax5uploader-progressbox].success.direction-right .ax-progressbox-arrow:before{content:' ';position:absolute;width:0;height:0;right:-12px;top:-6px;border-left:12px solid #d6e9c6;border-right:0 none;border-top:6px solid transparent;border-bottom:6px solid transparent}[data-ax5uploader-progressbox].success.direction-right .ax-progressbox-arrow:after{content:' ';position:absolute;width:0;height:0;right:-10px;top:-6px;border-left:12px solid #fff;border-right:0 none;border-top:6px solid transparent;border-bottom:6px solid transparent}[data-ax5uploader-progressbox].success.direction-bottom .ax-progressbox-arrow{position:absolute;width:0;height:0;left:50%;bottom:0}[data-ax5uploader-progressbox].success.direction-bottom .ax-progressbox-arrow:before{content:' ';position:absolute;width:0;height:0;left:-6px;bottom:-12px;border-left:6px solid transparent;border-right:6px solid transparent;border-top:12px solid #d6e9c6;border-bottom:0 none}[data-ax5uploader-progressbox].success.direction-bottom .ax-progressbox-arrow:after{content:' ';position:absolute;width:0;height:0;left:-6px;bottom:-10px;border-left:6px solid transparent;border-right:6px solid transparent;border-top:12px solid #fff;border-bottom:0 none}[data-ax5uploader-progressbox].success.direction-left .ax-progressbox-arrow{position:absolute;width:0;height:0;left:0;top:50%}[data-ax5uploader-progressbox].success.direction-left .ax-progressbox-arrow:before{content:' ';position:absolute;width:0;height:0;left:-12px;top:-6px;border-left:0 none;border-right:12px solid #d6e9c6;border-top:6px solid transparent;border-bottom:6px solid transparent}[data-ax5uploader-progressbox].success.direction-left .ax-progressbox-arrow:after{content:' ';position:absolute;width:0;height:0;left:-10px;top:-6px;border-left:0 none;border-right:12px solid #fff;border-top:6px solid transparent;border-bottom:6px solid transparent}[data-ax5uploader-progressbox].info{background-color:#fff;background-image:-webkit-linear-gradient(bottom, #fff);background-image:linear-gradient(to top,#fff);border:1px solid;border-color:#bce8f1;border-radius:5px;box-shadow:0px 0px 3px 0px rgba(0,0,0,0.175)}[data-ax5uploader-progressbox].info .ax-progressbox-body{padding:10px;text-align:center}[data-ax5uploader-progressbox].info .ax-progressbox-body .ax-picker-content{min-width:50px}[data-ax5uploader-progressbox].info .ax-progressbox-body .ax-picker-content .ax-picker-progressbox-box{border:0px solid;border-color:none;border-radius:0px;padding:0px;overflow:hidden}[data-ax5uploader-progressbox].info .ax-progressbox-body .ax-progressbox-buttons{text-align:right;padding:5px 0px 0px 0px}[data-ax5uploader-progressbox].info .ax-progressbox-body .ax-progressbox-buttons button.btn{padding:3px 7px;font-size:.8em}[data-ax5uploader-progressbox].info .ax-progressbox-body .ax-progressbox-buttons button:not(:last-child){margin-right:3px}[data-ax5uploader-progressbox].info.direction-top .ax-progressbox-arrow{position:absolute;width:0;height:0;left:50%;top:0}[data-ax5uploader-progressbox].info.direction-top .ax-progressbox-arrow:before{content:' ';position:absolute;width:0;height:0;left:-6px;top:-12px;border-left:6px solid transparent;border-right:6px solid transparent;border-top:0 none;border-bottom:12px solid #bce8f1}[data-ax5uploader-progressbox].info.direction-top .ax-progressbox-arrow:after{content:' ';position:absolute;width:0;height:0;left:-6px;top:-10px;border-left:6px solid transparent;border-right:6px solid transparent;border-top:0 none;border-bottom:12px solid #fff}[data-ax5uploader-progressbox].info.direction-right .ax-progressbox-arrow{position:absolute;width:0;height:0;right:0;top:50%}[data-ax5uploader-progressbox].info.direction-right .ax-progressbox-arrow:before{content:' ';position:absolute;width:0;height:0;right:-12px;top:-6px;border-left:12px solid #bce8f1;border-right:0 none;border-top:6px solid transparent;border-bottom:6px solid transparent}[data-ax5uploader-progressbox].info.direction-right .ax-progressbox-arrow:after{content:' ';position:absolute;width:0;height:0;right:-10px;top:-6px;border-left:12px solid #fff;border-right:0 none;border-top:6px solid transparent;border-bottom:6px solid transparent}[data-ax5uploader-progressbox].info.direction-bottom .ax-progressbox-arrow{position:absolute;width:0;height:0;left:50%;bottom:0}[data-ax5uploader-progressbox].info.direction-bottom .ax-progressbox-arrow:before{content:' ';position:absolute;width:0;height:0;left:-6px;bottom:-12px;border-left:6px solid transparent;border-right:6px solid transparent;border-top:12px solid #bce8f1;border-bottom:0 none}[data-ax5uploader-progressbox].info.direction-bottom .ax-progressbox-arrow:after{content:' ';position:absolute;width:0;height:0;left:-6px;bottom:-10px;border-left:6px solid transparent;border-right:6px solid transparent;border-top:12px solid #fff;border-bottom:0 none}[data-ax5uploader-progressbox].info.direction-left .ax-progressbox-arrow{position:absolute;width:0;height:0;left:0;top:50%}[data-ax5uploader-progressbox].info.direction-left .ax-progressbox-arrow:before{content:' ';position:absolute;width:0;height:0;left:-12px;top:-6px;border-left:0 none;border-right:12px solid #bce8f1;border-top:6px solid transparent;border-bottom:6px solid transparent}[data-ax5uploader-progressbox].info.direction-left .ax-progressbox-arrow:after{content:' ';position:absolute;width:0;height:0;left:-10px;top:-6px;border-left:0 none;border-right:12px solid #fff;border-top:6px solid transparent;border-bottom:6px solid transparent}[data-ax5uploader-progressbox].warning{background-color:#fff;background-image:-webkit-linear-gradient(bottom, #fff);background-image:linear-gradient(to top,#fff);border:1px solid;border-color:#faebcc;border-radius:5px;box-shadow:0px 0px 3px 0px rgba(0,0,0,0.175)}[data-ax5uploader-progressbox].warning .ax-progressbox-body{padding:10px;text-align:center}[data-ax5uploader-progressbox].warning .ax-progressbox-body .ax-picker-content{min-width:50px}[data-ax5uploader-progressbox].warning .ax-progressbox-body .ax-picker-content .ax-picker-progressbox-box{border:0px solid;border-color:none;border-radius:0px;padding:0px;overflow:hidden}[data-ax5uploader-progressbox].warning .ax-progressbox-body .ax-progressbox-buttons{text-align:right;padding:5px 0px 0px 0px}[data-ax5uploader-progressbox].warning .ax-progressbox-body .ax-progressbox-buttons button.btn{padding:3px 7px;font-size:.8em}[data-ax5uploader-progressbox].warning .ax-progressbox-body .ax-progressbox-buttons button:not(:last-child){margin-right:3px}[data-ax5uploader-progressbox].warning.direction-top .ax-progressbox-arrow{position:absolute;width:0;height:0;left:50%;top:0}[data-ax5uploader-progressbox].warning.direction-top .ax-progressbox-arrow:before{content:' ';position:absolute;width:0;height:0;left:-6px;top:-12px;border-left:6px solid transparent;border-right:6px solid transparent;border-top:0 none;border-bottom:12px solid #faebcc}[data-ax5uploader-progressbox].warning.direction-top .ax-progressbox-arrow:after{content:' ';position:absolute;width:0;height:0;left:-6px;top:-10px;border-left:6px solid transparent;border-right:6px solid transparent;border-top:0 none;border-bottom:12px solid #fff}[data-ax5uploader-progressbox].warning.direction-right .ax-progressbox-arrow{position:absolute;width:0;height:0;right:0;top:50%}[data-ax5uploader-progressbox].warning.direction-right .ax-progressbox-arrow:before{content:' ';position:absolute;width:0;height:0;right:-12px;top:-6px;border-left:12px solid #faebcc;border-right:0 none;border-top:6px solid transparent;border-bottom:6px solid transparent}[data-ax5uploader-progressbox].warning.direction-right .ax-progressbox-arrow:after{content:' ';position:absolute;width:0;height:0;right:-10px;top:-6px;border-left:12px solid #fff;border-right:0 none;border-top:6px solid transparent;border-bottom:6px solid transparent}[data-ax5uploader-progressbox].warning.direction-bottom .ax-progressbox-arrow{position:absolute;width:0;height:0;left:50%;bottom:0}[data-ax5uploader-progressbox].warning.direction-bottom .ax-progressbox-arrow:before{content:' ';position:absolute;width:0;height:0;left:-6px;bottom:-12px;border-left:6px solid transparent;border-right:6px solid transparent;border-top:12px solid #faebcc;border-bottom:0 none}[data-ax5uploader-progressbox].warning.direction-bottom .ax-progressbox-arrow:after{content:' ';position:absolute;width:0;height:0;left:-6px;bottom:-10px;border-left:6px solid transparent;border-right:6px solid transparent;border-top:12px solid #fff;border-bottom:0 none}[data-ax5uploader-progressbox].warning.direction-left .ax-progressbox-arrow{position:absolute;width:0;height:0;left:0;top:50%}[data-ax5uploader-progressbox].warning.direction-left .ax-progressbox-arrow:before{content:' ';position:absolute;width:0;height:0;left:-12px;top:-6px;border-left:0 none;border-right:12px solid #faebcc;border-top:6px solid transparent;border-bottom:6px solid transparent}[data-ax5uploader-progressbox].warning.direction-left .ax-progressbox-arrow:after{content:' ';position:absolute;width:0;height:0;left:-10px;top:-6px;border-left:0 none;border-right:12px solid #fff;border-top:6px solid transparent;border-bottom:6px solid transparent}[data-ax5uploader-progressbox].danger{background-color:#fff;background-image:-webkit-linear-gradient(bottom, #fff);background-image:linear-gradient(to top,#fff);border:1px solid;border-color:#ebccd1;border-radius:5px;box-shadow:0px 0px 3px 0px rgba(0,0,0,0.175)}[data-ax5uploader-progressbox].danger .ax-progressbox-body{padding:10px;text-align:center}[data-ax5uploader-progressbox].danger .ax-progressbox-body .ax-picker-content{min-width:50px}[data-ax5uploader-progressbox].danger .ax-progressbox-body .ax-picker-content .ax-picker-progressbox-box{border:0px solid;border-color:none;border-radius:0px;padding:0px;overflow:hidden}[data-ax5uploader-progressbox].danger .ax-progressbox-body .ax-progressbox-buttons{text-align:right;padding:5px 0px 0px 0px}[data-ax5uploader-progressbox].danger .ax-progressbox-body .ax-progressbox-buttons button.btn{padding:3px 7px;font-size:.8em}[data-ax5uploader-progressbox].danger .ax-progressbox-body .ax-progressbox-buttons button:not(:last-child){margin-right:3px}[data-ax5uploader-progressbox].danger.direction-top .ax-progressbox-arrow{position:absolute;width:0;height:0;left:50%;top:0}[data-ax5uploader-progressbox].danger.direction-top .ax-progressbox-arrow:before{content:' ';position:absolute;width:0;height:0;left:-6px;top:-12px;border-left:6px solid transparent;border-right:6px solid transparent;border-top:0 none;border-bottom:12px solid #ebccd1}[data-ax5uploader-progressbox].danger.direction-top .ax-progressbox-arrow:after{content:' ';position:absolute;width:0;height:0;left:-6px;top:-10px;border-left:6px solid transparent;border-right:6px solid transparent;border-top:0 none;border-bottom:12px solid #fff}[data-ax5uploader-progressbox].danger.direction-right .ax-progressbox-arrow{position:absolute;width:0;height:0;right:0;top:50%}[data-ax5uploader-progressbox].danger.direction-right .ax-progressbox-arrow:before{content:' ';position:absolute;width:0;height:0;right:-12px;top:-6px;border-left:12px solid #ebccd1;border-right:0 none;border-top:6px solid transparent;border-bottom:6px solid transparent}[data-ax5uploader-progressbox].danger.direction-right .ax-progressbox-arrow:after{content:' ';position:absolute;width:0;height:0;right:-10px;top:-6px;border-left:12px solid #fff;border-right:0 none;border-top:6px solid transparent;border-bottom:6px solid transparent}[data-ax5uploader-progressbox].danger.direction-bottom .ax-progressbox-arrow{position:absolute;width:0;height:0;left:50%;bottom:0}[data-ax5uploader-progressbox].danger.direction-bottom .ax-progressbox-arrow:before{content:' ';position:absolute;width:0;height:0;left:-6px;bottom:-12px;border-left:6px solid transparent;border-right:6px solid transparent;border-top:12px solid #ebccd1;border-bottom:0 none}[data-ax5uploader-progressbox].danger.direction-bottom .ax-progressbox-arrow:after{content:' ';position:absolute;width:0;height:0;left:-6px;bottom:-10px;border-left:6px solid transparent;border-right:6px solid transparent;border-top:12px solid #fff;border-bottom:0 none}[data-ax5uploader-progressbox].danger.direction-left .ax-progressbox-arrow{position:absolute;width:0;height:0;left:0;top:50%}[data-ax5uploader-progressbox].danger.direction-left .ax-progressbox-arrow:before{content:' ';position:absolute;width:0;height:0;left:-12px;top:-6px;border-left:0 none;border-right:12px solid #ebccd1;border-top:6px solid transparent;border-bottom:6px solid transparent}[data-ax5uploader-progressbox].danger.direction-left .ax-progressbox-arrow:after{content:' ';position:absolute;width:0;height:0;left:-10px;top:-6px;border-left:0 none;border-right:12px solid #fff;border-top:6px solid transparent;border-bottom:6px solid transparent}[data-ax5uploader-progressbox].destroy{-webkit-animation:ax-progressbox-destroy .1s cubic-bezier(0.6, -0.28, 0.735, 0.045) forwards;-moz-animation:ax-progressbox-destroy .1s cubic-bezier(0.6, -0.28, 0.735, 0.045) forwards;animation:ax-progressbox-destroy .1s cubic-bezier(0.6, -0.28, 0.735, 0.045) forwards}[data-ax5uploader-progressbox].direction-top{-webkit-transform-origin:center top;-moz-transform-origin:center top;-ms-transform-origin:center top;-o-transform-origin:center top;transform-origin:center top}[data-ax5uploader-progressbox].direction-right{-webkit-transform-origin:right center;-moz-transform-origin:right center;-ms-transform-origin:right center;-o-transform-origin:right center;transform-origin:right center}[data-ax5uploader-progressbox].direction-bottom{-webkit-transform-origin:center bottom;-moz-transform-origin:center bottom;-ms-transform-origin:center bottom;-o-transform-origin:center bottom;transform-origin:center bottom}[data-ax5uploader-progressbox].direction-left{-webkit-transform-origin:left center;-moz-transform-origin:left center;-ms-transform-origin:left center;-o-transform-origin:left center;transform-origin:left center} +@-webkit-keyframes ax-progressbox{0%{opacity:0.0;-webkit-transform:scale(0)}100%{opacity:1.0;-webkit-transform:scale(1)}}@-moz-keyframes ax-progressbox{0%{opacity:0.0;-moz-transform:scale(0)}100%{opacity:1.0;-moz-transform:scale(1)}}@keyframes ax-progressbox{0%{opacity:0.0;-webkit-transform:scale(0);-moz-transform:scale(0);-ms-transform:scale(0);-o-transform:scale(0);transform:scale(0)}100%{opacity:1.0;-webkit-transform:scale(1);-moz-transform:scale(1);-ms-transform:scale(1);-o-transform:scale(1);transform:scale(1)}}@-webkit-keyframes ax-progressbox-destroy{from{-webkit-transform:scale(1);opacity:1.0}to{-webkit-transform:scale(0.95);opacity:0.0}}@-moz-keyframes ax-progressbox-destroy{from{-moz-transform:scale(1);opacity:1.0}to{-moz-transform:scale(0.95);opacity:0.0}}@keyframes ax-progressbox-destroy{from{-webkit-transform:scale(1);-moz-transform:scale(1);-ms-transform:scale(1);-o-transform:scale(1);transform:scale(1);opacity:1.0}to{-webkit-transform:scale(0.95);-moz-transform:scale(0.95);-ms-transform:scale(0.95);-o-transform:scale(0.95);transform:scale(0.95);opacity:0.0}}[data-ax5uploader]{position:relative}[data-ax5uploader] [data-ax5uploader-button="selector"]{position:relative}[data-ax5uploader] [data-ax5uploader-dropzone]{background:#f3f3f3;border:2px dashed #0087F7;border-radius:5px;margin:10px 0;padding:7px;cursor:pointer}[data-ax5uploader] [data-ax5uploader-dropzone].dragover{background:#fff;border:2px solid #0087F7;opacity:0.6}[data-ax5uploader-uploaded-box]{background:#f3f3f3;border:1px solid #ccc;border-radius:5px;margin:10px 0;padding:7px;min-height:100px}[data-ax5uploader-uploaded-box][data-ax5uploader-uploaded-box]{margin:10px 0}[data-ax5uploader-uploaded-box][data-ax5uploader-uploaded-box] [data-ax5uploader-uploaded-item]{display:block;color:#333;border:0px solid #ccc;border-radius:4px;padding:6px 12px;margin:3px;background:#fff}[data-ax5uploader-uploaded-box][data-ax5uploader-uploaded-box] [data-ax5uploader-uploaded-item]:hover,[data-ax5uploader-uploaded-box][data-ax5uploader-uploaded-box] [data-ax5uploader-uploaded-item]:focus,[data-ax5uploader-uploaded-box][data-ax5uploader-uploaded-box] [data-ax5uploader-uploaded-item].focus{color:#333;text-decoration:none}[data-ax5uploader-uploaded-box][data-ax5uploader-uploaded-box] [data-ax5uploader-uploaded-item]:active,[data-ax5uploader-uploaded-box][data-ax5uploader-uploaded-box] [data-ax5uploader-uploaded-item].active{outline:0;background-image:none;box-shadow:inset 0 3px 5px rgba(0,0,0,0.125)}[data-ax5uploader-uploaded-box][data-ax5uploader-uploaded-box] [data-ax5uploader-uploaded-item].disabled,[data-ax5uploader-uploaded-box][data-ax5uploader-uploaded-box] [data-ax5uploader-uploaded-item][disabled],fieldset[disabled] [data-ax5uploader-uploaded-box][data-ax5uploader-uploaded-box] [data-ax5uploader-uploaded-item]{cursor:not-allowed;opacity:.65;box-shadow:none}[data-ax5uploader-uploaded-box][data-ax5uploader-uploaded-box] [data-ax5uploader-uploaded-item] .uploaded-item-holder{display:table}[data-ax5uploader-uploaded-box][data-ax5uploader-uploaded-box] [data-ax5uploader-uploaded-item] .uploaded-item-holder .uploaded-item-cell{display:table-cell;padding:0 3px}[data-ax5uploader-uploaded-box][data-ax5uploader-uploaded-box] [data-ax5uploader-uploaded-item] .uploaded-item-holder [data-uploaded-item-cell="download"]{cursor:pointer}[data-ax5uploader-uploaded-box][data-ax5uploader-uploaded-box] [data-ax5uploader-uploaded-item] .uploaded-item-holder [data-uploaded-item-cell="download"]:hover,[data-ax5uploader-uploaded-box][data-ax5uploader-uploaded-box] [data-ax5uploader-uploaded-item] .uploaded-item-holder [data-uploaded-item-cell="download"]:focus,[data-ax5uploader-uploaded-box][data-ax5uploader-uploaded-box] [data-ax5uploader-uploaded-item] .uploaded-item-holder [data-uploaded-item-cell="download"].focus{color:#337ab7;text-decoration:none}[data-ax5uploader-uploaded-box][data-ax5uploader-uploaded-box] [data-ax5uploader-uploaded-item] .uploaded-item-holder [data-uploaded-item-cell="delete"]{cursor:pointer}[data-ax5uploader-uploaded-box][data-ax5uploader-uploaded-box] [data-ax5uploader-uploaded-item] .uploaded-item-holder [data-uploaded-item-cell="delete"]:hover,[data-ax5uploader-uploaded-box][data-ax5uploader-uploaded-box] [data-ax5uploader-uploaded-item] .uploaded-item-holder [data-uploaded-item-cell="delete"]:focus,[data-ax5uploader-uploaded-box][data-ax5uploader-uploaded-box] [data-ax5uploader-uploaded-item] .uploaded-item-holder [data-uploaded-item-cell="delete"].focus{color:#337ab7;text-decoration:none}[data-ax5uploader-uploaded-box][data-ax5uploader-uploaded-box="inline"]:after{content:" ";display:block;clear:both}[data-ax5uploader-uploaded-box][data-ax5uploader-uploaded-box="inline"] [data-ax5uploader-uploaded-item]{display:block;float:left}[data-ax5uploader-input]{position:absolute;left:-1000px;top:-1000px;opacity:0;cursor:pointer}[data-ax5uploader-progressbox]{box-sizing:border-box;z-index:1000;position:absolute;left:0px;top:0px;width:200px;-webkit-perspective:1000px;-moz-perspective:1000px;perspective:1000px;-webkit-transform-style:preserve-3d;-moz-transform-style:preserve-3d;-ms-transform-style:preserve-3d;-o-transform-style:preserve-3d;transform-style:preserve-3d;-webkit-animation:ax-progressbox .1s;-moz-animation:ax-progressbox .1s;animation:ax-progressbox .1s;-webkit-transform:translateZ(0);-moz-transform:translateZ(0);-ms-transform:translateZ(0);-o-transform:translateZ(0);transform:translateZ(0);-webkit-transform-origin:center top;-moz-transform-origin:center top;-ms-transform-origin:center top;-o-transform-origin:center top;transform-origin:center top;background-color:#fff;background-image:-webkit-linear-gradient(bottom, #fff);background-image:linear-gradient(to top,#fff);border:1px solid;border-color:#ddd;border-radius:5px;box-shadow:0px 0px 3px 0px rgba(0,0,0,0.175)}[data-ax5uploader-progressbox] .progress{height:12px;margin-bottom:0}[data-ax5uploader-progressbox] .ax-progressbox-body{padding:10px;text-align:center}[data-ax5uploader-progressbox] .ax-progressbox-body .ax-picker-content{min-width:50px}[data-ax5uploader-progressbox] .ax-progressbox-body .ax-picker-content .ax-picker-progressbox-box{border:0px solid;border-color:none;border-radius:0px;padding:0px;overflow:hidden}[data-ax5uploader-progressbox] .ax-progressbox-body .ax-progressbox-buttons{text-align:right;padding:5px 0px 0px 0px}[data-ax5uploader-progressbox] .ax-progressbox-body .ax-progressbox-buttons button.btn{padding:3px 7px;font-size:.8em}[data-ax5uploader-progressbox] .ax-progressbox-body .ax-progressbox-buttons button:not(:last-child){margin-right:3px}[data-ax5uploader-progressbox].direction-top .ax-progressbox-arrow{position:absolute;width:0;height:0;left:50%;top:0}[data-ax5uploader-progressbox].direction-top .ax-progressbox-arrow:before{content:' ';position:absolute;width:0;height:0;left:-6px;top:-12px;border-left:6px solid transparent;border-right:6px solid transparent;border-top:0 none;border-bottom:12px solid #ddd}[data-ax5uploader-progressbox].direction-top .ax-progressbox-arrow:after{content:' ';position:absolute;width:0;height:0;left:-6px;top:-10px;border-left:6px solid transparent;border-right:6px solid transparent;border-top:0 none;border-bottom:12px solid #fff}[data-ax5uploader-progressbox].direction-right .ax-progressbox-arrow{position:absolute;width:0;height:0;right:0;top:50%}[data-ax5uploader-progressbox].direction-right .ax-progressbox-arrow:before{content:' ';position:absolute;width:0;height:0;right:-12px;top:-6px;border-left:12px solid #ddd;border-right:0 none;border-top:6px solid transparent;border-bottom:6px solid transparent}[data-ax5uploader-progressbox].direction-right .ax-progressbox-arrow:after{content:' ';position:absolute;width:0;height:0;right:-10px;top:-6px;border-left:12px solid #fff;border-right:0 none;border-top:6px solid transparent;border-bottom:6px solid transparent}[data-ax5uploader-progressbox].direction-bottom .ax-progressbox-arrow{position:absolute;width:0;height:0;left:50%;bottom:0}[data-ax5uploader-progressbox].direction-bottom .ax-progressbox-arrow:before{content:' ';position:absolute;width:0;height:0;left:-6px;bottom:-12px;border-left:6px solid transparent;border-right:6px solid transparent;border-top:12px solid #ddd;border-bottom:0 none}[data-ax5uploader-progressbox].direction-bottom .ax-progressbox-arrow:after{content:' ';position:absolute;width:0;height:0;left:-6px;bottom:-10px;border-left:6px solid transparent;border-right:6px solid transparent;border-top:12px solid #fff;border-bottom:0 none}[data-ax5uploader-progressbox].direction-left .ax-progressbox-arrow{position:absolute;width:0;height:0;left:0;top:50%}[data-ax5uploader-progressbox].direction-left .ax-progressbox-arrow:before{content:' ';position:absolute;width:0;height:0;left:-12px;top:-6px;border-left:0 none;border-right:12px solid #ddd;border-top:6px solid transparent;border-bottom:6px solid transparent}[data-ax5uploader-progressbox].direction-left .ax-progressbox-arrow:after{content:' ';position:absolute;width:0;height:0;left:-10px;top:-6px;border-left:0 none;border-right:12px solid #fff;border-top:6px solid transparent;border-bottom:6px solid transparent}[data-ax5uploader-progressbox].primary{background-color:#fff;background-image:-webkit-linear-gradient(bottom, #fff);background-image:linear-gradient(to top,#fff);border:1px solid;border-color:#337ab7;border-radius:5px;box-shadow:0px 0px 3px 0px rgba(0,0,0,0.175)}[data-ax5uploader-progressbox].primary .ax-progressbox-body{padding:10px;text-align:center}[data-ax5uploader-progressbox].primary .ax-progressbox-body .ax-picker-content{min-width:50px}[data-ax5uploader-progressbox].primary .ax-progressbox-body .ax-picker-content .ax-picker-progressbox-box{border:0px solid;border-color:none;border-radius:0px;padding:0px;overflow:hidden}[data-ax5uploader-progressbox].primary .ax-progressbox-body .ax-progressbox-buttons{text-align:right;padding:5px 0px 0px 0px}[data-ax5uploader-progressbox].primary .ax-progressbox-body .ax-progressbox-buttons button.btn{padding:3px 7px;font-size:.8em}[data-ax5uploader-progressbox].primary .ax-progressbox-body .ax-progressbox-buttons button:not(:last-child){margin-right:3px}[data-ax5uploader-progressbox].primary.direction-top .ax-progressbox-arrow{position:absolute;width:0;height:0;left:50%;top:0}[data-ax5uploader-progressbox].primary.direction-top .ax-progressbox-arrow:before{content:' ';position:absolute;width:0;height:0;left:-6px;top:-12px;border-left:6px solid transparent;border-right:6px solid transparent;border-top:0 none;border-bottom:12px solid #337ab7}[data-ax5uploader-progressbox].primary.direction-top .ax-progressbox-arrow:after{content:' ';position:absolute;width:0;height:0;left:-6px;top:-10px;border-left:6px solid transparent;border-right:6px solid transparent;border-top:0 none;border-bottom:12px solid #fff}[data-ax5uploader-progressbox].primary.direction-right .ax-progressbox-arrow{position:absolute;width:0;height:0;right:0;top:50%}[data-ax5uploader-progressbox].primary.direction-right .ax-progressbox-arrow:before{content:' ';position:absolute;width:0;height:0;right:-12px;top:-6px;border-left:12px solid #337ab7;border-right:0 none;border-top:6px solid transparent;border-bottom:6px solid transparent}[data-ax5uploader-progressbox].primary.direction-right .ax-progressbox-arrow:after{content:' ';position:absolute;width:0;height:0;right:-10px;top:-6px;border-left:12px solid #fff;border-right:0 none;border-top:6px solid transparent;border-bottom:6px solid transparent}[data-ax5uploader-progressbox].primary.direction-bottom .ax-progressbox-arrow{position:absolute;width:0;height:0;left:50%;bottom:0}[data-ax5uploader-progressbox].primary.direction-bottom .ax-progressbox-arrow:before{content:' ';position:absolute;width:0;height:0;left:-6px;bottom:-12px;border-left:6px solid transparent;border-right:6px solid transparent;border-top:12px solid #337ab7;border-bottom:0 none}[data-ax5uploader-progressbox].primary.direction-bottom .ax-progressbox-arrow:after{content:' ';position:absolute;width:0;height:0;left:-6px;bottom:-10px;border-left:6px solid transparent;border-right:6px solid transparent;border-top:12px solid #fff;border-bottom:0 none}[data-ax5uploader-progressbox].primary.direction-left .ax-progressbox-arrow{position:absolute;width:0;height:0;left:0;top:50%}[data-ax5uploader-progressbox].primary.direction-left .ax-progressbox-arrow:before{content:' ';position:absolute;width:0;height:0;left:-12px;top:-6px;border-left:0 none;border-right:12px solid #337ab7;border-top:6px solid transparent;border-bottom:6px solid transparent}[data-ax5uploader-progressbox].primary.direction-left .ax-progressbox-arrow:after{content:' ';position:absolute;width:0;height:0;left:-10px;top:-6px;border-left:0 none;border-right:12px solid #fff;border-top:6px solid transparent;border-bottom:6px solid transparent}[data-ax5uploader-progressbox].success{background-color:#fff;background-image:-webkit-linear-gradient(bottom, #fff);background-image:linear-gradient(to top,#fff);border:1px solid;border-color:#d6e9c6;border-radius:5px;box-shadow:0px 0px 3px 0px rgba(0,0,0,0.175)}[data-ax5uploader-progressbox].success .ax-progressbox-body{padding:10px;text-align:center}[data-ax5uploader-progressbox].success .ax-progressbox-body .ax-picker-content{min-width:50px}[data-ax5uploader-progressbox].success .ax-progressbox-body .ax-picker-content .ax-picker-progressbox-box{border:0px solid;border-color:none;border-radius:0px;padding:0px;overflow:hidden}[data-ax5uploader-progressbox].success .ax-progressbox-body .ax-progressbox-buttons{text-align:right;padding:5px 0px 0px 0px}[data-ax5uploader-progressbox].success .ax-progressbox-body .ax-progressbox-buttons button.btn{padding:3px 7px;font-size:.8em}[data-ax5uploader-progressbox].success .ax-progressbox-body .ax-progressbox-buttons button:not(:last-child){margin-right:3px}[data-ax5uploader-progressbox].success.direction-top .ax-progressbox-arrow{position:absolute;width:0;height:0;left:50%;top:0}[data-ax5uploader-progressbox].success.direction-top .ax-progressbox-arrow:before{content:' ';position:absolute;width:0;height:0;left:-6px;top:-12px;border-left:6px solid transparent;border-right:6px solid transparent;border-top:0 none;border-bottom:12px solid #d6e9c6}[data-ax5uploader-progressbox].success.direction-top .ax-progressbox-arrow:after{content:' ';position:absolute;width:0;height:0;left:-6px;top:-10px;border-left:6px solid transparent;border-right:6px solid transparent;border-top:0 none;border-bottom:12px solid #fff}[data-ax5uploader-progressbox].success.direction-right .ax-progressbox-arrow{position:absolute;width:0;height:0;right:0;top:50%}[data-ax5uploader-progressbox].success.direction-right .ax-progressbox-arrow:before{content:' ';position:absolute;width:0;height:0;right:-12px;top:-6px;border-left:12px solid #d6e9c6;border-right:0 none;border-top:6px solid transparent;border-bottom:6px solid transparent}[data-ax5uploader-progressbox].success.direction-right .ax-progressbox-arrow:after{content:' ';position:absolute;width:0;height:0;right:-10px;top:-6px;border-left:12px solid #fff;border-right:0 none;border-top:6px solid transparent;border-bottom:6px solid transparent}[data-ax5uploader-progressbox].success.direction-bottom .ax-progressbox-arrow{position:absolute;width:0;height:0;left:50%;bottom:0}[data-ax5uploader-progressbox].success.direction-bottom .ax-progressbox-arrow:before{content:' ';position:absolute;width:0;height:0;left:-6px;bottom:-12px;border-left:6px solid transparent;border-right:6px solid transparent;border-top:12px solid #d6e9c6;border-bottom:0 none}[data-ax5uploader-progressbox].success.direction-bottom .ax-progressbox-arrow:after{content:' ';position:absolute;width:0;height:0;left:-6px;bottom:-10px;border-left:6px solid transparent;border-right:6px solid transparent;border-top:12px solid #fff;border-bottom:0 none}[data-ax5uploader-progressbox].success.direction-left .ax-progressbox-arrow{position:absolute;width:0;height:0;left:0;top:50%}[data-ax5uploader-progressbox].success.direction-left .ax-progressbox-arrow:before{content:' ';position:absolute;width:0;height:0;left:-12px;top:-6px;border-left:0 none;border-right:12px solid #d6e9c6;border-top:6px solid transparent;border-bottom:6px solid transparent}[data-ax5uploader-progressbox].success.direction-left .ax-progressbox-arrow:after{content:' ';position:absolute;width:0;height:0;left:-10px;top:-6px;border-left:0 none;border-right:12px solid #fff;border-top:6px solid transparent;border-bottom:6px solid transparent}[data-ax5uploader-progressbox].info{background-color:#fff;background-image:-webkit-linear-gradient(bottom, #fff);background-image:linear-gradient(to top,#fff);border:1px solid;border-color:#bce8f1;border-radius:5px;box-shadow:0px 0px 3px 0px rgba(0,0,0,0.175)}[data-ax5uploader-progressbox].info .ax-progressbox-body{padding:10px;text-align:center}[data-ax5uploader-progressbox].info .ax-progressbox-body .ax-picker-content{min-width:50px}[data-ax5uploader-progressbox].info .ax-progressbox-body .ax-picker-content .ax-picker-progressbox-box{border:0px solid;border-color:none;border-radius:0px;padding:0px;overflow:hidden}[data-ax5uploader-progressbox].info .ax-progressbox-body .ax-progressbox-buttons{text-align:right;padding:5px 0px 0px 0px}[data-ax5uploader-progressbox].info .ax-progressbox-body .ax-progressbox-buttons button.btn{padding:3px 7px;font-size:.8em}[data-ax5uploader-progressbox].info .ax-progressbox-body .ax-progressbox-buttons button:not(:last-child){margin-right:3px}[data-ax5uploader-progressbox].info.direction-top .ax-progressbox-arrow{position:absolute;width:0;height:0;left:50%;top:0}[data-ax5uploader-progressbox].info.direction-top .ax-progressbox-arrow:before{content:' ';position:absolute;width:0;height:0;left:-6px;top:-12px;border-left:6px solid transparent;border-right:6px solid transparent;border-top:0 none;border-bottom:12px solid #bce8f1}[data-ax5uploader-progressbox].info.direction-top .ax-progressbox-arrow:after{content:' ';position:absolute;width:0;height:0;left:-6px;top:-10px;border-left:6px solid transparent;border-right:6px solid transparent;border-top:0 none;border-bottom:12px solid #fff}[data-ax5uploader-progressbox].info.direction-right .ax-progressbox-arrow{position:absolute;width:0;height:0;right:0;top:50%}[data-ax5uploader-progressbox].info.direction-right .ax-progressbox-arrow:before{content:' ';position:absolute;width:0;height:0;right:-12px;top:-6px;border-left:12px solid #bce8f1;border-right:0 none;border-top:6px solid transparent;border-bottom:6px solid transparent}[data-ax5uploader-progressbox].info.direction-right .ax-progressbox-arrow:after{content:' ';position:absolute;width:0;height:0;right:-10px;top:-6px;border-left:12px solid #fff;border-right:0 none;border-top:6px solid transparent;border-bottom:6px solid transparent}[data-ax5uploader-progressbox].info.direction-bottom .ax-progressbox-arrow{position:absolute;width:0;height:0;left:50%;bottom:0}[data-ax5uploader-progressbox].info.direction-bottom .ax-progressbox-arrow:before{content:' ';position:absolute;width:0;height:0;left:-6px;bottom:-12px;border-left:6px solid transparent;border-right:6px solid transparent;border-top:12px solid #bce8f1;border-bottom:0 none}[data-ax5uploader-progressbox].info.direction-bottom .ax-progressbox-arrow:after{content:' ';position:absolute;width:0;height:0;left:-6px;bottom:-10px;border-left:6px solid transparent;border-right:6px solid transparent;border-top:12px solid #fff;border-bottom:0 none}[data-ax5uploader-progressbox].info.direction-left .ax-progressbox-arrow{position:absolute;width:0;height:0;left:0;top:50%}[data-ax5uploader-progressbox].info.direction-left .ax-progressbox-arrow:before{content:' ';position:absolute;width:0;height:0;left:-12px;top:-6px;border-left:0 none;border-right:12px solid #bce8f1;border-top:6px solid transparent;border-bottom:6px solid transparent}[data-ax5uploader-progressbox].info.direction-left .ax-progressbox-arrow:after{content:' ';position:absolute;width:0;height:0;left:-10px;top:-6px;border-left:0 none;border-right:12px solid #fff;border-top:6px solid transparent;border-bottom:6px solid transparent}[data-ax5uploader-progressbox].warning{background-color:#fff;background-image:-webkit-linear-gradient(bottom, #fff);background-image:linear-gradient(to top,#fff);border:1px solid;border-color:#faebcc;border-radius:5px;box-shadow:0px 0px 3px 0px rgba(0,0,0,0.175)}[data-ax5uploader-progressbox].warning .ax-progressbox-body{padding:10px;text-align:center}[data-ax5uploader-progressbox].warning .ax-progressbox-body .ax-picker-content{min-width:50px}[data-ax5uploader-progressbox].warning .ax-progressbox-body .ax-picker-content .ax-picker-progressbox-box{border:0px solid;border-color:none;border-radius:0px;padding:0px;overflow:hidden}[data-ax5uploader-progressbox].warning .ax-progressbox-body .ax-progressbox-buttons{text-align:right;padding:5px 0px 0px 0px}[data-ax5uploader-progressbox].warning .ax-progressbox-body .ax-progressbox-buttons button.btn{padding:3px 7px;font-size:.8em}[data-ax5uploader-progressbox].warning .ax-progressbox-body .ax-progressbox-buttons button:not(:last-child){margin-right:3px}[data-ax5uploader-progressbox].warning.direction-top .ax-progressbox-arrow{position:absolute;width:0;height:0;left:50%;top:0}[data-ax5uploader-progressbox].warning.direction-top .ax-progressbox-arrow:before{content:' ';position:absolute;width:0;height:0;left:-6px;top:-12px;border-left:6px solid transparent;border-right:6px solid transparent;border-top:0 none;border-bottom:12px solid #faebcc}[data-ax5uploader-progressbox].warning.direction-top .ax-progressbox-arrow:after{content:' ';position:absolute;width:0;height:0;left:-6px;top:-10px;border-left:6px solid transparent;border-right:6px solid transparent;border-top:0 none;border-bottom:12px solid #fff}[data-ax5uploader-progressbox].warning.direction-right .ax-progressbox-arrow{position:absolute;width:0;height:0;right:0;top:50%}[data-ax5uploader-progressbox].warning.direction-right .ax-progressbox-arrow:before{content:' ';position:absolute;width:0;height:0;right:-12px;top:-6px;border-left:12px solid #faebcc;border-right:0 none;border-top:6px solid transparent;border-bottom:6px solid transparent}[data-ax5uploader-progressbox].warning.direction-right .ax-progressbox-arrow:after{content:' ';position:absolute;width:0;height:0;right:-10px;top:-6px;border-left:12px solid #fff;border-right:0 none;border-top:6px solid transparent;border-bottom:6px solid transparent}[data-ax5uploader-progressbox].warning.direction-bottom .ax-progressbox-arrow{position:absolute;width:0;height:0;left:50%;bottom:0}[data-ax5uploader-progressbox].warning.direction-bottom .ax-progressbox-arrow:before{content:' ';position:absolute;width:0;height:0;left:-6px;bottom:-12px;border-left:6px solid transparent;border-right:6px solid transparent;border-top:12px solid #faebcc;border-bottom:0 none}[data-ax5uploader-progressbox].warning.direction-bottom .ax-progressbox-arrow:after{content:' ';position:absolute;width:0;height:0;left:-6px;bottom:-10px;border-left:6px solid transparent;border-right:6px solid transparent;border-top:12px solid #fff;border-bottom:0 none}[data-ax5uploader-progressbox].warning.direction-left .ax-progressbox-arrow{position:absolute;width:0;height:0;left:0;top:50%}[data-ax5uploader-progressbox].warning.direction-left .ax-progressbox-arrow:before{content:' ';position:absolute;width:0;height:0;left:-12px;top:-6px;border-left:0 none;border-right:12px solid #faebcc;border-top:6px solid transparent;border-bottom:6px solid transparent}[data-ax5uploader-progressbox].warning.direction-left .ax-progressbox-arrow:after{content:' ';position:absolute;width:0;height:0;left:-10px;top:-6px;border-left:0 none;border-right:12px solid #fff;border-top:6px solid transparent;border-bottom:6px solid transparent}[data-ax5uploader-progressbox].danger{background-color:#fff;background-image:-webkit-linear-gradient(bottom, #fff);background-image:linear-gradient(to top,#fff);border:1px solid;border-color:#ebccd1;border-radius:5px;box-shadow:0px 0px 3px 0px rgba(0,0,0,0.175)}[data-ax5uploader-progressbox].danger .ax-progressbox-body{padding:10px;text-align:center}[data-ax5uploader-progressbox].danger .ax-progressbox-body .ax-picker-content{min-width:50px}[data-ax5uploader-progressbox].danger .ax-progressbox-body .ax-picker-content .ax-picker-progressbox-box{border:0px solid;border-color:none;border-radius:0px;padding:0px;overflow:hidden}[data-ax5uploader-progressbox].danger .ax-progressbox-body .ax-progressbox-buttons{text-align:right;padding:5px 0px 0px 0px}[data-ax5uploader-progressbox].danger .ax-progressbox-body .ax-progressbox-buttons button.btn{padding:3px 7px;font-size:.8em}[data-ax5uploader-progressbox].danger .ax-progressbox-body .ax-progressbox-buttons button:not(:last-child){margin-right:3px}[data-ax5uploader-progressbox].danger.direction-top .ax-progressbox-arrow{position:absolute;width:0;height:0;left:50%;top:0}[data-ax5uploader-progressbox].danger.direction-top .ax-progressbox-arrow:before{content:' ';position:absolute;width:0;height:0;left:-6px;top:-12px;border-left:6px solid transparent;border-right:6px solid transparent;border-top:0 none;border-bottom:12px solid #ebccd1}[data-ax5uploader-progressbox].danger.direction-top .ax-progressbox-arrow:after{content:' ';position:absolute;width:0;height:0;left:-6px;top:-10px;border-left:6px solid transparent;border-right:6px solid transparent;border-top:0 none;border-bottom:12px solid #fff}[data-ax5uploader-progressbox].danger.direction-right .ax-progressbox-arrow{position:absolute;width:0;height:0;right:0;top:50%}[data-ax5uploader-progressbox].danger.direction-right .ax-progressbox-arrow:before{content:' ';position:absolute;width:0;height:0;right:-12px;top:-6px;border-left:12px solid #ebccd1;border-right:0 none;border-top:6px solid transparent;border-bottom:6px solid transparent}[data-ax5uploader-progressbox].danger.direction-right .ax-progressbox-arrow:after{content:' ';position:absolute;width:0;height:0;right:-10px;top:-6px;border-left:12px solid #fff;border-right:0 none;border-top:6px solid transparent;border-bottom:6px solid transparent}[data-ax5uploader-progressbox].danger.direction-bottom .ax-progressbox-arrow{position:absolute;width:0;height:0;left:50%;bottom:0}[data-ax5uploader-progressbox].danger.direction-bottom .ax-progressbox-arrow:before{content:' ';position:absolute;width:0;height:0;left:-6px;bottom:-12px;border-left:6px solid transparent;border-right:6px solid transparent;border-top:12px solid #ebccd1;border-bottom:0 none}[data-ax5uploader-progressbox].danger.direction-bottom .ax-progressbox-arrow:after{content:' ';position:absolute;width:0;height:0;left:-6px;bottom:-10px;border-left:6px solid transparent;border-right:6px solid transparent;border-top:12px solid #fff;border-bottom:0 none}[data-ax5uploader-progressbox].danger.direction-left .ax-progressbox-arrow{position:absolute;width:0;height:0;left:0;top:50%}[data-ax5uploader-progressbox].danger.direction-left .ax-progressbox-arrow:before{content:' ';position:absolute;width:0;height:0;left:-12px;top:-6px;border-left:0 none;border-right:12px solid #ebccd1;border-top:6px solid transparent;border-bottom:6px solid transparent}[data-ax5uploader-progressbox].danger.direction-left .ax-progressbox-arrow:after{content:' ';position:absolute;width:0;height:0;left:-10px;top:-6px;border-left:0 none;border-right:12px solid #fff;border-top:6px solid transparent;border-bottom:6px solid transparent}[data-ax5uploader-progressbox].destroy{-webkit-animation:ax-progressbox-destroy .1s cubic-bezier(0.6, -0.28, 0.735, 0.045) forwards;-moz-animation:ax-progressbox-destroy .1s cubic-bezier(0.6, -0.28, 0.735, 0.045) forwards;animation:ax-progressbox-destroy .1s cubic-bezier(0.6, -0.28, 0.735, 0.045) forwards}[data-ax5uploader-progressbox].direction-top{-webkit-transform-origin:center top;-moz-transform-origin:center top;-ms-transform-origin:center top;-o-transform-origin:center top;transform-origin:center top}[data-ax5uploader-progressbox].direction-right{-webkit-transform-origin:right center;-moz-transform-origin:right center;-ms-transform-origin:right center;-o-transform-origin:right center;transform-origin:right center}[data-ax5uploader-progressbox].direction-bottom{-webkit-transform-origin:center bottom;-moz-transform-origin:center bottom;-ms-transform-origin:center bottom;-o-transform-origin:center bottom;transform-origin:center bottom}[data-ax5uploader-progressbox].direction-left{-webkit-transform-origin:left center;-moz-transform-origin:left center;-ms-transform-origin:left center;-o-transform-origin:left center;transform-origin:left center} [data-ax5combobox] select[multiple].form-control{height:34px}[data-ax5combobox] select[multiple].input-sm{height:30px}[data-ax5combobox] select[multiple].input-lg{height:46px}.form-group-sm [data-ax5combobox] select[multiple].form-control{height:30px}.form-group-lg [data-ax5combobox] select[multiple].form-control{height:46px}@media (min-width: 768px){.form-inline [data-ax5combobox]{display:inline-block}.form-inline [data-ax5combobox] .ax5combobox-display .ax5combobox-display-table{table-layout:auto}}[data-ax5combobox]{position:relative;overflow:visible;display:block;margin:0px}[data-ax5combobox] select{z-index:1;position:absolute;opacity:0;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none}@-webkit-keyframes ax-combobox-option-group{from{-webkit-transform:translateY(-10%);opacity:0}to{-webkit-transform:translateY(0%);opacity:1}}@-moz-keyframes ax-combobox-option-group{from{-moz-transform:translateY(-10%);opacity:0}to{-moz-transform:translateY(0%);opacity:1}}@keyframes ax-combobox-option-group{from{-webkit-transform:translateY(-10%);-moz-transform:translateY(-10%);-ms-transform:translateY(-10%);-o-transform:translateY(-10%);transform:translateY(-10%);opacity:0}to{-webkit-transform:translateY(0%);-moz-transform:translateY(0%);-ms-transform:translateY(0%);-o-transform:translateY(0%);transform:translateY(0%);opacity:1}}@-webkit-keyframes ax-combobox-option-group-destroy{from{-webkit-transform:translateY(0%) scaleY(1);opacity:1}to{-webkit-transform:translateY(0%) scaleY(0);opacity:0}}@-moz-keyframes ax-combobox-option-group-destroy{from{-moz-transform:translateY(0%) scaleY(1);opacity:1}to{-moz-transform:translateY(0%) scaleY(0);opacity:0}}@keyframes ax-combobox-option-group-destroy{from{-webkit-transform:translateY(0%) scaleY(1);-moz-transform:translateY(0%) scaleY(1);-ms-transform:translateY(0%) scaleY(1);-o-transform:translateY(0%) scaleY(1);transform:translateY(0%) scaleY(1);opacity:1}to{-webkit-transform:translateY(0%) scaleY(0);-moz-transform:translateY(0%) scaleY(0);-ms-transform:translateY(0%) scaleY(0);-o-transform:translateY(0%) scaleY(0);transform:translateY(0%) scaleY(0);opacity:0}}.ax5combobox-display{position:relative;z-index:2;padding:0px;display:block}.ax5combobox-display:hover,.ax5combobox-display:focus{text-decoration:none}.ax5combobox-display .ax5combobox-display-table{width:100%;height:100%;display:table;table-layout:fixed;border-collapse:collapse}.ax5combobox-display .ax5combobox-display-table [data-ax5combobox-display="label-holder"]{display:table-cell;vertical-align:middle;padding:0px 0px}.ax5combobox-display .ax5combobox-display-table [data-ax5combobox-display="label"]{display:block;white-space:nowrap;overflow:hidden;padding:0px 7px;text-decoration:none}.ax5combobox-display .ax5combobox-display-table [data-ax5combobox-display="label"]:focus{outline:none}.ax5combobox-display .ax5combobox-display-table [data-ax5combobox-display="label"]:hover{text-decoration:none}.ax5combobox-display .ax5combobox-display-table [data-ax5combobox-display="label"]:after{content:' ';display:block;clear:both}.ax5combobox-display .ax5combobox-display-table [data-ax5combobox-display="label"] [data-ax5combobox-selected-label]{position:relative;display:block;float:left;background:transparent;padding:0px 3px;border:1px solid transparent;border-radius:0px;margin:1px 0px 1px -0.5em;background-color:#eee;background-image:-webkit-linear-gradient(top, #eee,#eee);background-image:linear-gradient(to bottom,#eee,#eee);border:1px solid #ccc;color:#444;border-radius:3px;margin-left:0px;margin-right:3px}.ax5combobox-display .ax5combobox-display-table [data-ax5combobox-display="label"] [data-ax5combobox-selected-label]:first-child{margin-left:0px}.ax5combobox-display .ax5combobox-display-table [data-ax5combobox-display="label"] [data-ax5combobox-selected-label] [data-ax5combobox-remove]{width:15px;position:absolute;right:0}.ax5combobox-display .ax5combobox-display-table [data-ax5combobox-display="label"] [data-ax5combobox-selected-label] [data-ax5combobox-remove]:hover{color:#d9534f}.ax5combobox-display .ax5combobox-display-table [data-ax5combobox-display="label"] [data-ax5combobox-selected-label] span{padding-right:15px}.ax5combobox-display .ax5combobox-display-table [data-ax5combobox-display="label"] [data-ax5combobox-display="input"]{float:left;width:100px}.ax5combobox-display .ax5combobox-display-table [data-ax5combobox-display="label"] [data-ax5combobox-display="input"]:focus{outline:none}.ax5combobox-display .ax5combobox-display-table [data-ax5combobox-display="label"] [data-ax5combobox-display="input"]::-ms-clear{display:none}.ax5combobox-display .ax5combobox-display-table [data-ax5combobox-display="addon"]{display:table-cell;vertical-align:middle;width:16px;text-align:center}.ax5combobox-display .ax5combobox-display-table [data-ax5combobox-display="addon"] .addon-icon-reset{display:none}.ax5combobox-display .ax5combobox-display-table [data-ax5combobox-display="addon"] .addon-icon-closed{display:block}.ax5combobox-display .ax5combobox-display-table [data-ax5combobox-display="addon"] .addon-icon-opened{display:none}.ax5combobox-display .ax5combobox-display-table [data-ax5combobox-display="addon"] .addon-icon-closed{width:16px;text-align:left;line-height:6.363px}.ax5combobox-display .ax5combobox-display-table [data-ax5combobox-display="addon"] .addon-icon-closed .addon-icon-arrow{content:'';width:0px;height:0px;display:inline-block;border-left:4.5px solid transparent;border-right:4.5px solid transparent;border-top:6.363px solid #444;background:transparent;opacity:1}.ax5combobox-display .ax5combobox-display-table [data-ax5combobox-display="addon"] .addon-icon-opened{width:16px;text-align:left;line-height:6.363px}.ax5combobox-display .ax5combobox-display-table [data-ax5combobox-display="addon"] .addon-icon-opened .addon-icon-arrow{content:'';width:0px;height:0px;display:inline-block;border-left:4.5px solid transparent;border-right:4.5px solid transparent;border-bottom:6.363px solid #444;background:transparent;opacity:1}.ax5combobox-display[data-select-option-group-opened]{box-shadow:inset 1px 1px 3px rgba(0,0,0,0.2)}.ax5combobox-display[data-select-option-group-opened] .ax5combobox-display-table [data-ax5combobox-display="addon"] .addon-icon-reset{display:block;position:absolute;right:23px;top:0px;height:100%}.ax5combobox-display[data-select-option-group-opened] .ax5combobox-display-table [data-ax5combobox-display="addon"] .addon-icon-closed{display:none}.ax5combobox-display[data-select-option-group-opened] .ax5combobox-display-table [data-ax5combobox-display="addon"] .addon-icon-opened{display:block}.ax5combobox-display.default a{color:#555}.ax5combobox-display.default:hover:not([disabled]),.ax5combobox-display.default:active:not([disabled]),.ax5combobox-display.default:focus:not([disabled]),.ax5combobox-display.default[data-select-option-group-opened]:not([disabled]){border-color:#ccc;color:#555;background:#fbfbfb;text-decoration:none}.ax5combobox-display.default:hover:not([disabled]) .ax5combobox-display-table [data-ax5-select-display="addon"] .addon-icon-closed .addon-icon-arrow,.ax5combobox-display.default:active:not([disabled]) .ax5combobox-display-table [data-ax5-select-display="addon"] .addon-icon-closed .addon-icon-arrow,.ax5combobox-display.default:focus:not([disabled]) .ax5combobox-display-table [data-ax5-select-display="addon"] .addon-icon-closed .addon-icon-arrow,.ax5combobox-display.default[data-select-option-group-opened]:not([disabled]) .ax5combobox-display-table [data-ax5-select-display="addon"] .addon-icon-closed .addon-icon-arrow{border-top-color:#555}.ax5combobox-display.default:hover:not([disabled]) .ax5combobox-display-table [data-ax5-select-display="addon"] .addon-icon-opened .addon-icon-arrow,.ax5combobox-display.default:active:not([disabled]) .ax5combobox-display-table [data-ax5-select-display="addon"] .addon-icon-opened .addon-icon-arrow,.ax5combobox-display.default:focus:not([disabled]) .ax5combobox-display-table [data-ax5-select-display="addon"] .addon-icon-opened .addon-icon-arrow,.ax5combobox-display.default[data-select-option-group-opened]:not([disabled]) .ax5combobox-display-table [data-ax5-select-display="addon"] .addon-icon-opened .addon-icon-arrow{border-bottom-color:#555}.ax5combobox-display.default [disabled]{-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none}.ax5combobox-display.primary a{color:#555}.ax5combobox-display.primary:hover:not([disabled]),.ax5combobox-display.primary:active:not([disabled]),.ax5combobox-display.primary:focus:not([disabled]),.ax5combobox-display.primary[data-select-option-group-opened]:not([disabled]){border-color:#337ab7;color:#555;background:#fbfbfb;text-decoration:none}.ax5combobox-display.primary:hover:not([disabled]) .ax5combobox-display-table [data-ax5-select-display="addon"] .addon-icon-closed .addon-icon-arrow,.ax5combobox-display.primary:active:not([disabled]) .ax5combobox-display-table [data-ax5-select-display="addon"] .addon-icon-closed .addon-icon-arrow,.ax5combobox-display.primary:focus:not([disabled]) .ax5combobox-display-table [data-ax5-select-display="addon"] .addon-icon-closed .addon-icon-arrow,.ax5combobox-display.primary[data-select-option-group-opened]:not([disabled]) .ax5combobox-display-table [data-ax5-select-display="addon"] .addon-icon-closed .addon-icon-arrow{border-top-color:#555}.ax5combobox-display.primary:hover:not([disabled]) .ax5combobox-display-table [data-ax5-select-display="addon"] .addon-icon-opened .addon-icon-arrow,.ax5combobox-display.primary:active:not([disabled]) .ax5combobox-display-table [data-ax5-select-display="addon"] .addon-icon-opened .addon-icon-arrow,.ax5combobox-display.primary:focus:not([disabled]) .ax5combobox-display-table [data-ax5-select-display="addon"] .addon-icon-opened .addon-icon-arrow,.ax5combobox-display.primary[data-select-option-group-opened]:not([disabled]) .ax5combobox-display-table [data-ax5-select-display="addon"] .addon-icon-opened .addon-icon-arrow{border-bottom-color:#555}.ax5combobox-display.primary [disabled]{-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none}.ax5combobox-display.success a{color:#555}.ax5combobox-display.success:hover:not([disabled]),.ax5combobox-display.success:active:not([disabled]),.ax5combobox-display.success:focus:not([disabled]),.ax5combobox-display.success[data-select-option-group-opened]:not([disabled]){border-color:#5cb85c;color:#555;background:#fbfbfb;text-decoration:none}.ax5combobox-display.success:hover:not([disabled]) .ax5combobox-display-table [data-ax5-select-display="addon"] .addon-icon-closed .addon-icon-arrow,.ax5combobox-display.success:active:not([disabled]) .ax5combobox-display-table [data-ax5-select-display="addon"] .addon-icon-closed .addon-icon-arrow,.ax5combobox-display.success:focus:not([disabled]) .ax5combobox-display-table [data-ax5-select-display="addon"] .addon-icon-closed .addon-icon-arrow,.ax5combobox-display.success[data-select-option-group-opened]:not([disabled]) .ax5combobox-display-table [data-ax5-select-display="addon"] .addon-icon-closed .addon-icon-arrow{border-top-color:#555}.ax5combobox-display.success:hover:not([disabled]) .ax5combobox-display-table [data-ax5-select-display="addon"] .addon-icon-opened .addon-icon-arrow,.ax5combobox-display.success:active:not([disabled]) .ax5combobox-display-table [data-ax5-select-display="addon"] .addon-icon-opened .addon-icon-arrow,.ax5combobox-display.success:focus:not([disabled]) .ax5combobox-display-table [data-ax5-select-display="addon"] .addon-icon-opened .addon-icon-arrow,.ax5combobox-display.success[data-select-option-group-opened]:not([disabled]) .ax5combobox-display-table [data-ax5-select-display="addon"] .addon-icon-opened .addon-icon-arrow{border-bottom-color:#555}.ax5combobox-display.success [disabled]{-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none}.ax5combobox-display.info a{color:#555}.ax5combobox-display.info:hover:not([disabled]),.ax5combobox-display.info:active:not([disabled]),.ax5combobox-display.info:focus:not([disabled]),.ax5combobox-display.info[data-select-option-group-opened]:not([disabled]){border-color:#5bc0de;color:#555;background:#fbfbfb;text-decoration:none}.ax5combobox-display.info:hover:not([disabled]) .ax5combobox-display-table [data-ax5-select-display="addon"] .addon-icon-closed .addon-icon-arrow,.ax5combobox-display.info:active:not([disabled]) .ax5combobox-display-table [data-ax5-select-display="addon"] .addon-icon-closed .addon-icon-arrow,.ax5combobox-display.info:focus:not([disabled]) .ax5combobox-display-table [data-ax5-select-display="addon"] .addon-icon-closed .addon-icon-arrow,.ax5combobox-display.info[data-select-option-group-opened]:not([disabled]) .ax5combobox-display-table [data-ax5-select-display="addon"] .addon-icon-closed .addon-icon-arrow{border-top-color:#555}.ax5combobox-display.info:hover:not([disabled]) .ax5combobox-display-table [data-ax5-select-display="addon"] .addon-icon-opened .addon-icon-arrow,.ax5combobox-display.info:active:not([disabled]) .ax5combobox-display-table [data-ax5-select-display="addon"] .addon-icon-opened .addon-icon-arrow,.ax5combobox-display.info:focus:not([disabled]) .ax5combobox-display-table [data-ax5-select-display="addon"] .addon-icon-opened .addon-icon-arrow,.ax5combobox-display.info[data-select-option-group-opened]:not([disabled]) .ax5combobox-display-table [data-ax5-select-display="addon"] .addon-icon-opened .addon-icon-arrow{border-bottom-color:#555}.ax5combobox-display.info [disabled]{-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none}.ax5combobox-display.warning a{color:#555}.ax5combobox-display.warning:hover:not([disabled]),.ax5combobox-display.warning:active:not([disabled]),.ax5combobox-display.warning:focus:not([disabled]),.ax5combobox-display.warning[data-select-option-group-opened]:not([disabled]){border-color:#f0ad4e;color:#555;background:#fbfbfb;text-decoration:none}.ax5combobox-display.warning:hover:not([disabled]) .ax5combobox-display-table [data-ax5-select-display="addon"] .addon-icon-closed .addon-icon-arrow,.ax5combobox-display.warning:active:not([disabled]) .ax5combobox-display-table [data-ax5-select-display="addon"] .addon-icon-closed .addon-icon-arrow,.ax5combobox-display.warning:focus:not([disabled]) .ax5combobox-display-table [data-ax5-select-display="addon"] .addon-icon-closed .addon-icon-arrow,.ax5combobox-display.warning[data-select-option-group-opened]:not([disabled]) .ax5combobox-display-table [data-ax5-select-display="addon"] .addon-icon-closed .addon-icon-arrow{border-top-color:#555}.ax5combobox-display.warning:hover:not([disabled]) .ax5combobox-display-table [data-ax5-select-display="addon"] .addon-icon-opened .addon-icon-arrow,.ax5combobox-display.warning:active:not([disabled]) .ax5combobox-display-table [data-ax5-select-display="addon"] .addon-icon-opened .addon-icon-arrow,.ax5combobox-display.warning:focus:not([disabled]) .ax5combobox-display-table [data-ax5-select-display="addon"] .addon-icon-opened .addon-icon-arrow,.ax5combobox-display.warning[data-select-option-group-opened]:not([disabled]) .ax5combobox-display-table [data-ax5-select-display="addon"] .addon-icon-opened .addon-icon-arrow{border-bottom-color:#555}.ax5combobox-display.warning [disabled]{-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none}.ax5combobox-display.danger a{color:#555}.ax5combobox-display.danger:hover:not([disabled]),.ax5combobox-display.danger:active:not([disabled]),.ax5combobox-display.danger:focus:not([disabled]),.ax5combobox-display.danger[data-select-option-group-opened]:not([disabled]){border-color:#d9534f;color:#555;background:#fbfbfb;text-decoration:none}.ax5combobox-display.danger:hover:not([disabled]) .ax5combobox-display-table [data-ax5-select-display="addon"] .addon-icon-closed .addon-icon-arrow,.ax5combobox-display.danger:active:not([disabled]) .ax5combobox-display-table [data-ax5-select-display="addon"] .addon-icon-closed .addon-icon-arrow,.ax5combobox-display.danger:focus:not([disabled]) .ax5combobox-display-table [data-ax5-select-display="addon"] .addon-icon-closed .addon-icon-arrow,.ax5combobox-display.danger[data-select-option-group-opened]:not([disabled]) .ax5combobox-display-table [data-ax5-select-display="addon"] .addon-icon-closed .addon-icon-arrow{border-top-color:#555}.ax5combobox-display.danger:hover:not([disabled]) .ax5combobox-display-table [data-ax5-select-display="addon"] .addon-icon-opened .addon-icon-arrow,.ax5combobox-display.danger:active:not([disabled]) .ax5combobox-display-table [data-ax5-select-display="addon"] .addon-icon-opened .addon-icon-arrow,.ax5combobox-display.danger:focus:not([disabled]) .ax5combobox-display-table [data-ax5-select-display="addon"] .addon-icon-opened .addon-icon-arrow,.ax5combobox-display.danger[data-select-option-group-opened]:not([disabled]) .ax5combobox-display-table [data-ax5-select-display="addon"] .addon-icon-opened .addon-icon-arrow{border-bottom-color:#555}.ax5combobox-display.danger [disabled]{-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none}.ax5combobox-option-group{box-sizing:border-box;z-index:2000;position:absolute;left:0;top:0;border-radius:5px;box-shadow:0px 0px 3px 0px rgba(0,0,0,0.175);border:1px solid;overflow:hidden;background-color:#fbfbfb;background-image:-webkit-linear-gradient(bottom, #fbfbfb);background-image:linear-gradient(to top,#fbfbfb);-webkit-animation:ax-combobox-option-group .1s ease-out;-moz-animation:ax-combobox-option-group .1s ease-out;animation:ax-combobox-option-group .1s ease-out;-webkit-transform:translateZ(0);-moz-transform:translateZ(0);-ms-transform:translateZ(0);-o-transform:translateZ(0);transform:translateZ(0);-webkit-transform-origin:center top;-moz-transform-origin:center top;-ms-transform-origin:center top;-o-transform-origin:center top;transform-origin:center top}.ax5combobox-option-group.destroy{-webkit-animation:ax-combobox-option-group-destroy .1s cubic-bezier(0.6, -0.28, 0.735, 0.045) forwards;-moz-animation:ax-combobox-option-group-destroy .1s cubic-bezier(0.6, -0.28, 0.735, 0.045) forwards;animation:ax-combobox-option-group-destroy .1s cubic-bezier(0.6, -0.28, 0.735, 0.045) forwards}.ax5combobox-option-group.direction-top{-webkit-transform-origin:center top;-moz-transform-origin:center top;-ms-transform-origin:center top;-o-transform-origin:center top;transform-origin:center top}.ax5combobox-option-group.direction-bottom{-webkit-transform-origin:center bottom;-moz-transform-origin:center bottom;-ms-transform-origin:center bottom;-o-transform-origin:center bottom;transform-origin:center bottom}.ax5combobox-option-group.default{border-color:#ccc;color:#555}.ax5combobox-option-group.default .ax-combobox-body .ax-combobox-option-group-content .ax-combobox-option-item:hover,.ax5combobox-option-group.default .ax-combobox-body .ax-combobox-option-group-content .ax-combobox-option-item.hover{background:#a6a6a6 !important;color:#222}.ax5combobox-option-group.default .ax-combobox-body .ax-combobox-option-group-content .ax-combobox-option-item:hover .ax-combobox-option-item-holder .ax-combobox-option-item-cell.ax-combobox-option-item-checkbox .item-checkbox-wrap.useCheckBox:after,.ax5combobox-option-group.default .ax-combobox-body .ax-combobox-option-group-content .ax-combobox-option-item.hover .ax-combobox-option-item-holder .ax-combobox-option-item-cell.ax-combobox-option-item-checkbox .item-checkbox-wrap.useCheckBox:after{border-color:#222 !important}.ax5combobox-option-group.default .ax-combobox-body .ax-combobox-option-group-content .ax-combobox-option-item[data-option-selected="true"]{background:#ccc;color:#222}.ax5combobox-option-group.default .ax-combobox-body .ax-combobox-option-group-content .ax-combobox-option-item[data-option-selected="true"] .ax-combobox-option-item-holder .ax-combobox-option-item-cell.ax-combobox-option-item-checkbox .item-checkbox-wrap.useCheckBox:after{border-color:#222 !important}.ax5combobox-option-group.default .ax-combobox-body .ax-combobox-option-group-content .ax-combobox-option-group .ax-combobox-option-item-holder .ax-combobox-option-group-label{background:#eee}.ax5combobox-option-group.default .ax-combobox-body .ax-combobox-option-group-buttons{border-top:1px solid;border-color:#ccc}.ax5combobox-option-group.primary{border-color:#337ab7;color:#555}.ax5combobox-option-group.primary .ax-combobox-body .ax-combobox-option-group-content .ax-combobox-option-item:hover,.ax5combobox-option-group.primary .ax-combobox-body .ax-combobox-option-group-content .ax-combobox-option-item.hover{background:#64a0d3 !important;color:#fff}.ax5combobox-option-group.primary .ax-combobox-body .ax-combobox-option-group-content .ax-combobox-option-item:hover .ax-combobox-option-item-holder .ax-combobox-option-item-cell.ax-combobox-option-item-checkbox .item-checkbox-wrap.useCheckBox:after,.ax5combobox-option-group.primary .ax-combobox-body .ax-combobox-option-group-content .ax-combobox-option-item.hover .ax-combobox-option-item-holder .ax-combobox-option-item-cell.ax-combobox-option-item-checkbox .item-checkbox-wrap.useCheckBox:after{border-color:#fff !important}.ax5combobox-option-group.primary .ax-combobox-body .ax-combobox-option-group-content .ax-combobox-option-item[data-option-selected="true"]{background:#337ab7;color:#fff}.ax5combobox-option-group.primary .ax-combobox-body .ax-combobox-option-group-content .ax-combobox-option-item[data-option-selected="true"] .ax-combobox-option-item-holder .ax-combobox-option-item-cell.ax-combobox-option-item-checkbox .item-checkbox-wrap.useCheckBox:after{border-color:#fff !important}.ax5combobox-option-group.primary .ax-combobox-body .ax-combobox-option-group-content .ax-combobox-option-group .ax-combobox-option-item-holder .ax-combobox-option-group-label{background:#eee}.ax5combobox-option-group.primary .ax-combobox-body .ax-combobox-option-group-buttons{border-top:1px solid;border-color:#337ab7}.ax5combobox-option-group.success{border-color:#5cb85c;color:#555}.ax5combobox-option-group.success .ax-combobox-body .ax-combobox-option-group-content .ax-combobox-option-item:hover,.ax5combobox-option-group.success .ax-combobox-body .ax-combobox-option-group-content .ax-combobox-option-item.hover{background:#3d8b3d !important;color:#222}.ax5combobox-option-group.success .ax-combobox-body .ax-combobox-option-group-content .ax-combobox-option-item:hover .ax-combobox-option-item-holder .ax-combobox-option-item-cell.ax-combobox-option-item-checkbox .item-checkbox-wrap.useCheckBox:after,.ax5combobox-option-group.success .ax-combobox-body .ax-combobox-option-group-content .ax-combobox-option-item.hover .ax-combobox-option-item-holder .ax-combobox-option-item-cell.ax-combobox-option-item-checkbox .item-checkbox-wrap.useCheckBox:after{border-color:#222 !important}.ax5combobox-option-group.success .ax-combobox-body .ax-combobox-option-group-content .ax-combobox-option-item[data-option-selected="true"]{background:#5cb85c;color:#222}.ax5combobox-option-group.success .ax-combobox-body .ax-combobox-option-group-content .ax-combobox-option-item[data-option-selected="true"] .ax-combobox-option-item-holder .ax-combobox-option-item-cell.ax-combobox-option-item-checkbox .item-checkbox-wrap.useCheckBox:after{border-color:#222 !important}.ax5combobox-option-group.success .ax-combobox-body .ax-combobox-option-group-content .ax-combobox-option-group .ax-combobox-option-item-holder .ax-combobox-option-group-label{background:#eee}.ax5combobox-option-group.success .ax-combobox-body .ax-combobox-option-group-buttons{border-top:1px solid;border-color:#5cb85c}.ax5combobox-option-group.info{border-color:#5bc0de;color:#555}.ax5combobox-option-group.info .ax-combobox-body .ax-combobox-option-group-content .ax-combobox-option-item:hover,.ax5combobox-option-group.info .ax-combobox-body .ax-combobox-option-group-content .ax-combobox-option-item.hover{background:#9bd8eb !important;color:#fff}.ax5combobox-option-group.info .ax-combobox-body .ax-combobox-option-group-content .ax-combobox-option-item:hover .ax-combobox-option-item-holder .ax-combobox-option-item-cell.ax-combobox-option-item-checkbox .item-checkbox-wrap.useCheckBox:after,.ax5combobox-option-group.info .ax-combobox-body .ax-combobox-option-group-content .ax-combobox-option-item.hover .ax-combobox-option-item-holder .ax-combobox-option-item-cell.ax-combobox-option-item-checkbox .item-checkbox-wrap.useCheckBox:after{border-color:#fff !important}.ax5combobox-option-group.info .ax-combobox-body .ax-combobox-option-group-content .ax-combobox-option-item[data-option-selected="true"]{background:#5bc0de;color:#fff}.ax5combobox-option-group.info .ax-combobox-body .ax-combobox-option-group-content .ax-combobox-option-item[data-option-selected="true"] .ax-combobox-option-item-holder .ax-combobox-option-item-cell.ax-combobox-option-item-checkbox .item-checkbox-wrap.useCheckBox:after{border-color:#fff !important}.ax5combobox-option-group.info .ax-combobox-body .ax-combobox-option-group-content .ax-combobox-option-group .ax-combobox-option-item-holder .ax-combobox-option-group-label{background:#eee}.ax5combobox-option-group.info .ax-combobox-body .ax-combobox-option-group-buttons{border-top:1px solid;border-color:#5bc0de}.ax5combobox-option-group.warning{border-color:#f0ad4e;color:#555}.ax5combobox-option-group.warning .ax-combobox-body .ax-combobox-option-group-content .ax-combobox-option-item:hover,.ax5combobox-option-group.warning .ax-combobox-body .ax-combobox-option-group-content .ax-combobox-option-item.hover{background:#f6ce95 !important;color:#fff}.ax5combobox-option-group.warning .ax-combobox-body .ax-combobox-option-group-content .ax-combobox-option-item:hover .ax-combobox-option-item-holder .ax-combobox-option-item-cell.ax-combobox-option-item-checkbox .item-checkbox-wrap.useCheckBox:after,.ax5combobox-option-group.warning .ax-combobox-body .ax-combobox-option-group-content .ax-combobox-option-item.hover .ax-combobox-option-item-holder .ax-combobox-option-item-cell.ax-combobox-option-item-checkbox .item-checkbox-wrap.useCheckBox:after{border-color:#fff !important}.ax5combobox-option-group.warning .ax-combobox-body .ax-combobox-option-group-content .ax-combobox-option-item[data-option-selected="true"]{background:#f0ad4e;color:#fff}.ax5combobox-option-group.warning .ax-combobox-body .ax-combobox-option-group-content .ax-combobox-option-item[data-option-selected="true"] .ax-combobox-option-item-holder .ax-combobox-option-item-cell.ax-combobox-option-item-checkbox .item-checkbox-wrap.useCheckBox:after{border-color:#fff !important}.ax5combobox-option-group.warning .ax-combobox-body .ax-combobox-option-group-content .ax-combobox-option-group .ax-combobox-option-item-holder .ax-combobox-option-group-label{background:#eee}.ax5combobox-option-group.warning .ax-combobox-body .ax-combobox-option-group-buttons{border-top:1px solid;border-color:#f0ad4e}.ax5combobox-option-group.danger{border-color:#d9534f;color:#555}.ax5combobox-option-group.danger .ax-combobox-body .ax-combobox-option-group-content .ax-combobox-option-item:hover,.ax5combobox-option-group.danger .ax-combobox-body .ax-combobox-option-group-content .ax-combobox-option-item.hover{background:#e7908e !important;color:#fff}.ax5combobox-option-group.danger .ax-combobox-body .ax-combobox-option-group-content .ax-combobox-option-item:hover .ax-combobox-option-item-holder .ax-combobox-option-item-cell.ax-combobox-option-item-checkbox .item-checkbox-wrap.useCheckBox:after,.ax5combobox-option-group.danger .ax-combobox-body .ax-combobox-option-group-content .ax-combobox-option-item.hover .ax-combobox-option-item-holder .ax-combobox-option-item-cell.ax-combobox-option-item-checkbox .item-checkbox-wrap.useCheckBox:after{border-color:#fff !important}.ax5combobox-option-group.danger .ax-combobox-body .ax-combobox-option-group-content .ax-combobox-option-item[data-option-selected="true"]{background:#d9534f;color:#fff}.ax5combobox-option-group.danger .ax-combobox-body .ax-combobox-option-group-content .ax-combobox-option-item[data-option-selected="true"] .ax-combobox-option-item-holder .ax-combobox-option-item-cell.ax-combobox-option-item-checkbox .item-checkbox-wrap.useCheckBox:after{border-color:#fff !important}.ax5combobox-option-group.danger .ax-combobox-body .ax-combobox-option-group-content .ax-combobox-option-group .ax-combobox-option-item-holder .ax-combobox-option-group-label{background:#eee}.ax5combobox-option-group.danger .ax-combobox-body .ax-combobox-option-group-buttons{border-top:1px solid;border-color:#d9534f}.ax5combobox-option-group .ax-combobox-body{padding:0px}.ax5combobox-option-group .ax-combobox-body .ax-combobox-option-group-content{max-height:180px;overflow-y:auto;-webkit-overflow-scrolling:touch;position:relative}.ax5combobox-option-group .ax-combobox-body .ax-combobox-option-group-content .ax-combobox-option-item{padding:3px 0px;text-align:left;cursor:pointer;font-size:13px;position:relative;box-sizing:border-box;overflow:hidden}.ax5combobox-option-group .ax-combobox-body .ax-combobox-option-group-content .ax-combobox-option-item .ax-combobox-option-item-holder{display:table;position:relative;border-collapse:separate;overflow:hidden;width:100%;height:18px}.ax5combobox-option-group .ax-combobox-body .ax-combobox-option-group-content .ax-combobox-option-item .ax-combobox-option-item-holder .ax-combobox-option-item-cell{box-sizing:border-box;display:table-cell;vertical-align:middle;white-space:nowrap;font-size:13px;line-height:18px;padding:0px 0px 0px 0px;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none}.ax5combobox-option-group .ax-combobox-body .ax-combobox-option-group-content .ax-combobox-option-item .ax-combobox-option-item-holder .ax-combobox-option-item-cell.ax-combobox-option-item-checkbox{overflow:hidden;width:13px;text-align:center}.ax5combobox-option-group .ax-combobox-body .ax-combobox-option-group-content .ax-combobox-option-item .ax-combobox-option-item-holder .ax-combobox-option-item-cell.ax-combobox-option-item-checkbox .item-checkbox-wrap{position:relative;display:block;width:13px;height:18px}.ax5combobox-option-group .ax-combobox-body .ax-combobox-option-group-content .ax-combobox-option-item .ax-combobox-option-item-holder .ax-combobox-option-item-cell.ax-combobox-option-item-checkbox .item-checkbox-wrap.useCheckBox:after{content:'';width:9px;height:4.5px;position:absolute;top:4.5px;right:0px;border:2px solid #000;border-top:none;border-right:none;background:transparent;opacity:0.1;-webkit-transform:rotate(-50deg);-moz-transform:rotate(-50deg);-ms-transform:rotate(-50deg);-o-transform:rotate(-50deg);transform:rotate(-50deg)}.ax5combobox-option-group .ax-combobox-body .ax-combobox-option-group-content .ax-combobox-option-item .ax-combobox-option-item-holder .ax-combobox-option-item-cell.ax-combobox-option-item-label{padding:0px 7px;padding-right:9px}.ax5combobox-option-group .ax-combobox-body .ax-combobox-option-group-content .ax-combobox-option-item[data-option-selected="true"] .ax-combobox-option-item-holder .ax-combobox-option-item-cell.ax-combobox-option-item-checkbox .item-checkbox-wrap.useCheckBox:after{opacity:1}.ax5combobox-option-group .ax-combobox-body .ax-combobox-option-group-content .ax-combobox-option-group .ax-combobox-option-item-holder{display:table;position:relative;border-collapse:separate;overflow:hidden;width:100%;height:18px}.ax5combobox-option-group .ax-combobox-body .ax-combobox-option-group-content .ax-combobox-option-group .ax-combobox-option-item-holder .ax-combobox-option-group-label{box-sizing:border-box;display:table-cell;vertical-align:middle;white-space:nowrap;font-size:13px;line-height:18px;padding:5px 10px;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none}.ax5combobox-option-group .ax-combobox-body .ax-combobox-option-group-buttons{text-align:center;padding:3px 0px}.ax5combobox-option-group.ax5combobox-option-group-lg .ax-combobox-body{padding:0px}.ax5combobox-option-group.ax5combobox-option-group-lg .ax-combobox-body .ax-combobox-option-group-content{max-height:219px;overflow-y:auto;-webkit-overflow-scrolling:touch;position:relative}.ax5combobox-option-group.ax5combobox-option-group-lg .ax-combobox-body .ax-combobox-option-group-content .ax-combobox-option-item{padding:5px 0px;text-align:left;cursor:pointer;font-size:16.9px;position:relative;box-sizing:border-box;overflow:hidden}.ax5combobox-option-group.ax5combobox-option-group-lg .ax-combobox-body .ax-combobox-option-group-content .ax-combobox-option-item .ax-combobox-option-item-holder{display:table;position:relative;border-collapse:separate;overflow:hidden;width:100%;height:21.9px}.ax5combobox-option-group.ax5combobox-option-group-lg .ax-combobox-body .ax-combobox-option-group-content .ax-combobox-option-item .ax-combobox-option-item-holder .ax-combobox-option-item-cell{box-sizing:border-box;display:table-cell;vertical-align:middle;white-space:nowrap;font-size:16.9px;line-height:21.9px;padding:0px 0px 0px 0px;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none}.ax5combobox-option-group.ax5combobox-option-group-lg .ax-combobox-body .ax-combobox-option-group-content .ax-combobox-option-item .ax-combobox-option-item-holder .ax-combobox-option-item-cell.ax-combobox-option-item-checkbox{overflow:hidden;width:16.9px;text-align:center}.ax5combobox-option-group.ax5combobox-option-group-lg .ax-combobox-body .ax-combobox-option-group-content .ax-combobox-option-item .ax-combobox-option-item-holder .ax-combobox-option-item-cell.ax-combobox-option-item-checkbox .item-checkbox-wrap{position:relative;display:block;width:16.9px;height:21.9px}.ax5combobox-option-group.ax5combobox-option-group-lg .ax-combobox-body .ax-combobox-option-group-content .ax-combobox-option-item .ax-combobox-option-item-holder .ax-combobox-option-item-cell.ax-combobox-option-item-checkbox .item-checkbox-wrap.useCheckBox:after{content:'';width:12.9px;height:6.45px;position:absolute;top:5.475px;right:0px;border:2px solid #000;border-top:none;border-right:none;background:transparent;opacity:0.1;-webkit-transform:rotate(-50deg);-moz-transform:rotate(-50deg);-ms-transform:rotate(-50deg);-o-transform:rotate(-50deg);transform:rotate(-50deg)}.ax5combobox-option-group.ax5combobox-option-group-lg .ax-combobox-body .ax-combobox-option-group-content .ax-combobox-option-item .ax-combobox-option-item-holder .ax-combobox-option-item-cell.ax-combobox-option-item-label{padding:0px 7px;padding-right:12.9px}.ax5combobox-option-group.ax5combobox-option-group-lg .ax-combobox-body .ax-combobox-option-group-content .ax-combobox-option-item[data-option-selected="true"] .ax-combobox-option-item-holder .ax-combobox-option-item-cell.ax-combobox-option-item-checkbox .item-checkbox-wrap.useCheckBox:after{opacity:1}.ax5combobox-option-group.ax5combobox-option-group-lg .ax-combobox-body .ax-combobox-option-group-content .ax-combobox-option-group .ax-combobox-option-item-holder{display:table;position:relative;border-collapse:separate;overflow:hidden;width:100%;height:21.9px}.ax5combobox-option-group.ax5combobox-option-group-lg .ax-combobox-body .ax-combobox-option-group-content .ax-combobox-option-group .ax-combobox-option-item-holder .ax-combobox-option-group-label{box-sizing:border-box;display:table-cell;vertical-align:middle;white-space:nowrap;font-size:16.9px;line-height:21.9px;padding:5px 10px;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none}.ax5combobox-option-group.ax5combobox-option-group-lg .ax-combobox-body .ax-combobox-option-group-buttons{text-align:center;padding:5px 0px}.ax5combobox-option-group.ax5combobox-option-group-sm .ax-combobox-body{padding:0px}.ax5combobox-option-group.ax5combobox-option-group-sm .ax-combobox-body .ax-combobox-option-group-content{max-height:167px;overflow-y:auto;-webkit-overflow-scrolling:touch;position:relative}.ax5combobox-option-group.ax5combobox-option-group-sm .ax-combobox-body .ax-combobox-option-group-content .ax-combobox-option-item{padding:2px 0px;text-align:left;cursor:pointer;font-size:11.7px;position:relative;box-sizing:border-box;overflow:hidden}.ax5combobox-option-group.ax5combobox-option-group-sm .ax-combobox-body .ax-combobox-option-group-content .ax-combobox-option-item .ax-combobox-option-item-holder{display:table;position:relative;border-collapse:separate;overflow:hidden;width:100%;height:16.7px}.ax5combobox-option-group.ax5combobox-option-group-sm .ax-combobox-body .ax-combobox-option-group-content .ax-combobox-option-item .ax-combobox-option-item-holder .ax-combobox-option-item-cell{box-sizing:border-box;display:table-cell;vertical-align:middle;white-space:nowrap;font-size:11.7px;line-height:16.7px;padding:0px 0px 0px 0px;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none}.ax5combobox-option-group.ax5combobox-option-group-sm .ax-combobox-body .ax-combobox-option-group-content .ax-combobox-option-item .ax-combobox-option-item-holder .ax-combobox-option-item-cell.ax-combobox-option-item-checkbox{overflow:hidden;width:11.7px;text-align:center}.ax5combobox-option-group.ax5combobox-option-group-sm .ax-combobox-body .ax-combobox-option-group-content .ax-combobox-option-item .ax-combobox-option-item-holder .ax-combobox-option-item-cell.ax-combobox-option-item-checkbox .item-checkbox-wrap{position:relative;display:block;width:11.7px;height:16.7px}.ax5combobox-option-group.ax5combobox-option-group-sm .ax-combobox-body .ax-combobox-option-group-content .ax-combobox-option-item .ax-combobox-option-item-holder .ax-combobox-option-item-cell.ax-combobox-option-item-checkbox .item-checkbox-wrap.useCheckBox:after{content:'';width:7.7px;height:3.85px;position:absolute;top:4.175px;right:0px;border:2px solid #000;border-top:none;border-right:none;background:transparent;opacity:0.1;-webkit-transform:rotate(-50deg);-moz-transform:rotate(-50deg);-ms-transform:rotate(-50deg);-o-transform:rotate(-50deg);transform:rotate(-50deg)}.ax5combobox-option-group.ax5combobox-option-group-sm .ax-combobox-body .ax-combobox-option-group-content .ax-combobox-option-item .ax-combobox-option-item-holder .ax-combobox-option-item-cell.ax-combobox-option-item-label{padding:0px 7px;padding-right:7.7px}.ax5combobox-option-group.ax5combobox-option-group-sm .ax-combobox-body .ax-combobox-option-group-content .ax-combobox-option-item[data-option-selected="true"] .ax-combobox-option-item-holder .ax-combobox-option-item-cell.ax-combobox-option-item-checkbox .item-checkbox-wrap.useCheckBox:after{opacity:1}.ax5combobox-option-group.ax5combobox-option-group-sm .ax-combobox-body .ax-combobox-option-group-content .ax-combobox-option-group .ax-combobox-option-item-holder{display:table;position:relative;border-collapse:separate;overflow:hidden;width:100%;height:16.7px}.ax5combobox-option-group.ax5combobox-option-group-sm .ax-combobox-body .ax-combobox-option-group-content .ax-combobox-option-group .ax-combobox-option-item-holder .ax-combobox-option-group-label{box-sizing:border-box;display:table-cell;vertical-align:middle;white-space:nowrap;font-size:11.7px;line-height:16.7px;padding:5px 10px;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none}.ax5combobox-option-group.ax5combobox-option-group-sm .ax-combobox-body .ax-combobox-option-group-buttons{text-align:center;padding:2px 0px}.ax5combobox-option-group.ax5combobox-option-group-xs .ax-combobox-body{padding:0px}.ax5combobox-option-group.ax5combobox-option-group-xs .ax-combobox-body .ax-combobox-option-group-content{max-height:154px;overflow-y:auto;-webkit-overflow-scrolling:touch;position:relative}.ax5combobox-option-group.ax5combobox-option-group-xs .ax-combobox-body .ax-combobox-option-group-content .ax-combobox-option-item{padding:1px 0px;text-align:left;cursor:pointer;font-size:10.4px;position:relative;box-sizing:border-box;overflow:hidden}.ax5combobox-option-group.ax5combobox-option-group-xs .ax-combobox-body .ax-combobox-option-group-content .ax-combobox-option-item .ax-combobox-option-item-holder{display:table;position:relative;border-collapse:separate;overflow:hidden;width:100%;height:15.4px}.ax5combobox-option-group.ax5combobox-option-group-xs .ax-combobox-body .ax-combobox-option-group-content .ax-combobox-option-item .ax-combobox-option-item-holder .ax-combobox-option-item-cell{box-sizing:border-box;display:table-cell;vertical-align:middle;white-space:nowrap;font-size:10.4px;line-height:15.4px;padding:0px 0px 0px 0px;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none}.ax5combobox-option-group.ax5combobox-option-group-xs .ax-combobox-body .ax-combobox-option-group-content .ax-combobox-option-item .ax-combobox-option-item-holder .ax-combobox-option-item-cell.ax-combobox-option-item-checkbox{overflow:hidden;width:10.4px;text-align:center}.ax5combobox-option-group.ax5combobox-option-group-xs .ax-combobox-body .ax-combobox-option-group-content .ax-combobox-option-item .ax-combobox-option-item-holder .ax-combobox-option-item-cell.ax-combobox-option-item-checkbox .item-checkbox-wrap{position:relative;display:block;width:10.4px;height:15.4px}.ax5combobox-option-group.ax5combobox-option-group-xs .ax-combobox-body .ax-combobox-option-group-content .ax-combobox-option-item .ax-combobox-option-item-holder .ax-combobox-option-item-cell.ax-combobox-option-item-checkbox .item-checkbox-wrap.useCheckBox:after{content:'';width:6.4px;height:3.2px;position:absolute;top:3.85px;right:0px;border:2px solid #000;border-top:none;border-right:none;background:transparent;opacity:0.1;-webkit-transform:rotate(-50deg);-moz-transform:rotate(-50deg);-ms-transform:rotate(-50deg);-o-transform:rotate(-50deg);transform:rotate(-50deg)}.ax5combobox-option-group.ax5combobox-option-group-xs .ax-combobox-body .ax-combobox-option-group-content .ax-combobox-option-item .ax-combobox-option-item-holder .ax-combobox-option-item-cell.ax-combobox-option-item-label{padding:0px 7px;padding-right:6.4px}.ax5combobox-option-group.ax5combobox-option-group-xs .ax-combobox-body .ax-combobox-option-group-content .ax-combobox-option-item[data-option-selected="true"] .ax-combobox-option-item-holder .ax-combobox-option-item-cell.ax-combobox-option-item-checkbox .item-checkbox-wrap.useCheckBox:after{opacity:1}.ax5combobox-option-group.ax5combobox-option-group-xs .ax-combobox-body .ax-combobox-option-group-content .ax-combobox-option-group .ax-combobox-option-item-holder{display:table;position:relative;border-collapse:separate;overflow:hidden;width:100%;height:15.4px}.ax5combobox-option-group.ax5combobox-option-group-xs .ax-combobox-body .ax-combobox-option-group-content .ax-combobox-option-group .ax-combobox-option-item-holder .ax-combobox-option-group-label{box-sizing:border-box;display:table-cell;vertical-align:middle;white-space:nowrap;font-size:10.4px;line-height:15.4px;padding:5px 10px;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none}.ax5combobox-option-group.ax5combobox-option-group-xs .ax-combobox-body .ax-combobox-option-group-buttons{text-align:center;padding:1px 0px} diff --git a/dist/ax5ui.all.js b/dist/ax5ui.all.js old mode 100755 new mode 100644 index c9c705a7..cb4c65a3 --- a/dist/ax5ui.all.js +++ b/dist/ax5ui.all.js @@ -53,7 +53,7 @@ var _typeof = typeof Symbol === "function" && typeof Symbol.iterator === "symbol * ax5 version * @member {String} ax5.info.version */ - var version = "1.3.58"; + var version = "1.3.66"; /** * ax5 library path @@ -3423,7 +3423,7 @@ ax5.ui = function () { UI.addClass({ className: "dialog", - version: "1.3.58" + version: "1.3.66" }, function () { /** * @class ax5dialog @@ -3960,7 +3960,7 @@ ax5.ui = function () { UI.addClass({ className: "mask", - version: "1.3.58" + version: "1.3.66" }, function () { /** * @class ax5mask @@ -3999,7 +3999,8 @@ ax5.ui = function () { this.instanceId = ax5.getGuid(); this.config = { theme: '', - target: jQuery(document.body).get(0) + target: jQuery(document.body).get(0), + animateTime: 250 }; this.maskContent = ''; this.status = "off"; @@ -4197,31 +4198,65 @@ ax5.ui = function () { * ``` */ this.close = function (_delay) { + var _this2 = this; + if (this.$mask) { - var _close = function _close() { - this.status = "off"; - this.$mask.remove(); - this.$target.removeClass("ax-masking"); + (function () { + var _close = function _close() { + this.status = "off"; + this.$mask.remove(); + this.$target.removeClass("ax-masking"); - onStateChanged.call(this, null, { - self: this, - state: "close" - }); + onStateChanged.call(this, null, { + self: this, + state: "close" + }); - jQuery(window).unbind("resize.ax5mask-" + this.instanceId); - }; + jQuery(window).unbind("resize.ax5mask-" + this.instanceId); + }; - if (_delay) { + if (_delay) { + setTimeout(function () { + _close.call(this); + }.bind(_this2), _delay); + } else { + _close.call(_this2); + } + })(); + } + return this; + }; + + /** + * @method ax5mask.fadeOut + * @returns {ax5mask} + */ + this.fadeOut = function () { + var _this3 = this; + + if (this.$mask) { + (function () { + var _close = function _close() { + this.status = "off"; + this.$mask.remove(); + this.$target.removeClass("ax-masking"); + + onStateChanged.call(this, null, { + self: this, + state: "close" + }); + + jQuery(window).unbind("resize.ax5mask-" + this.instanceId); + }; + + _this3.$mask.addClass("fade-out"); setTimeout(function () { _close.call(this); - }.bind(this), _delay); - } else { - _close.call(this); - } + }.bind(_this3), cfg.animateTime); + })(); } return this; }; - //== class body end /** * @method ax5mask.align @@ -4289,7 +4324,7 @@ ax5.ui = function () { UI.addClass({ className: "toast", - version: "1.3.58" + version: "1.3.66" }, function () { /** * @class ax5toast @@ -4651,7 +4686,7 @@ ax5.ui = function () { UI.addClass({ className: "modal", - version: "1.3.58" + version: "1.3.66" }, function () { /** * @class ax5modal @@ -4699,7 +4734,7 @@ ax5.ui = function () { */ var ax5modal = function ax5modal() { var self = this, - cfg, + cfg = void 0, ENM = { "mousedown": ax5.info.supportTouch ? "touchstart" : "mousedown", "mousemove": ax5.info.supportTouch ? "touchmove" : "mousemove", @@ -4734,6 +4769,7 @@ ax5.ui = function () { animateTime: 250 }; this.activeModal = null; + this.watingModal = false; this.$ = {}; // UI inside of the jQuery object store cfg = this.config; // extended config copy cfg @@ -4771,7 +4807,7 @@ ax5.ui = function () { return MODAL.tmpl.get.call(this, "content", data, {}); }, open = function open(opts, callback) { - var that; + var that = void 0; jQuery(document.body).append(getContent.call(this, opts.id, opts)); this.activeModal = jQuery('#' + opts.id); @@ -4825,7 +4861,10 @@ ax5.ui = function () { } if (callback) callback.call(that); - onStateChanged.call(this, opts, that); + + if (!this.watingModal) { + onStateChanged.call(this, opts, that); + } // bind key event if (opts.closeToEsc) { @@ -4861,7 +4900,7 @@ ax5.ui = function () { }); }, btnOnClick = function btnOnClick(e, opts, callback, target, k) { - var that; + var that = void 0; if (e.srcElement) e.target = e.srcElement; target = U.findParentNode(e.target, function (target) { @@ -4915,16 +4954,16 @@ ax5.ui = function () { }, moveModal = { "on": function on() { - var modalZIndex = this.activeModal.css("z-index"); - var modalOffset = this.activeModal.position(); - var modalBox = { + var modalZIndex = this.activeModal.css("z-index"), + modalOffset = this.activeModal.position(), + modalBox = { width: this.activeModal.outerWidth(), height: this.activeModal.outerHeight() - }; - var windowBox = { + }, + windowBox = { width: jQuery(window).width(), height: jQuery(window).height() - }; - var getResizerPosition = function getResizerPosition(e) { + }, + getResizerPosition = function getResizerPosition(e) { self.__dx = e.clientX - self.mousePosition.clientX; self.__dy = e.clientY - self.mousePosition.clientY; @@ -4982,7 +5021,6 @@ ax5.ui = function () { }, "off": function off() { var setModalPosition = function setModalPosition() { - //console.log(this.activeModal.offset(), this.__dx); var box = this.activeModal.offset(); box.left += this.__dx - $(document).scrollLeft(); box.top += this.__dy - $(document).scrollTop(); @@ -5032,10 +5070,18 @@ ax5.ui = function () { * my_modal.open(); * ``` */ - this.open = function (opts, callback) { + this.open = function (opts, callback, tryCount) { + if (typeof tryCount === "undefined") tryCount = 0; if (!this.activeModal) { opts = self.modalConfig = jQuery.extend(true, {}, cfg, opts); open.call(this, opts, callback); + this.watingModal = false; + } else if (tryCount < 3) { + // 3번까지 재 시도 + this.watingModal = true; + setTimeout(function () { + this.open(opts, callback, tryCount + 1); + }.bind(this), cfg.animateTime); } return this; }; @@ -5082,10 +5128,13 @@ ax5.ui = function () { this.activeModal.remove(); this.activeModal = null; } - onStateChanged.call(this, opts, { - self: this, - state: "close" - }); + // 모달 오픈 대기중이면 닫기 상태 전달 안함. + if (!this.watingModal) { + onStateChanged.call(this, opts, { + self: this, + state: "close" + }); + } }.bind(this), cfg.animateTime); } @@ -5299,7 +5348,7 @@ ax5.ui = function () { UI.addClass({ className: "calendar", - version: "1.3.58" + version: "1.3.66" }, function () { /** @@ -6361,7 +6410,7 @@ ax5.ui = function () { UI.addClass({ className: "picker", - version: "1.3.58" + version: "1.3.66" }, function () { /** * @class ax5picker @@ -7400,7 +7449,7 @@ jQuery.fn.ax5picker = function () { UI.addClass({ className: "formatter", - version: "1.3.58" + version: "1.3.66" }, function () { var TODAY = new Date(); var setSelectionRange = function setSelectionRange(input, pos) { @@ -8036,7 +8085,7 @@ jQuery.fn.ax5formatter = function () { UI.addClass({ className: "menu", - version: "1.3.58" + version: "1.3.66" }, function () { /** * @class ax5.ui.menu @@ -8863,7 +8912,7 @@ jQuery.fn.ax5formatter = function () { UI.addClass({ className: "select", - version: "1.3.58" + version: "1.3.66" }, function () { /** * @class ax5select @@ -10035,7 +10084,7 @@ jQuery.fn.ax5select = function () { UI.addClass({ className: "grid", - version: "1.3.58" + version: "1.3.66" }, function () { /** * @class ax5grid @@ -11435,7 +11484,7 @@ jQuery.fn.ax5select = function () { * ``` */ this.focus = function (_pos) { - var _this2 = this; + var _this4 = this; if (GRID.body.moveFocus.call(this, _pos)) { var focusedColumn = void 0; @@ -11451,7 +11500,7 @@ jQuery.fn.ax5select = function () { this.select(0); } else { (function () { - var selectedIndex = _this2.selectedDataIndexs[0]; + var selectedIndex = _this4.selectedDataIndexs[0]; var processor = { "UP": function UP() { if (selectedIndex > 0) { @@ -11476,7 +11525,7 @@ jQuery.fn.ax5select = function () { }; if (_pos in processor) { - processor[_pos].call(_this2); + processor[_pos].call(_this4); } })(); } @@ -11881,6 +11930,7 @@ jQuery.fn.ax5select = function () { self.xvar.dataHoveredIndex = dindex; }); this.$["container"]["body"].on("mousedown", '[data-ax5grid-column-attr="default"]', function (e) { + if (self.xvar.touchmoved) return false; if (this.getAttribute("data-ax5grid-column-rowIndex")) { columnSelector.on.call(self, { panelName: this.getAttribute("data-ax5grid-panel-name"), @@ -11991,9 +12041,9 @@ jQuery.fn.ax5select = function () { } }; - var getFieldValue = function getFieldValue(_list, _item, _index, _col, _value) { - var _key = _col.key; - var tagsToReplace = { + var getFieldValue = function getFieldValue(_list, _item, _index, _col, _value, _returnPlainText) { + var _key = _col.key, + tagsToReplace = { '<': '<', '>': '>' }; @@ -12025,7 +12075,7 @@ jQuery.fn.ax5select = function () { } // print editor - return GRID.inlineEditor[_col.editor.type].getHtml(this, _col.editor, _value); + return _returnPlainText ? _value : GRID.inlineEditor[_col.editor.type].getHtml(this, _col.editor, _value); } if (_col.formatter) { var that = { @@ -12147,29 +12197,42 @@ jQuery.fn.ax5select = function () { }; var repaint = function repaint(_reset) { - var cfg = this.config; - var list = this.list; + var cfg = this.config, + list = this.list; + + /// repaint reset 타입이면 고정컬럼을 재조정 if (_reset) { resetFrozenColumn.call(this); + // 틀고정 이 변경되면 출력 시작 인덱스 값을 초기화 this.xvar.paintStartRowIndex = undefined; } + + /// 출력시작 인덱스 var paintStartRowIndex = Math.floor(Math.abs(this.$.panel["body-scroll"].position().top) / this.xvar.bodyTrHeight) + this.xvar.frozenRowIndex; if (this.xvar.dataRowCount === list.length && this.xvar.paintStartRowIndex === paintStartRowIndex) return this; // 스크롤 포지션 변경 여부에 따라 프로세스 진행여부 결정 - var isFirstPaint = typeof this.xvar.paintStartRowIndex === "undefined"; - var asideBodyRowData = this.asideBodyRowData; - var leftBodyRowData = this.leftBodyRowData; - var bodyRowData = this.bodyRowData; - var leftFootSumData = this.leftFootSumData; - var footSumData = this.footSumData; - var asideBodyGroupingData = this.asideBodyGroupingData; - var leftBodyGroupingData = this.leftBodyGroupingData; - var bodyGroupingData = this.bodyGroupingData; - var bodyAlign = cfg.body.align; - var paintRowCount = Math.ceil(this.$.panel["body"].height() / this.xvar.bodyTrHeight) + 1; + + var isFirstPaint = typeof this.xvar.paintStartRowIndex === "undefined", + asideBodyRowData = this.asideBodyRowData, + leftBodyRowData = this.leftBodyRowData, + bodyRowData = this.bodyRowData, + leftFootSumData = this.leftFootSumData, + footSumData = this.footSumData, + asideBodyGroupingData = this.asideBodyGroupingData, + leftBodyGroupingData = this.leftBodyGroupingData, + bodyGroupingData = this.bodyGroupingData, + bodyAlign = cfg.body.align, + paintRowCount = Math.ceil(this.$.panel["body"].height() / this.xvar.bodyTrHeight) + 1; + + if (document.addEventListener && ax5.info.supportTouch) { + paintRowCount = paintRowCount * 2; + } + + /// 스크롤 컨텐츠의 높이 : 그리드 스크롤의 실제 크기와는 관계 없이 데이터 갯수에 따라 스크롤 컨텐츠 높이값 구해서 저장해두기. this.xvar.scrollContentHeight = this.xvar.bodyTrHeight * (this.list.length - this.xvar.frozenRowIndex); + /// 사용된 패널들의 키 모음 this.$.livePanelKeys = []; - // body-scroll 의 포지션에 의존적이므로.. + // 그리드 바디 영역 페인트 함수 var repaintBody = function repaintBody(_elTargetKey, _colGroup, _bodyRow, _groupRow, _list, _scrollConfig) { var _elTarget = this.$.panel[_elTargetKey]; @@ -12178,13 +12241,19 @@ jQuery.fn.ax5select = function () { return false; } - var SS = []; - var cgi, cgl; - var di, dl; - var tri, trl; - var ci, cl; - var col, cellHeight, colAlign; - var isScrolled = function () { + var SS = [], + cgi = void 0, + cgl = void 0, + di = void 0, + dl = void 0, + tri = void 0, + trl = void 0, + ci = void 0, + cl = void 0, + col = void 0, + cellHeight = void 0, + colAlign = void 0, + isScrolled = function () { // 스크롤값이 변경되거나 처음 호출되었습니까? if (typeof _scrollConfig === "undefined" || typeof _scrollConfig['paintStartRowIndex'] === "undefined") { _scrollConfig = { @@ -12197,6 +12266,9 @@ jQuery.fn.ax5select = function () { } }(); + if (isScrolled) { + SS.push('
'); + } SS.push(''); SS.push(''); for (cgi = 0, cgl = _colGroup.length; cgi < cgl; cgi++) { @@ -12206,7 +12278,7 @@ jQuery.fn.ax5select = function () { SS.push(''); for (di = _scrollConfig.paintStartRowIndex, dl = function () { - var len; + var len = void 0; len = _list.length; if (_scrollConfig.paintRowCount + _scrollConfig.paintStartRowIndex < len) { len = _scrollConfig.paintRowCount + _scrollConfig.paintStartRowIndex; @@ -12214,9 +12286,8 @@ jQuery.fn.ax5select = function () { return len; }(); di < dl; di++) { - var isGroupingRow = false; - var rowTable; - + var isGroupingRow = false, + rowTable = void 0; if (_groupRow && "__isGrouping" in _list[di]) { rowTable = _groupRow; isGroupingRow = true; @@ -12268,6 +12339,7 @@ jQuery.fn.ax5select = function () { return ''; }(cellHeight), isGroupingRow ? getGroupingValue.call(this, _list[di], di, col) : getFieldValue.call(this, _list, _list[di], di, col), ''); + SS.push(''); } SS.push(''); @@ -12276,9 +12348,10 @@ jQuery.fn.ax5select = function () { } SS.push('
'); - if (isScrolled) { - _elTarget.css({ paddingTop: (_scrollConfig.paintStartRowIndex - this.xvar.frozenRowIndex) * _scrollConfig.bodyTrHeight }); + if (isScrolled && _list.length) { + SS.push('
'); } + _elTarget.empty().get(0).innerHTML = SS.join(''); this.$.livePanelKeys.push(_elTargetKey); // 사용중인 패널키를 모아둠. (뷰의 상태 변경시 사용하려고) @@ -12292,11 +12365,16 @@ jQuery.fn.ax5select = function () { return false; } - var SS = []; - var cgi, cgl; - var tri, trl; - var ci, cl; - var col, cellHeight, colAlign; + var SS = [], + cgi = void 0, + cgl = void 0, + tri = void 0, + trl = void 0, + ci = void 0, + cl = void 0, + col = void 0, + cellHeight = void 0, + colAlign = void 0; SS.push(''); SS.push(''); @@ -12411,7 +12489,6 @@ jQuery.fn.ax5select = function () { } //todo : repaintBody 에서 footSum 데이터 예외처리 - // right if (cfg.rightSum) { // todo : right 표현 정리 @@ -12951,7 +13028,7 @@ jQuery.fn.ax5select = function () { if (!noRepaint && "top" in css) { repaint.call(this); - } + } else {} }; var blur = function blur() { @@ -13455,25 +13532,25 @@ jQuery.fn.ax5select = function () { var getExcelString = function getExcelString() { var cfg = this.config, list = this.list, - bodyRowData = this.bodyRowData, - footSumData = this.footSumData, - bodyGroupingData = this.bodyGroupingData; + bodyRowData = this.bodyRowTable, + footSumData = this.footSumTable, + bodyGroupingData = this.bodyGroupingTable; // body-scroll 의 포지션에 의존적이므로.. var getBody = function getBody(_colGroup, _bodyRow, _groupRow, _list) { var SS = [], - di, - dl, - tri, - trl, - ci, - cl, - col; + di = void 0, + dl = void 0, + tri = void 0, + trl = void 0, + ci = void 0, + cl = void 0, + col = void 0; //SS.push('
'); for (di = 0, dl = _list.length; di < dl; di++) { - var isGroupingRow = false; - var rowTable; + var isGroupingRow = false, + rowTable = void 0; if (_groupRow && "__isGrouping" in _list[di]) { rowTable = _groupRow; @@ -13487,7 +13564,7 @@ jQuery.fn.ax5select = function () { for (ci = 0, cl = rowTable.rows[tri].cols.length; ci < cl; ci++) { col = rowTable.rows[tri].cols[ci]; - SS.push(''); + SS.push(''); } SS.push('\n'); } @@ -13606,10 +13683,10 @@ jQuery.fn.ax5select = function () { var initData = function initData(_list) { this.selectedDataIndexs = []; var i = 0, - l = _list.length; - var returnList = []; - var appendIndex = 0; - var dataRealRowCount = 0; + l = _list.length, + returnList = [], + appendIndex = 0, + dataRealRowCount = 0; if (this.config.body.grouping) { var groupingKeys = U.map(this.bodyGrouping.by, function () { @@ -13622,9 +13699,9 @@ jQuery.fn.ax5select = function () { }); var gi = 0, gl = groupingKeys.length, - compareString, + compareString = void 0, appendRow = [], - ari; + ari = void 0; for (; i < l + 1; i++) { gi = 0; if (_list[i] && _list[i][this.config.columnKeys.deleted]) { @@ -13832,7 +13909,6 @@ jQuery.fn.ax5select = function () { */ var deleteRow = function deleteRow(_dindex) { var list = this.config.body.grouping ? clearGroupingData.call(this, this.list) : this.list; - var processor = { "first": function first() { list[0][this.config.columnKeys.deleted] = true; @@ -14251,10 +14327,10 @@ jQuery.fn.ax5select = function () { var self = this; this.$["container"]["header"].on("click", '[data-ax5grid-column-attr]', function (e) { - var key = this.getAttribute("data-ax5grid-column-key"); - var colIndex = this.getAttribute("data-ax5grid-column-colindex"); - var rowIndex = this.getAttribute("data-ax5grid-column-rowindex"); - var col = self.colGroup[colIndex]; + var key = this.getAttribute("data-ax5grid-column-key"), + colIndex = this.getAttribute("data-ax5grid-column-colindex"), + rowIndex = this.getAttribute("data-ax5grid-column-rowindex"), + col = self.colGroup[colIndex]; if (key === "__checkbox_header__") { var selected = this.getAttribute("data-ax5grid-selected"); @@ -14286,8 +14362,8 @@ jQuery.fn.ax5select = function () { }; var resetFrozenColumn = function resetFrozenColumn() { - var cfg = this.config; - var dividedHeaderObj = GRID.util.divideTableByFrozenColumnIndex(this.headerTable, this.config.frozenColumnIndex); + var cfg = this.config, + dividedHeaderObj = GRID.util.divideTableByFrozenColumnIndex(this.headerTable, this.config.frozenColumnIndex); this.asideHeaderData = function (dataTable) { var colGroup = []; var data = { rows: [] }; @@ -14333,10 +14409,10 @@ jQuery.fn.ax5select = function () { }; var getFieldValue = function getFieldValue(_col) { - var cfg = this.config; - var colGroup = this.colGroup; - var _key = _col.key; - var tagsToReplace = { + var cfg = this.config, + colGroup = this.colGroup, + _key = _col.key, + tagsToReplace = { '<': '<', '>': '>' }; @@ -14349,24 +14425,25 @@ jQuery.fn.ax5select = function () { }; var repaint = function repaint(_reset) { - var cfg = this.config; - var colGroup = this.colGroup; + var cfg = this.config, + colGroup = this.colGroup; + if (_reset) { resetFrozenColumn.call(this); this.xvar.paintStartRowIndex = undefined; } - var asideHeaderData = this.asideHeaderData; - var leftHeaderData = this.leftHeaderData; - var headerData = this.headerData; - var headerAlign = cfg.header.align; + var asideHeaderData = this.asideHeaderData, + leftHeaderData = this.leftHeaderData, + headerData = this.headerData, + headerAlign = cfg.header.align; // this.asideColGroup : asideHeaderData에서 처리 함. this.leftHeaderColGroup = colGroup.slice(0, this.config.frozenColumnIndex); this.headerColGroup = colGroup.slice(this.config.frozenColumnIndex); var repaintHeader = function repaintHeader(_elTarget, _colGroup, _bodyRow) { - var tableWidth = 0; - var SS = []; + var tableWidth = 0, + SS = []; SS.push('
', isGroupingRow ? getGroupingValue.call(this, _list[di], di, col) : getFieldValue.call(this, _list, _list[di], di, col), '', isGroupingRow ? getGroupingValue.call(this, _list[di], di, col) : getFieldValue.call(this, _list, _list[di], di, col, undefined, "text"), '
'); SS.push(''); for (var cgi = 0, cgl = _colGroup.length; cgi < cgl; cgi++) { @@ -14430,9 +14507,10 @@ jQuery.fn.ax5select = function () { /// append column-resizer (function () { - var resizerHeight = cfg.header.columnHeight * _bodyRow.rows.length - cfg.header.columnBorderWidth; - var resizerLeft = 0; - var AS = []; + var resizerHeight = cfg.header.columnHeight * _bodyRow.rows.length - cfg.header.columnBorderWidth, + resizerLeft = 0, + AS = []; + for (var cgi = 0, cgl = _colGroup.length; cgi < cgl; cgi++) { var col = _colGroup[cgi]; if (!U.isNothing(col.colIndex)) { @@ -14464,9 +14542,9 @@ jQuery.fn.ax5select = function () { }; var toggleSort = function toggleSort(_key) { - var sortOrder = ""; - var sortInfo = {}; - var seq = 0; + var sortOrder = "", + sortInfo = {}, + seq = 0; for (var k in this.sortInfo) { if (this.sortInfo[k].fixed) { @@ -14522,11 +14600,10 @@ jQuery.fn.ax5select = function () { }; var getExcelString = function getExcelString() { - var cfg = this.config; - var colGroup = this.colGroup; - var headerData = this.headerData; - - var getHeader = function getHeader(_colGroup, _bodyRow) { + var cfg = this.config, + colGroup = this.colGroup, + headerData = this.headerTable, + getHeader = function getHeader(_colGroup, _bodyRow) { var SS = []; //SS.push('
'); for (var tri = 0, trl = _bodyRow.rows.length; tri < trl; tri++) { @@ -15107,9 +15184,10 @@ jQuery.fn.ax5select = function () { return false; } - var newLeft, newTop; - var _top_is_end = false; - var _left_is_end = false; + var newLeft = void 0, + newTop = void 0, + _top_is_end = false, + _left_is_end = false; newLeft = _body_scroll_position.left - delta.x; newTop = _body_scroll_position.top - delta.y; @@ -15153,8 +15231,9 @@ jQuery.fn.ax5select = function () { _content_height = self.xvar.scrollContentHeight, _content_width = self.xvar.scrollContentWidth, getContentPosition = function getContentPosition(e) { - var mouseObj = GRID.util.getMousePosition(e); - var newLeft, newTop; + var mouseObj = GRID.util.getMousePosition(e), + newLeft = void 0, + newTop = void 0; self.xvar.__x_da = mouseObj.clientX - self.xvar.mousePosition.clientX; self.xvar.__y_da = mouseObj.clientY - self.xvar.mousePosition.clientY; @@ -15185,36 +15264,40 @@ jQuery.fn.ax5select = function () { this.xvar.__x_da = 0; // 이동량 변수 초기화 (계산이 잘못 될까바) this.xvar.__y_da = 0; // 이동량 변수 초기화 (계산이 잘못 될까바) + this.xvar.touchmoved = false; + + jQuery(document.body).on("touchmove" + ".ax5grid-" + this.instanceId, function (e) { - jQuery(document.body).bind("touchmove" + ".ax5grid-" + this.instanceId, function (e) { var css = getContentPosition(e); GRID.header.scrollTo.call(self, { left: css.left }); GRID.body.scrollTo.call(self, css, "noRepaint"); resize.call(self); U.stopEvent(e); - }).bind("touchend" + ".ax5grid-" + this.instanceId, function (e) { - var css = getContentPosition(e); - GRID.header.scrollTo.call(self, { left: css.left }); - GRID.body.scrollTo.call(self, css); - resize.call(self); - U.stopEvent(e); - scrollContentMover.off.call(self); + self.xvar.touchmoved = true; + }).on("touchend" + ".ax5grid-" + this.instanceId, function (e) { + if (self.xvar.touchmoved) { + var css = getContentPosition(e); + GRID.header.scrollTo.call(self, { left: css.left }); + GRID.body.scrollTo.call(self, css); + resize.call(self); + U.stopEvent(e); + scrollContentMover.off.call(self); + } }); jQuery(document.body).attr('unselectable', 'on').css('user-select', 'none').on('selectstart', false); }, "off": function off() { - jQuery(document.body).unbind("touchmove" + ".ax5grid-" + this.instanceId).unbind("touchend" + ".ax5grid-" + this.instanceId); + jQuery(document.body).off("touchmove" + ".ax5grid-" + this.instanceId).off("touchend" + ".ax5grid-" + this.instanceId); jQuery(document.body).removeAttr('unselectable').css('user-select', 'auto').off('selectstart'); } }; var init = function init() { - var self = this; - //this.config.scroller.size - var margin = this.config.scroller.trackPadding; + var self = this, + margin = this.config.scroller.trackPadding; this.$["scroller"]["vertical-bar"].css({ width: this.config.scroller.size - (margin + 1), left: margin / 2 }); this.$["scroller"]["horizontal-bar"].css({ height: this.config.scroller.size - (margin + 1), top: margin / 2 }); @@ -15248,8 +15331,9 @@ jQuery.fn.ax5select = function () { }.bind(this)); this.$["container"]["body"].on('mousewheel DOMMouseScroll', function (e) { - var E = e.originalEvent; - var delta = { x: 0, y: 0 }; + var E = e.originalEvent, + delta = { x: 0, y: 0 }; + if (E.detail) { delta.y = E.detail * 10; } else { @@ -15770,7 +15854,7 @@ jQuery.fn.ax5select = function () { UI.addClass({ className: "mediaViewer", - version: "1.3.58" + version: "1.3.66" }, function () { /** * @class ax5mediaViewer @@ -16338,7 +16422,7 @@ jQuery.fn.ax5select = function () { UI.addClass({ className: "uploader", - version: "1.3.58" + version: "1.3.66" }, function () { var ax5uploader = function ax5uploader() { @@ -16412,7 +16496,7 @@ jQuery.fn.ax5select = function () { * UI 상태변경 이벤트 처리자 * UI의 상태변경 : open, close, upload 등의 변경사항이 발생되면 onStateChanged 함수를 후출하여 이벤트를 처리 */ - var onStateChanged = function onStateChanged(that) { + var bound_onStateChanged = function (that) { var state = { "open": function open() {}, @@ -16428,13 +16512,15 @@ jQuery.fn.ax5select = function () { that = null; return true; - }; + }.bind(this); - var onSelectFile = function (_evt) { + var bound_onSelectFile = function (_evt) { var files = void 0; if (!ax5.info.supportFileApi) { // file API 지원 안되는 브라우저. + // input file에 multiple 지원 안됨 그러므로 단일 파일 처리만 하면 됨. + files = { path: _evt.target.value }; } else if ('dataTransfer' in _evt) { files = _evt.dataTransfer.files; } else if ('target' in _evt) { @@ -16453,71 +16539,143 @@ jQuery.fn.ax5select = function () { } if (cfg.progressBox) { - openProgressBox(); + bound_openProgressBox(); } if (!cfg.manualUpload) { this.send(); } + + if (!ax5.info.supportFileApi) { + bound_alignLayout(false); + } }.bind(this); - var bindEvent = function bindEvent() { + var bound_bindEvent = function () { this.$fileSelector.off("click.ax5uploader").on("click.ax5uploader", function () { this.$inputFile.trigger("click"); }.bind(this)); - this.$inputFile.off("change.ax5uploader").on("change.ax5uploader", function (_evt) { - onSelectFile(_evt); - }.bind(this)); + if (!ax5.info.supportFileApi) { + this.$fileSelector.off("mouseover.ax5uploader").on("mouseover.ax5uploader", function () { + bound_alignLayout(true); + }.bind(this)); + + this.$inputFile.off("mouseover.ax5uploader").on("mouseover.ax5uploader", function () { + this.$fileSelector.addClass("active"); + }.bind(this)); + + this.$inputFile.off("mouseout.ax5uploader").on("mouseout.ax5uploader", function () { + this.$fileSelector.removeClass("active"); + + bound_alignLayout(false); + }.bind(this)); + } + + (function () { + if (!this.$uploadedBox || !this.$uploadedBox.get(0)) return false; + + this.$uploadedBox.on("click", "[data-uploaded-item-cell]", function () { + var $this = jQuery(this), + cellType = $this.attr("data-uploaded-item-cell"), + uploadedItemIndex = Number($this.parents('[data-ax5uploader-uploaded-item]').attr('data-ax5uploader-uploaded-item')), + that = {}; + + if (cfg.uploadedBox && cfg.uploadedBox.onclick) { + that = { + self: self, + cellType: cellType, + uploadedFiles: self.uploadedFiles, + fileIndex: uploadedItemIndex + }; + cfg.uploadedBox.onclick.call(that, that); + } + + $this = null; + cellType = null; + uploadedItemIndex = null; + that = null; + }); + }).call(this); (function () { // dropZone 설정 방식 변경 + if (!ax5.info.supportFileApi) return false; if (!this.$dropZone || !this.$dropZone.get(0)) return false; var timer = void 0; - this.$dropZone.on("click", function (e) { - //console.log(e.target.getAttribute("data-ax5uploader-dropzone")); - var isItemCell = ax5.util.findParentNode(e.target, function (target) { - if (target.hasAttribute("data-uploaded-item-cell")) { - return true; + this.$dropZone.parent().on("click", "[data-ax5uploader-dropzone]", function (e) { + if (this == e.target || $.contains(this, e.target)) { + if (U.isFunction(cfg.dropZone.onclick)) { + cfg.dropZone.onclick.call({ + self: self + }); + } else { + self.$inputFile.trigger("click"); } - }); - - if (!isItemCell) { - // dropZone click - self.$inputFile.trigger("click"); } }); this.$dropZone.get(0).addEventListener('dragover', function (e) { U.stopEvent(e); - self.$dropZone.addClass("dragover"); + + if (U.isFunction(cfg.dropZone.ondragover)) { + cfg.dropZone.ondragover.call({ + self: self + }); + } else { + self.$dropZone.addClass("dragover"); + } }, false); this.$dropZone.get(0).addEventListener('dragleave', function (e) { U.stopEvent(e); - self.$dropZone.removeClass("dragover"); + + if (U.isFunction(cfg.dropZone.ondragover)) { + cfg.dropZone.ondragout.call({ + self: self + }); + } else { + self.$dropZone.removeClass("dragover"); + } }, false); this.$dropZone.get(0).addEventListener('drop', function (e) { U.stopEvent(e); - self.$dropZone.removeClass("dragover"); - onSelectFile(e || window.event); + + if (U.isFunction(cfg.dropZone.ondrop)) { + cfg.dropZone.ondrop.call({ + self: self + }); + } else { + self.$dropZone.removeClass("dragover"); + } + + bound_onSelectFile(e || window.event); }, false); }).call(this); - }; + }.bind(this); - var alignLayout = function alignLayout() { + var bound_alignLayout = function (_TF) { // 상황이 좋지 않은경우 (만약 버튼 클릭으로 input file click이 되지 않는 다면 z-index값을 높여서 버튼위를 덮는다.) - /* - var box = this.$fileSelector.position(); - box.width = this.$fileSelector.outerWidth(); - box.height = this.$fileSelector.outerHeight(); - this.$inputFile.css(box); - */ - }; + if (_TF) { + if (!ax5.info.supportFileApi) { + // ie9에서 inputFile을 직접 클릭하지 않으면 submit 오류발생함. submit access denied + // 그래서 버튼위에 inputFile을 올려두어야 함. (position값을 이용하면 편하지만..) + // 그런데 form을 안에두면 또 다른 이중폼 문제 발생소지 ㅜㅜ 불가피하게 버튼의 offset 값을 이용. + var box = this.$fileSelector.offset(); + box.width = this.$fileSelector.outerWidth(); + box.height = this.$fileSelector.outerHeight(); + this.$inputFile.css(box); + } + } else { + this.$inputFile.css({ + left: -1000, top: -1000 + }); + } + }.bind(this); - var alignProgressBox = function alignProgressBox(append) { + var bound_alignProgressBox = function (append) { var _alignProgressBox = function _alignProgressBox() { var $window = jQuery(window), $body = jQuery(document.body); @@ -16542,7 +16700,7 @@ jQuery.fn.ax5select = function () { }; // picker css(width, left, top) & direction 결정 - if (!cfg.direction || cfg.direction === "" || cfg.direction === "auto") { + if (!cfg.progressBoxDirection || cfg.progressBoxDirection === "" || cfg.progressBoxDirection === "auto") { // set direction pickerDirection = "top"; if (pos.top - pickerDim.height - positionMargin < 0) { @@ -16551,7 +16709,7 @@ jQuery.fn.ax5select = function () { pickerDirection = "bottom"; } } else { - pickerDirection = cfg.direction; + pickerDirection = cfg.progressBoxDirection; } if (append) { @@ -16625,31 +16783,31 @@ jQuery.fn.ax5select = function () { setTimeout(function () { _alignProgressBox.call(this); }.bind(this)); - }; + }.bind(this); - var openProgressBox = function () { + var bound_openProgressBox = function () { this.$progressBox.removeClass("destroy"); this.$progressUpload.removeAttr("disabled"); this.$progressAbort.removeAttr("disabled"); // apend & align progress box - alignProgressBox.call(this, "append"); + bound_alignProgressBox("append"); // state change - onStateChanged.call(this, { + bound_onStateChanged({ self: this, state: "open" }); }.bind(this); - var closeProgressBox = function () { + var bound_closeProgressBox = function () { this.$progressBox.addClass("destroy"); setTimeout(function () { this.$progressBox.remove(); }.bind(this), cfg.animateTime); }.bind(this); - var startUpload = function () { + var bound_startUpload = function () { var processor = { "html5": function html5() { @@ -16657,7 +16815,7 @@ jQuery.fn.ax5select = function () { var uploadFile = this.selectedFiles.shift(); if (!uploadFile) { // 업로드 종료 - uploadComplete(); + bound_uploadComplete(); return this; } @@ -16684,16 +16842,23 @@ jQuery.fn.ax5select = function () { if (res.error) { if (cfg.debug) console.log(res.error); + if (U.isFunction(cfg.onuploaderror)) { + cfg.onuploaderror.call({ + self: this, + error: res.error + }, res); + } + self.send(); return false; } - uploaded(res); + bound_uploaded(res); self.send(); }; this.xhr.upload.onprogress = function (e) { // console.log(e.loaded, e.total); - updateProgressBar(e); + bound_updateProgressBar(e); if (U.isFunction(cfg.onprogress)) { cfg.onprogress.call({ loaded: e.loaded, @@ -16704,12 +16869,51 @@ jQuery.fn.ax5select = function () { this.xhr.send(formData); // multipart/form-data }, "form": function form() { + + /// i'm busy + this.__uploading = true; + // 폼과 iframe을 만들어 페이지 아래에 삽입 후 업로드 - // iframe 생성 - var iframe = $(''); - // form 생성. + var $iframe = jQuery(''); + jQuery(document.body).append($iframe); + + // onload 이벤트 핸들러 + // action에서 파일을 받아 처리한 결과값을 텍스트로 출력한다고 가정하고 iframe의 내부 데이터를 결과값으로 callback 호출 + $iframe.load(function () { + var doc = this.contentWindow ? this.contentWindow.document : this.contentDocument ? this.contentDocument : this.document, + root = doc.documentElement ? doc.documentElement : doc.body, + result = root.textContent ? root.textContent : root.innerText, + res = void 0; + + try { + res = JSON.parse(result); + } catch (e) { + res = { + error: "Syntax error", + body: result + }; + } + + if (cfg.debug) console.log(res); + if (res.error) { + console.log(res); + } else { + bound_uploaded(res); + $iframe.remove(); + + setTimeout(function () { + bound_uploadComplete(); + }, 300); + } + }); - $(document.body).append(iframe); + this.$inputFileForm.attr("target", 'ax5uploader-' + this.instanceId + '-iframe').attr("action", cfg.form.action).submit(); + + this.selectedFilesTotal = 1; + bound_updateProgressBar({ + loaded: 1, + total: 1 + }); } }; @@ -16730,7 +16934,7 @@ jQuery.fn.ax5select = function () { processor[ax5.info.supportFileApi ? "html5" : "form"].call(this); }.bind(this); - var updateProgressBar = function (e) { + var bound_updateProgressBar = function (e) { this.__loaded += e.loaded; this.$progressBar.css({ width: U.number(this.__loaded / this.selectedFilesTotal * 100, { round: 2 }) + '%' }); if (e.lengthComputable) { @@ -16738,10 +16942,10 @@ jQuery.fn.ax5select = function () { } }.bind(this); - var uploaded = function (res) { + var bound_uploaded = function (res) { if (cfg.debug) console.log(res); this.uploadedFiles.push(res); - repaintUploadedBox(); // 업로드된 파일 출력 + bound_repaintUploadedBox(); // 업로드된 파일 출력 if (U.isFunction(cfg.onuploaded)) { cfg.onuploaded.call({ @@ -16750,13 +16954,13 @@ jQuery.fn.ax5select = function () { } }.bind(this); - var uploadComplete = function () { + var bound_uploadComplete = function () { this.__uploading = false; // 업로드 완료 상태처리 this.$progressUpload.removeAttr("disabled"); this.$progressAbort.attr("disabled", "disabled"); if (cfg.progressBox) { - closeProgressBox(); + bound_closeProgressBox(); } if (U.isFunction(cfg.onuploadComplete)) { cfg.onuploadComplete.call({ @@ -16764,9 +16968,12 @@ jQuery.fn.ax5select = function () { }); } // update uploadedFiles display + + /// reset inputFile + bound_attachFileTag(); }.bind(this); - var cancelUpload = function () { + var bound_cancelUpload = function () { var processor = { "html5": function html5() { @@ -16784,15 +16991,18 @@ jQuery.fn.ax5select = function () { processor[ax5.info.supportFileApi ? "html5" : "form"].call(this); if (cfg.progressBox) { - closeProgressBox(); + bound_closeProgressBox(); } - this.$inputFile.get(0).value = ""; - console.log("cancelUpload"); + //this.$inputFile.val(""); + /// reset inputFile + bound_attachFileTag(); + + if (cfg.debug) console.log("cancelUpload"); // update uploadedFiles display }.bind(this); - var repaintUploadedBox = function () { + var bound_repaintUploadedBox = function () { // uploadedBox 가 없다면 아무일도 하지 않음. // onuploaded 함수 이벤트를 이용하여 개발자가 직접 업로드디 박스를 구현 한다고 이해 하자. if (this.$uploadedBox === null) return this; @@ -16800,10 +17010,87 @@ jQuery.fn.ax5select = function () { this.$uploadedBox.html(UPLOADER.tmpl.get("upoadedBox", { uploadedFiles: this.uploadedFiles, icon: cfg.uploadedBox.icon, - lang: cfg.uploadedBox.lang + lang: cfg.uploadedBox.lang, + supportFileApi: !!ax5.info.supportFileApi }, cfg.uploadedBox.columnKeys)); }.bind(this); + var bound_attachFileTag = function () { + if (this.$inputFile && this.$inputFile.get(0)) { + this.$inputFile.remove(); + } + if (this.$inputFileForm && this.$inputFileForm.get(0)) { + this.$inputFileForm.remove(); + } + + this.$inputFile = jQuery(UPLOADER.tmpl.get.call(this, "inputFile", { + instanceId: this.instanceId, + multiple: cfg.multiple, + accept: cfg.accept, + name: cfg.form.fileName + })); + + if (ax5.info.supportFileApi) { + jQuery(document.body).append(this.$inputFile); + } else { + this.$fileSelector.attr("tabindex", -1); + this.$inputFileForm = jQuery(UPLOADER.tmpl.get.call(this, "inputFileForm", { + instanceId: this.instanceId + })); + + this.$inputFileForm.append(this.$inputFile); + jQuery(document.body).append(this.$inputFileForm); + } + + this.$inputFile.off("change.ax5uploader").on("change.ax5uploader", function (_evt) { + bound_onSelectFile(_evt); + }.bind(this)); + }.bind(this); + + /** + * Preferences of uploader UI + * @method ax5uploader.setConfig + * @param {Object} _config - 클래스 속성값 + * @param {Element} _config.target + * @param {Object} _config.form + * @param {String} _config.form.action - upload URL + * @param {String} _config.form.fileName - The name key of the upload file + * @param {Boolean} [_config.multiple=false] - Whether multiple files. In a browser where fileApi is not supported (eg IE9), it only works with false. + * @param {String} [_config.accept=""] - accept mimeType (http://www.w3schools.com/TAgs/att_input_accept.asp) + * @param {Boolean} [_config.manualUpload=false] - Whether to automatically upload when a file is selected. + * @param {Boolean} [_config.progressBox=true] - Whether to use progressBox + * @param {String} [_config.progressBoxDirection=auto] - ProgressBox display direction + * @param {Object} [_config.dropZone] + * @param {Element} [_config.dropZone.target] + * @param {Function} [_config.dropZone.onclick] + * @param {Function} [_config.dropZone.ondragover] + * @param {Function} [_config.dropZone.ondragout] + * @param {Function} [_config.dropZone.ondrop] + * @param {Object} [_config.uploadedBox] + * @param {Element} [_config.uploadedBox.target] + * @param {Element} [_config.uploadedBox.icon] + * @param {Object} [_config.uploadedBox.columnKeys] + * @param {String} [_config.uploadedBox.columnKeys.name] + * @param {String} [_config.uploadedBox.columnKeys.type] + * @param {String} [_config.uploadedBox.columnKeys.size] + * @param {String} [_config.uploadedBox.columnKeys.uploadedName] + * @param {String} [_config.uploadedBox.columnKeys.downloadPath] + * @param {Object} [_config.uploadedBox.lang] + * @param {String} [_config.uploadedBox.lang.supportedHTML5_emptyListMsg] + * @param {String} [_config.uploadedBox.lang.emptyListMsg] + * @param {Function} [_config.uploadedBox.onchange] + * @param {Function} [_config.uploadedBox.onclick] + * @param {Function} [_config.validateSelectedFiles] + * @param {Function} [_config.onprogress] - return loaded, total + * @param {Function} [_config.onuploaded] - return self + * @param {Function} [_config.onuploaderror] - return self, error + * @param {Function} [_config.onuploadComplete] - return self + * @returns {ax5uploader} + * @example + * ```js + * + * ``` + */ this.init = function (_config) { cfg = jQuery.extend(true, {}, cfg, _config); if (!cfg.target) { @@ -16814,35 +17101,14 @@ jQuery.fn.ax5select = function () { this.$target = jQuery(cfg.target); // 파일 드랍존은 옵션 사항. - if (cfg.dropZone) { - this.$dropZone = jQuery(cfg.dropZone); + if (cfg.dropZone && cfg.dropZone.target && ax5.info.supportFileApi) { + this.$dropZone = jQuery(cfg.dropZone.target); this.$dropZone.attr("data-ax5uploader-dropzone", this.instanceId); } // uploadedBox 옵션 사항 if (cfg.uploadedBox && cfg.uploadedBox.target) { this.$uploadedBox = jQuery(cfg.uploadedBox.target); - this.$uploadedBox.on("click", "[data-uploaded-item-cell]", function () { - var $this = jQuery(this), - cellType = $this.attr("data-uploaded-item-cell"), - uploadedItemIndex = Number($this.parents('[data-ax5uploader-uploaded-item]').attr('data-ax5uploader-uploaded-item')), - that = {}; - - if (cfg.uploadedBox && cfg.uploadedBox.onclick) { - that = { - self: self, - cellType: cellType, - uploadedFiles: self.uploadedFiles, - fileIndex: uploadedItemIndex - }; - cfg.uploadedBox.onclick.call(that, that); - } - - $this = null; - cellType = null; - uploadedItemIndex = null; - that = null; - }); } // target attribute data @@ -16862,21 +17128,7 @@ jQuery.fn.ax5select = function () { } // input file 추가 - this.$inputFile = jQuery(UPLOADER.tmpl.get.call(this, "inputFile", { - instanceId: this.instanceId, - multiple: cfg.multiple, - accept: cfg.accept - })); - - if (ax5.info.supportFileApi) { - jQuery(document.body).append(this.$inputFile); - } else { - this.$inputFileForm = jQuery(UPLOADER.tmpl.get.call(this, "inputFileForm", { - instanceId: this.instanceId - })); - this.$inputFileForm.append(this.$inputFile); - jQuery(document.body).append(this.$inputFileForm); - } + bound_attachFileTag(); // btns 확인 cfg.btns = jQuery.extend({}, this.defaultBtns, cfg.btns); @@ -16890,11 +17142,14 @@ jQuery.fn.ax5select = function () { this.$progressUpload = this.$progressBox.find('[data-pregressbox-btn="upload"]'); this.$progressAbort = this.$progressBox.find('[data-pregressbox-btn="abort"]'); - // 레이아웃 정렬 - alignLayout.call(this); + // file API가 지원되지 않는 브라우저는 중지 기능 제공 못함. + if (!ax5.info.supportFileApi) { + this.$progressAbort.hide(); + } // 파일버튼 등에 이벤트 연결. - bindEvent.call(this); + bound_bindEvent(); + bound_repaintUploadedBox(); return this; }; @@ -16906,7 +17161,20 @@ jQuery.fn.ax5select = function () { this.send = function () { return function () { // 업로드 시작 - startUpload(); + if (U.isFunction(cfg.validateSelectedFiles)) { + var that = { + self: this, + uploadedFiles: this.uploadedFiles, + selectedFiles: this.selectedFiles + }; + if (!cfg.validateSelectedFiles.call(that, that)) { + bound_cancelUpload(); + return false; + // 전송처리 안함. + } + } + + bound_startUpload(); return this; }; }(); @@ -16917,7 +17185,11 @@ jQuery.fn.ax5select = function () { */ this.abort = function () { return function () { - cancelUpload(); + if (!ax5.info.supportFileApi) { + alert("This browser not supported abort method"); + return this; + } + bound_cancelUpload(); return this; }; }(); @@ -16955,7 +17227,13 @@ jQuery.fn.ax5select = function () { if (U.isArray(_files)) { this.uploadedFiles = _files; } - repaintUploadedBox(); + if (U.isString(_files)) { + try { + this.uploadedFiles = JSON.parse(_files); + } catch (e) {} + } + + bound_repaintUploadedBox(); return this; }; @@ -16974,7 +17252,7 @@ jQuery.fn.ax5select = function () { if (!isNaN(Number(_index))) { this.uploadedFiles.splice(_index, 1); } - repaintUploadedBox(); + bound_repaintUploadedBox(); return this; }; @@ -16989,10 +17267,22 @@ jQuery.fn.ax5select = function () { */ this.removeFileAll = function () { this.uploadedFiles = []; - repaintUploadedBox(); + bound_repaintUploadedBox(); return this; }; + /** + * @method ax5uploader.selectFile + * @returns {Boolean} + */ + this.selectFile = function () { + if (ax5.info.supportFileApi) { + this.$inputFile.trigger("click"); + return true; + } + return false; + }; + // 클래스 생성자 this.main = function () { UI.uploader_instance = UI.uploader_instance || []; @@ -17029,11 +17319,11 @@ jQuery.fn.ax5select = function () { }; var inputFile = function inputFile(columnKeys) { - return ''; + return ''; }; var inputFileForm = function inputFileForm(columnKeys) { - return ''; + return ''; }; var progressBox = function progressBox(columnKeys) { @@ -17041,7 +17331,7 @@ jQuery.fn.ax5select = function () { }; var upoadedBox = function upoadedBox(columnKeys) { - 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{{{lang.emptyList}}}\n{{/uploadedFiles}}\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'; }; UPLOADER.tmpl = { @@ -17070,7 +17360,7 @@ jQuery.fn.ax5select = function () { UI.addClass({ className: "combobox", - version: "1.3.58" + version: "1.3.66" }, function () { /** * @class ax5combobox @@ -18706,7 +18996,7 @@ jQuery.fn.ax5combobox = function () { UI.addClass({ className: "layout", - version: "1.3.58" + version: "1.3.66" }, function () { /** * @class ax5layout @@ -19735,7 +20025,7 @@ jQuery.fn.ax5layout = function () { UI.addClass({ className: "binder", - version: "1.3.58" + version: "1.3.66" }, function () { /** @@ -20696,7 +20986,7 @@ jQuery.fn.ax5layout = function () { UI.addClass({ className: "autocomplete", - version: "1.3.58" + version: "1.3.66" }, function () { /** * @class ax5autocomplete @@ -22080,7 +22370,7 @@ jQuery.fn.ax5autocomplete = function () { }; var autocompleteDisplay = function autocompleteDisplay(columnKeys) { - return ' \n\n
\n
\n
\n \n
\n
\n {{#multiple}}{{#reset}}\n {{{.}}}\n {{/reset}}{{/multiple}}\n
\n
\n\n'; + return ' \n\n
\n
\n
\n \n
\n
\n {{#multiple}}{{#reset}}\n {{{.}}}\n {{/reset}}{{/multiple}}\n
\n
\n\n'; }; var formSelect = function formSelect(columnKeys) { diff --git a/dist/ax5ui.all.min.js b/dist/ax5ui.all.min.js old mode 100755 new mode 100644 index 59d03aa1..ac784a40 --- a/dist/ax5ui.all.min.js +++ b/dist/ax5ui.all.min.js @@ -1,12 +1,12 @@ -"use strict";var _typeof="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t};(function(){var t,e,i=this,n=this,a=n?n.document:null,o=(n?n.document.documentElement:null,/^(["'](\\.|[^"\\\n\r])*?["']|[,:{}\[\]0-9.\-+Eaeflnr-u \n\r\t])+?$/),l=/^-ms-/,s=/[\-_]([\da-z])/gi,r=/([A-Z])/g,d=/\./,c=/[-|+]?[\D]/gi,u=/\D/gi,h=new RegExp("([0-9])([0-9][0-9][0-9][,.])"),p=/&/g,f=/=/,m=/[ ]+/g,g={};g.guid=1,g.getGuid=function(){return g.guid++},g.info=t=function(){function i(t,i){return t={href:n.location.href,param:n.location.search,referrer:a.referrer,pathname:n.location.pathname,hostname:n.location.hostname,port:n.location.port},i=t.href.split(/[\?#]/),t.param=t.param.replace("?",""),t.url=i[0],t.href.search("#")>-1&&(t.hashdata=e.last(i)),i=null,t.baseUrl=e.left(t.href,"?").replace(t.pathname,""),t}function o(e,i,n){return t.errorMsg&&t.errorMsg[e]?{className:e,errorCode:i,methodName:n,msg:t.errorMsg[e][i]}:{className:e,errorCode:i,methodName:n}}var l="1.3.58",s="",r=function(){console.error(e.toArray(arguments).join(":"))},d={BACKSPACE:8,TAB:9,RETURN:13,ESC:27,LEFT:37,UP:38,RIGHT:39,DOWN:40,DELETE:46,HOME:36,END:35,PAGEUP:33,PAGEDOWN:34,INSERT:45,SPACE:32},c=[{label:"SUN"},{label:"MON"},{label:"TUE"},{label:"WED"},{label:"THU"},{label:"FRI"},{label:"SAT"}],u=function(t,e,i,a,o,l){return n&&n.navigator?(t=navigator.userAgent.toLowerCase(),e=t.search(/mobile/g)!=-1,l,t.search(/iphone/g)!=-1?{name:"iphone",version:0,mobile:!0}:t.search(/ipad/g)!=-1?{name:"ipad",version:0,mobile:!0}:t.search(/android/g)!=-1?(a=/(android)[ \/]([\w.]+)/.exec(t)||[],l=a[2]||"0",{name:"android",version:l,mobile:e}):(i="",a=/(opr)[ \/]([\w.]+)/.exec(t)||/(chrome)[ \/]([\w.]+)/.exec(t)||/(webkit)[ \/]([\w.]+)/.exec(t)||/(msie) ([\w.]+)/.exec(t)||t.indexOf("compatible")<0&&/(mozilla)(?:.*? rv:([\w.]+)|)/.exec(t)||[],o=a[1]||"",l=a[2]||"0","msie"==o&&(o="ie"),{name:o,version:l,mobile:e})):{}}(),h=!("undefined"==typeof window||"undefined"==typeof navigator||!n.document),p=n&&/Firefox/i.test(navigator.userAgent)?"DOMMouseScroll":"mousewheel",f={},m=!!n&&("ontouchstart"in n||navigator.maxTouchPoints>0||navigator.msMaxTouchPoints>0),g=!!n&&(n.FileReader&&n.File&&n.FileList&&n.Blob);return{errorMsg:f,version:l,baseUrl:s,onerror:r,eventKeys:d,weekNames:c,browser:u,isBrowser:h,supportTouch:m,supportFileApi:g,wheelEnm:p,urlUtil:i,getError:o}}(),g.util=e=function(){function x(t,e){if(Q(t))return[];var i,n=0,a=t.length,o=void 0===a||"function"==typeof t;if(o){for(i in t)if("undefined"!=typeof t[i]&&e.call(t[i],i,t[i])===!1)break}else for(;n0&&("undefined"==typeof t[n]||(a=e.call(i,a,t[--n]))!==!1););return a}function k(t,e){if(Q(t))return[];var i,n,a=0,o=t.length,l=[];if(j(t))for(i in t)"undefined"!=typeof t[i]&&(n=e.call(t[i],i,t[i]))&&l.push(t[i]);else for(;a0&&(e+=","),e+=C(t[i]);e+="]"}else if(g.util.isObject(t)){e+="{";var a=[];x(t,function(t,e){a.push('"'+t+'": '+C(e))}),e+=a.join(", "),e+="}"}else e=g.util.isString(t)?'"'+t+'"':g.util.isNumber(t)?t:g.util.isUndefined(t)?"undefined":g.util.isFunction(t)?'"{Function}"':t;return e}function $(t,e){if(!e&&!o.test(t))return{error:500,msg:"syntax error"};try{return new Function("","return "+t)()}catch(i){return{error:500,msg:"syntax error"}}}function S(t){var e;return null!=t&&t==t.window?e="window":t&&1==t.nodeType?e="element":t&&11==t.nodeType?e="fragment":null===t?e="null":"undefined"==typeof t?e="undefined":"[object Object]"==xt.call(t)?e="object":"[object Array]"==xt.call(t)?e="array":"[object String]"==xt.call(t)?e="string":"[object Number]"==xt.call(t)?e="number":"[object NodeList]"==xt.call(t)?e="nodelist":"function"==typeof t&&(e="function"),e}function T(t){return null!=t&&t==t.window}function E(t){return!(!t||1!=t.nodeType&&11!=t.nodeType)}function j(t){return"[object Object]"==xt.call(t)}function N(t){return"[object Array]"==xt.call(t)}function D(t){return"function"==typeof t}function z(t){return"[object String]"==xt.call(t)}function P(t){return"[object Number]"==xt.call(t)}function K(t){return!!("[object NodeList]"==xt.call(t)||"undefined"!=typeof t&&t&&t[0]&&1==t[0].nodeType)}function R(t){return"undefined"==typeof t}function Q(t){return"undefined"==typeof t||null===t||""===t}function q(t){return t instanceof Date&&!isNaN(t.valueOf())}function A(t){var e=!1;if(t)if(t instanceof Date&&!isNaN(t.valueOf()))e=!0;else{if(t.length>7&&nt(t)instanceof Date)return!0;if(t=t.replace(/\D/g,""),t.length>7){var i=t.substr(4,2),n=t.substr(6,2);t=nt(t),t.getMonth()==i-1&&t.getDate()==n&&(e=!0)}}else;return e}function M(t){if(j(t)){var e=Object.keys(t),i={};return i[e[0]]=t[e[0]],i}return N(t)?t[0]:void console.error("ax5.util.object.first","argument type error")}function O(t){if(j(t)){var e=Object.keys(t),i={};return i[e[e.length-1]]=t[e[e.length-1]],i}return N(t)?t[t.length-1]:void console.error("ax5.util.object.last","argument type error")}function H(t,e,i,n){var o;return"number"==typeof i&&(o=new Date,o.setDate(o.getDate()+i)),n=n||{},a.cookie=[escape(t),"=",escape(e),o?"; expires="+o.toUTCString():"",n.path?"; path="+n.path:"",n.domain?"; domain="+n.domain:"",n.secure?"; secure":""].join("")}function G(t){for(var e=t+"=",i=a.cookie.split(";"),n=0,o=i.length;n-1?t.substr(0,t.indexOf(e)):"":P(e)?t.substr(0,e):""}function B(t,e){return"undefined"==typeof t||"undefined"==typeof e?"":(t=""+t,z(e)?t.lastIndexOf(e)>-1?t.substr(t.lastIndexOf(e)+1):"":P(e)?t.substr(t.length-e):"")}function V(t){return t.replace(l,"ms-").replace(s,function(t,e){return e.toUpperCase()})}function W(t){return V(t).replace(r,function(t,e){return"-"+e.toLowerCase()})}function U(t,e){var i,n=(""+t).split(d),a=Number(n[0])<0||"-0"==n[0],o=0;return n[0]=n[0].replace(c,""),n[1]?(n[1]=n[1].replace(u,""),o=Number(n[0]+"."+n[1])||0):o=Number(n[0])||0,i=a?-o:o,x(e,function(t,e){"round"==t&&(i=P(e)?e<0?+(Math.round(i+"e-"+Math.abs(e))+"e+"+Math.abs(e)):+(Math.round(i+"e+"+e)+"e-"+e):Math.round(i)),"floor"==t&&(i=Math.floor(i)),"ceil"==t?i=Math.ceil(i):"money"==t?i=function(t){var e=""+t;if(isNaN(e)||""==e)return"";var i=e.split(".");i[0]+=".";do i[0]=i[0].replace(h,"$1,$2");while(h.test(i[0]));return i.length>1?i.join(""):i[0].split(".")[0]}(i):"abs"==t?i=Math.abs(Number(i)):"byte"==t&&(i=function(t){t=Number(i);var e="KB",n=t/1024;return n/1024>1&&(e="MB",n/=1024),n/1024>1&&(e="GB",n/=1024),U(n,{round:1})+e}(i))}),i}function Y(t){return"undefined"!=typeof t.length?Array.prototype.slice.call(t):[]}function X(t,e){var i=e.length,n=t.length,a=0;if("number"==typeof i)for(;a15)f.test(e)||p.test(e)?e=new Date(e):(r=e.split(/ /g),u=r[0].split(/\D/g),n=u[0],a=parseFloat(u[1]),o=parseFloat(u[2]),c=r[1]||"09:00",d=c.substring(0,5).split(":"),l=parseFloat(d[0]),s=parseFloat(d[1]),"AM"!==B(c,2)&&"PM"!==B(c,2)||(l+=12),e=it(n,a-1,o,l,s));else if(14==e.length)h=e.replace(/\D/g,""),e=it(h.substr(0,4),h.substr(4,2)-1,U(h.substr(6,2)),U(h.substr(8,2)),U(h.substr(10,2)),U(h.substr(12,2)));else if(e.length>7)h=e.replace(/\D/g,""),e=it(h.substr(0,4),h.substr(4,2)-1,U(h.substr(6,2)));else if(e.length>4)h=e.replace(/\D/g,""),e=it(h.substr(0,4),h.substr(4,2)-1,1);else{if(e.length>2)return h=e.replace(/\D/g,""),it(h.substr(0,4),h.substr(4,2)-1,1);e=new Date}return"undefined"==typeof i?e:("add"in i&&(e=function(t,e){var i,n,a,o,l=864e5;return"undefined"!=typeof e.d?t.setTime(t.getTime()+e.d*l):"undefined"!=typeof e.m?(i=t.getFullYear(),n=t.getMonth(),a=t.getDate(),i+=parseInt(e.m/12),n+=e.m%12,o=lt(i,n),o\&\"]/gm,function(t){switch(t){case"<":return"<";case">":return">";case"&":return"&";case'"':return""";default:return t}}):""}function mt(t){return"[object String]"!=xt.call(t)?t:t?t.replace(/(<)|(>)|(&)|(")/gm,function(t){switch(t){case"<":return"<";case">":return">";case"&":return"&";case""":return'"';default:return t}}):""}function gt(t){function e(t){this.value=t,this.toString=function(){return this.value},this.format=function(){for(var t=[],e=0,i=arguments.length;e>>0;if("function"!=typeof t)throw TypeError();var n,a=arguments[1];for(n=0;ni));n+=1);return t.removeRule(0),l};document.querySelectorAll=function(t){return e(t,1/0)},document.querySelector=function(t){return e(t,1)[0]||null}}}(),String.prototype.trim||!function(){String.prototype.trim=function(){return this.replace(e,"")}}(),window.JSON||(window.JSON={parse:function(t){return new Function("","return "+t)()},stringify:function(){var t,e=/["]/g;return t=function(i){var n,a,o;switch(n="undefined"==typeof i?"undefined":_typeof(i)){case"string":return'"'+i.replace(e,'\\"')+'"';case"number":case"boolean":return i.toString();case"undefined":return"undefined";case"function":return'""';case"object":if(!i)return"null";if(n="",i.splice){for(a=0,o=i.length;a=9)return!1;var t=Array.prototype.splice;Array.prototype.splice=function(){var e=Array.prototype.slice.call(arguments);return"undefined"==typeof e[1]&&(e[1]=this.length-e[0]),t.apply(this,e)}}(),function(){var t=Array.prototype.slice;try{t.call(document.documentElement)}catch(e){Array.prototype.slice=function(e,i){if(i="undefined"!=typeof i?i:this.length,"[object Array]"===Object.prototype.toString.call(this))return t.call(this,e,i);var n,a,o=[],l=this.length,s=e||0;s=s>=0?s:Math.max(0,l+s);var r="number"==typeof i?Math.min(i,l):l;if(i<0&&(r=l+i),a=r-s,a>0)if(o=new Array(a),this.charAt)for(n=0;n"'\/]/g,function(t){return v[t]})}function r(e,i){function a(){if(x&&!v)for(;g.length;)delete f[g.pop()];else g=[];x=!1,v=!1}function o(t){if("string"==typeof t&&(t=t.split(y,2)),!m(t)||2!==t.length)throw new Error("Invalid tags: "+t);s=new RegExp(n(t[0])+"\\s*"),r=new RegExp("\\s*"+n(t[1])),h=new RegExp("\\s*"+n("}"+t[1]))}if(!e)return[];var s,r,h,p=[],f=[],g=[],x=!1,v=!1;o(i||t.tags);for(var k,C,$,S,T,E,j=new u(e);!j.eos();){if(k=j.pos,$=j.scanUntil(s))for(var N=0,D=$.length;N0?o[o.length-1][4]:n;break;default:a.push(e)}return n}function u(t){this.string=t,this.tail=t,this.pos=0}function h(t,e){this.view=t,this.cache={".":this.view,"@each":function(){var t=[];for(var e in this)t.push({"@key":e,"@value":this[e]});return t}},this.parent=e}function p(){this.cache={}}var f=Object.prototype.toString,m=Array.isArray||function(t){return"[object Array]"===f.call(t)},g=RegExp.prototype.test,x=/\S/,v={"&":"&","<":"<",">":">",'"':""","'":"'","/":"/"},b=/\s*/,y=/\s+/,w=/\s*=/,_=/\s*\}/,I=/#|\^|\/|>|\{|&|=|!/;u.prototype.eos=function(){return""===this.tail},u.prototype.scan=function(t){var e=this.tail.match(t);if(!e||0!==e.index)return"";var i=e[0];return this.tail=this.tail.substring(i.length),this.pos+=i.length,i},u.prototype.scanUntil=function(t){var e,i=this.tail.search(t);switch(i){case-1:e=this.tail,this.tail="";break;case 0:e="";break;default:e=this.tail.substring(0,i),this.tail=this.tail.substring(i)}return this.pos+=e.length,e},h.prototype.push=function(t){return new h(t,this)},h.prototype.lookup=function(t){var i,n=this.cache;if(n.hasOwnProperty(t))i=n[t];else{for(var o,l,s=this,r=!1;s;){if(t.indexOf(".")>0)for(i=s.view,o=t.split("."),l=0;null!=i&&l"===o?l=this.renderPartial(a,e,i,n):"&"===o?l=this.unescapedValue(a,e):"name"===o?l=this.escapedValue(a,e):"text"===o&&(l=this.rawValue(a)),void 0!==l&&(s+=l);return s},p.prototype.renderSection=function(t,i,n,a){function o(t){return l.render(t,i,n)}var l=this,s="",r=i.lookup(t[1]);if(r){if(m(r))for(var d=0,c=r.length;d"),input:i.input,btns:i.btns,_crlf:function(){return this.replace(/\n/g,"
")}};try{return t.tmpl.get.call(this,"dialogDisplay",a)}finally{a=null}},s=function(t,e){var i,a={};t.id=t.id||n.id,i={width:t.width},jQuery(document.body).append(l.call(this,t.id,t)),this.activeDialog=jQuery("#"+t.id),this.activeDialog.css({width:i.width}),t.height=i.height=this.activeDialog.height(),"undefined"==typeof t.position||"center"===t.position?(a.top=jQuery(window).height()/2-i.height/2,a.left=jQuery(window).width()/2-i.width/2):(a.left=t.position.left||0,a.top=t.position.top||0),n.zIndex&&(a["z-index"]=n.zIndex),this.activeDialog.css(a),"prompt"===t.dialogType?this.activeDialog.find("[data-dialog-prompt]").get(0).focus():this.activeDialog.find("[data-dialog-btn]").get(0).focus(),this.activeDialog.find("[data-dialog-btn]").on(n.clickEventName,function(i){d.call(this,i||window.event,t,e)}.bind(this)),jQuery(window).bind("keydown.ax5dialog",function(i){c.call(this,i||window.event,t,e)}.bind(this)),jQuery(window).bind("resize.ax5dialog",function(t){r.call(this,t||window.event)}.bind(this)),o.call(this,t,{self:this,state:"open"}),a=null,i=null},r=function(t){if(!this.activeDialog)return this; -var e=a.dialogConfig,i={width:e.width,height:e.height};return"undefined"==typeof e.position||"center"===e.position?(i.top=window.innerHeight/2-i.height/2,i.left=window.innerWidth/2-i.width/2):(i.left=e.position.left||0,i.top=e.position.top||0),i.left<0&&(i.left=0),i.top<0&&(i.top=0),this.activeDialog.css(i),e=null,i=null,this},d=function(t,e,n,a,o){var l;if(t.srcElement&&(t.target=t.srcElement),a=i.findParentNode(t.target,function(t){if(t.getAttribute("data-dialog-btn"))return!0})){if(o=a.getAttribute("data-dialog-btn"),l={self:this,key:o,value:e.btns[o],dialogId:e.id,btnTarget:a},"prompt"===e.dialogType){var s=null;for(var r in e.input)if(l[r]=this.activeDialog.find("[data-dialog-prompt="+r+"]").val(),""==l[r]||null==l[r]){s=r;break}}if(e.btns[o].onClick)e.btns[o].onClick.call(l,o);else if("alert"===e.dialogType)n&&n.call(l,o),this.close({doNotCallback:!0});else if("confirm"===e.dialogType)n&&n.call(l,o),this.close({doNotCallback:!0});else if("prompt"===e.dialogType){if("ok"===o&&s)return this.activeDialog.find('[data-dialog-prompt="'+s+'"]').get(0).focus(),!1;n&&n.call(l,o),this.close({doNotCallback:!0})}}l=null,e=null,n=null,a=null,o=null},c=function(t,e,i,n,a){var o,l=null;if(t.keyCode==ax5.info.eventKeys.ESC&&this.close(),"prompt"===e.dialogType&&t.keyCode==ax5.info.eventKeys.RETURN){o={self:this,key:a,value:e.btns[a],dialogId:e.id,btnTarget:n};for(var s in e.input)if(o[s]=this.activeDialog.find("[data-dialog-prompt="+s+"]").val(),""==o[s]||null==o[s]){l=s;break}if(l)return o=null,l=null,!1;i&&i.call(o,a),this.close({doNotCallback:!0})}o=null,l=null,e=null,i=null,n=null,a=null};this.init=function(){this.onStateChanged=n.onStateChanged},this.alert=function(t,e,o){return i.isString(t)&&(t={title:n.title,msg:t}),this.activeDialog?(o?console.log(ax5.info.getError("ax5dialog","501","alert")):setTimeout(function(){this.alert(t,e,1)}.bind(this),Number(n.animateTime)+100),this):(a.dialogConfig={},jQuery.extend(!0,a.dialogConfig,n,t),t=a.dialogConfig,t.dialogType="alert",t.theme=t.theme||n.theme||"",t.callback=e,"undefined"==typeof t.btns&&(t.btns={ok:{label:n.lang.ok,theme:t.theme}}),s.call(this,t,e),this)},this.confirm=function(t,e,o){return i.isString(t)&&(t={title:n.title,msg:t}),this.activeDialog?(o?console.log(ax5.info.getError("ax5dialog","501","confirm")):setTimeout(function(){this.confirm(t,e,1)}.bind(this),Number(n.animateTime)+100),this):(a.dialogConfig={},jQuery.extend(!0,a.dialogConfig,n,t),t=a.dialogConfig,t.dialogType="confirm",t.theme=t.theme||n.theme||"",t.callback=e,"undefined"==typeof t.btns&&(t.btns={ok:{label:n.lang.ok,theme:t.theme},cancel:{label:n.lang.cancel}}),s.call(this,t,e),this)},this.prompt=function(t,e,o){return i.isString(t)&&(t={title:n.title,msg:t}),this.activeDialog?(o?console.log(ax5.info.getError("ax5dialog","501","prompt")):setTimeout(function(){this.prompt(t,e,1)}.bind(this),Number(n.animateTime)+100),this):(a.dialogConfig={},jQuery.extend(!0,a.dialogConfig,n,t),t=a.dialogConfig,t.dialogType="prompt",t.theme=t.theme||n.theme||"",t.callback=e,"undefined"==typeof t.input&&(t.input={value:{label:""}}),"undefined"==typeof t.btns&&(t.btns={ok:{label:n.lang.ok,theme:t.theme},cancel:{label:n.lang.cancel}}),s.call(this,t,e),this)},this.close=function(t){var e,i;return this.activeDialog&&(e=a.dialogConfig,this.activeDialog.addClass("destroy"),jQuery(window).unbind("keydown.ax5dialog"),jQuery(window).unbind("resize.ax5dialog"),setTimeout(function(){this.activeDialog&&(this.activeDialog.remove(),this.activeDialog=null),i={self:this,state:"close",dialogId:e.id},!e.callback||t&&t.doNotCallback||e.callback.call(i),e&&e.onStateChanged?e.onStateChanged.call(i,i):this.onStateChanged&&this.onStateChanged.call(i,i),e=null,i=null}.bind(this),n.animateTime)),this},this.main=function(){e.dialog_instance=e.dialog_instance||[],e.dialog_instance.push(this),arguments&&i.isObject(arguments[0])&&this.setConfig(arguments[0])}.apply(this,arguments)};return n}()),t=ax5.ui.dialog}(),function(){var t=ax5.ui.dialog,e=function(t){return' \n
\n
\n {{{title}}}\n
\n
\n
{{{msg}}}
\n \n {{#input}}\n
\n {{#@each}}\n
\n {{#@value.label}}\n \n {{/@value.label}}\n \n {{#@value.help}}\n

{{#_crlf}}{{.}}{{/_crlf}}

\n {{/@value.help}}\n
\n {{/@each}}\n
\n {{/input}}\n \n
\n
\n {{#btns}}\n {{#@each}}\n \n {{/@each}}\n {{/btns}}\n
\n
\n
\n
\n '};t.tmpl={dialogDisplay:e,get:function(e,i,n){return ax5.mustache.render(t.tmpl[e].call(this,n),i)}}}(),function(){var t,e=ax5.ui,i=ax5.util;e.addClass({className:"mask",version:"1.3.58"},function(){var n=function(){var n,a=this;this.instanceId=ax5.getGuid(),this.config={theme:"",target:jQuery(document.body).get(0)},this.maskContent="",this.status="off",n=this.config;var o=function(t,e){return t&&t.onStateChanged?t.onStateChanged.call(e,e):this.onStateChanged&&this.onStateChanged.call(e,e),t=null,e=null,!0},l=function(e){return"undefined"==typeof e.templateName&&(e.templateName="defaultMask"),t.tmpl.get.call(this,e.templateName,e)},s=function(t){this.maskContent=t};this.init=function(){this.onStateChanged=n.onStateChanged,this.onClick=n.onClick,this.config.content&&s.call(this,this.config.content)},this.open=function(t){"on"===this.status&&this.close(),t&&t.content&&s.call(this,t.content),t&&"undefined"==typeof t.templateName&&(t.templateName="defaultMask"),a.maskConfig={},jQuery.extend(!0,a.maskConfig,this.config,t);var e,i=a.maskConfig,n=i.target,r=jQuery(n),d="ax-mask-"+ax5.getGuid(),c={},u={},h=i.templateName,p=l({theme:i.theme,maskId:d,body:this.maskContent,templateName:h});return jQuery(document.body).append(p),n&&n!==jQuery(document.body).get(0)&&(c={position:i.position||"absolute",left:r.offset().left,top:r.offset().top,width:r.outerWidth(),height:r.outerHeight()},"undefined"!=typeof a.maskConfig.zIndex&&(c["z-index"]=a.maskConfig.zIndex),r.addClass("ax-masking"),jQuery(window).bind("resize.ax5mask-"+this.instanceId,function(t){this.align()}.bind(this))),this.$mask=e=jQuery("#"+d),this.$target=r,this.status="on",e.css(c),i.onClick&&e.on("click",function(t){u={self:a,state:"open",type:"click"},a.maskConfig.onClick.call(u,u)}),o.call(this,null,{self:this,state:"open"}),t=null,i=null,n=null,r=null,d=null,e=null,c=null,u=null,h=null,p=null,this},this.close=function(t){if(this.$mask){var e=function(){this.status="off",this.$mask.remove(),this.$target.removeClass("ax-masking"),o.call(this,null,{self:this,state:"close"}),jQuery(window).unbind("resize.ax5mask-"+this.instanceId)};t?setTimeout(function(){e.call(this)}.bind(this),t):e.call(this)}return this},this.align=function(){if(this.maskConfig&&this.maskConfig.target&&this.maskConfig.target!==jQuery(document.body).get(0))try{var t={position:this.maskConfig.position||"absolute",left:this.$target.offset().left,top:this.$target.offset().top,width:this.$target.outerWidth(),height:this.$target.outerHeight()};this.$mask.css(t)}catch(e){}return this},this.pullRequest=function(){console.log("test pullRequest01"),console.log("test pullRequest02")},this.main=function(){e.mask_instance=e.mask_instance||[],e.mask_instance.push(this),arguments&&i.isObject(arguments[0])&&this.setConfig(arguments[0])}.apply(this,arguments)};return n}()),t=ax5.ui.mask}(),function(){var t=ax5.ui.mask,e=function(t){return'\n
\n
\n
\n
\n {{{body}}}\n
\n
\n
\n '};t.tmpl={defaultMask:e,get:function(e,i,n){return ax5.mustache.render(t.tmpl[e].call(this,n),i)}}}(),function(){var t,e=ax5.ui,i=ax5.util;e.addClass({className:"toast",version:"1.3.58"},function(){var n=function(){var n,a=this,o=0,l=null;this.instanceId=ax5.getGuid(),this.config={clickEventName:"click",theme:"default",width:300,icon:"",closeIcon:"",msg:"",lang:{ok:"ok",cancel:"cancel"},displayTime:3e3,animateTime:250,containerPosition:"bottom-left"},this.toastContainer=null,this.queue=[],n=this.config;var s=function(t,e){return t&&t.onStateChanged?t.onStateChanged.call(e,e):this.onStateChanged&&this.onStateChanged.call(e,e),t=null,e=null,!0},r=function(e,i){var n={toastId:e,theme:i.theme,icon:i.icon,msg:(i.msg||"").replace(/\n/g,"
"),btns:i.btns,closeIcon:i.closeIcon};try{return t.tmpl.get.call(this,"toastDisplay",n)}finally{e=null,n=null}},d=function(t,e){l&&clearTimeout(l);var d,u={width:t.width};return t.id="ax5-toast-"+a.containerId+"-"+ ++o,jQuery("#"+t.id).get(0)?this:("bottom"==i.left(n.containerPosition,"-")?this.toastContainer.append(r(t.id,t)):this.toastContainer.prepend(r(t.id,t)),d=jQuery("#"+t.id),d.css({width:u.width}),t.toastBox=d,this.queue.push(t),s.call(this,t,{self:this,state:"open",toastId:t.id}),"push"===t.toastType?(setTimeout(function(){this.close(t,e)}.bind(this),n.displayTime),d.find("[data-ax-toast-btn]").on(n.clickEventName,function(i){c.call(this,i||window.event,t,d,e)}.bind(this))):"confirm"===t.toastType&&d.find("[data-ax-toast-btn]").on(n.clickEventName,function(i){c.call(this,i||window.event,t,d,e)}.bind(this)),void(u=null))},c=function(t,e,n,a,o,l){if(o=i.findParentNode(t.target,function(t){if(t.getAttribute("data-ax-toast-btn"))return!0})){l=o.getAttribute("data-ax-toast-btn");var s={key:l,value:e.btns?e.btns[l]:l,toastId:e.id,btn_target:o};e.btns&&e.btns[l].onClick?e.btns[l].onClick.call(s,l):"push"===e.toastType?(a&&a.call(s,l),this.close(e,a)):"confirm"===e.toastType&&(a&&a.call(s,l),this.close(e,a))}t=null,e=null,n=null,a=null,o=null,l=null};this.init=function(){this.onStateChanged=n.onStateChanged,a.containerId=ax5.getGuid();var t=[];n.zIndex&&t.push("z-index:"+n.zIndex),jQuery(document.body).append('
'),this.toastContainer=jQuery('[data-toast-container="'+a.containerId+'"]')},this.push=function(t,e){return a.containerId||this.init(),i.isString(t)&&(t={title:n.title,msg:t}),t.toastType="push",a.dialogConfig={},jQuery.extend(!0,a.dialogConfig,n,t),t=a.dialogConfig,d.call(this,t,e),t=null,e=null,this},this.confirm=function(t,e){return a.containerId||this.init(),i.isString(t)&&(t={title:n.title,msg:t}),t.toastType="confirm",a.dialogConfig={},jQuery.extend(!0,a.dialogConfig,n,t),t=a.dialogConfig,"undefined"==typeof t.btns&&(t.btns={ok:{label:n.lang.ok,theme:t.theme}}),d.call(this,t,e),t=null,e=null,this},this.close=function(t,e){"undefined"==typeof t&&(t=i.last(this.queue));var a=t.toastBox;return a.addClass("push"==t.toastType?"removed":"destroy"),this.queue=i.filter(this.queue,function(){return t.id!=this.id}),setTimeout(function(){var i={toastId:t.id};a.remove(),e&&e.call(i),i={self:this,state:"close",toastId:t.id},s.call(this,t,i),0===this.queue.length&&(l&&clearTimeout(l),l=setTimeout(function(){0===this.queue.length&&(o=0)}.bind(this),3e3)),i=null,t=null,e=null,a=null}.bind(this),n.animateTime),this},this.main=function(){e.toast_instance=e.toast_instance||[],e.toast_instance.push(this),arguments&&i.isObject(arguments[0])&&this.setConfig(arguments[0])}.apply(this,arguments)};return n}()),t=ax5.ui.toast}(),function(){var t=ax5.ui.toast,e=function(t){return'\n
\n {{#icon}}\n
{{{.}}}
\n {{/icon}}\n
{{{msg}}}
\n {{#btns}}\n
\n
\n {{#@each}}\n \n {{/@each}}\n
\n
\n {{/btns}}\n {{^btns}}\n {{{closeIcon}}}\n {{/btns}}\n
\n
'};t.tmpl={toastDisplay:e,get:function(e,i,n){return ax5.mustache.render(t.tmpl[e].call(this,n),i)}}}(),function(){var t,e=ax5.ui,i=ax5.util;e.addClass({className:"modal",version:"1.3.58"},function(){var n=function(){var n,a=this,o={mousedown:ax5.info.supportTouch?"touchstart":"mousedown",mousemove:ax5.info.supportTouch?"touchmove":"mousemove",mouseup:ax5.info.supportTouch?"touchend":"mouseup"},l=function(t){var e=t;return"changedTouches"in t&&(e=t.changedTouches[0]),{clientX:e.clientX,clientY:e.clientY}};this.instanceId=ax5.getGuid(),this.config={id:"ax5-modal-"+this.instanceId,position:{left:"center",top:"middle",margin:10},minimizePosition:"bottom-right",clickEventName:"click",theme:"default",width:300,height:400,closeToEsc:!0,disableDrag:!1,animateTime:250},this.activeModal=null,this.$={},n=this.config;var s=function(t,e){return t&&t.onStateChanged?t.onStateChanged.call(e,e):this.onStateChanged&&this.onStateChanged.call(e,e),!0},r=function(e,i){var n={modalId:e,theme:i.theme,header:i.header,fullScreen:i.fullScreen?"fullscreen":"",styles:"",iframe:i.iframe,iframeLoadingMsg:i.iframeLoadingMsg};return i.zIndex&&(n.styles+="z-index:"+i.zIndex+";"),i.absolute&&(n.styles+="position:absolute;"),n.iframe&&"string"==typeof n.iframe.param&&(n.iframe.param=ax5.util.param(n.iframe.param)),t.tmpl.get.call(this,"content",n,{})},d=function(t,e){var d;jQuery(document.body).append(r.call(this,t.id,t)),this.activeModal=jQuery("#"+t.id),this.$={root:this.activeModal,header:this.activeModal.find('[data-modal-els="header"]'),body:this.activeModal.find('[data-modal-els="body"]')},t.iframe&&(this.$["iframe-wrap"]=this.activeModal.find('[data-modal-els="iframe-wrap"]'),this.$.iframe=this.activeModal.find('[data-modal-els="iframe"]'),this.$["iframe-form"]=this.activeModal.find('[data-modal-els="iframe-form"]'),this.$["iframe-loading"]=this.activeModal.find('[data-modal-els="iframe-loading"]')),this.align(),d={self:this,id:t.id,theme:t.theme,width:t.width,height:t.height,state:"open",$:this.$},t.iframe&&(this.$["iframe-wrap"].css({height:t.height}),this.$.iframe.css({height:t.height}),this.$["iframe-form"].attr({method:t.iframe.method}),this.$["iframe-form"].attr({target:t.id+"-frame"}),this.$["iframe-form"].attr({action:t.iframe.url}),this.$.iframe.on("load",function(){d.state="load",t.iframeLoadingMsg&&this.$["iframe-loading"].hide(),s.call(this,t,d)}.bind(this)),t.iframeLoadingMsg||this.$.iframe.show(),this.$["iframe-form"].submit()),e&&e.call(d),s.call(this,t,d),t.closeToEsc&&jQuery(window).bind("keydown.ax-modal",function(t){u.call(this,t||window.event)}.bind(this)),jQuery(window).bind("resize.ax-modal",function(t){this.align(null,t||window.event)}.bind(this)),this.activeModal.find("[data-modal-header-btn]").on(n.clickEventName,function(e){c.call(this,e||window.event,t)}.bind(this)),this.$.header.bind(o.mousedown,function(e){if(t.isFullScreen)return!1;var n=i.findParentNode(e.target,function(t){if(t.getAttribute("data-modal-header-btn"))return!0});n||1==t.disableDrag||(a.mousePosition=l(e),p.on.call(a))}).bind("dragstart",function(t){return i.stopEvent(t),!1})},c=function(t,e,n,a,o){var l;t.srcElement&&(t.target=t.srcElement),a=i.findParentNode(t.target,function(t){if(t.getAttribute("data-modal-header-btn"))return!0}),a&&(o=a.getAttribute("data-modal-header-btn"),l={self:this,key:o,value:e.header.btns[o],dialogId:e.id,btnTarget:a},e.header.btns[o].onClick&&e.header.btns[o].onClick.call(l,o)),l=null,e=null,n=null,a=null,o=null},u=function(t){t.keyCode==ax5.info.eventKeys.ESC&&this.close()},h={"top-left":function(){this.align({left:"left",top:"top"})},"top-right":function(){this.align({left:"right",top:"top"})},"bottom-left":function(){this.align({left:"left",top:"bottom"})},"bottom-right":function(){this.align({left:"right",top:"bottom"})},"center-middle":function(){this.align({left:"center",top:"middle"})}},p={on:function(){var t=this.activeModal.css("z-index"),e=this.activeModal.position(),i={width:this.activeModal.outerWidth(),height:this.activeModal.outerHeight()},l={width:jQuery(window).width(),height:jQuery(window).height()},s=function(t){a.__dx=t.clientX-a.mousePosition.clientX,a.__dy=t.clientY-a.mousePosition.clientY;var n=0,o=l.width-i.width,s=0,r=l.height-i.height;return n>e.left+a.__dx?a.__dx=-e.left:oe.top+a.__dy?a.__dy=-e.top:r
'),a.resizer=jQuery('
'),a.resizerBg.css({zIndex:t}),a.resizer.css({left:e.left,top:e.top,width:i.width,height:i.height,zIndex:t+1}),jQuery(document.body).append(a.resizerBg).append(a.resizer),a.activeModal.addClass("draged")),jQuery(document.body).bind(o.mousemove+".ax5modal-"+n.id,function(t){a.resizer.css(s(t))}).bind(o.mouseup+".ax5layout-"+this.instanceId,function(t){p.off.call(a)}).bind("mouseleave.ax5layout-"+this.instanceId,function(t){p.off.call(a)}),jQuery(document.body).attr("unselectable","on").css("user-select","none").on("selectstart",!1)},off:function(){var t=function(){var t=this.activeModal.offset();t.left+=this.__dx-$(document).scrollLeft(),t.top+=this.__dy-$(document).scrollTop(),this.activeModal.css(t)};this.resizer&&(this.activeModal.removeClass("draged"),this.resizer.remove(),this.resizer=null,this.resizerBg.remove(),this.resizerBg=null,t.call(this)),jQuery(document.body).unbind(o.mousemove+".ax5modal-"+n.id).unbind(o.mouseup+".ax5modal-"+n.id).unbind("mouseleave.ax5modal-"+n.id),jQuery(document.body).removeAttr("unselectable").css("user-select","auto").off("selectstart")}};this.init=function(){this.onStateChanged=n.onStateChanged},this.open=function(t,e){return this.activeModal||(t=a.modalConfig=jQuery.extend(!0,{},n,t),d.call(this,t,e)),this},this.close=function(t){return this.activeModal&&(t=a.modalConfig,this.activeModal.addClass("destroy"),jQuery(window).unbind("keydown.ax-modal"),jQuery(window).unbind("resize.ax-modal"),setTimeout(function(){if(this.activeModal){if(t.iframe){var e=this.$.iframe;if(e){var i=e.get(0),n=i.contentDocument?i.contentDocument:i.contentWindow.document;try{$(n.body).children().each(function(){$(this).remove()})}catch(a){}n.innerHTML="",e.attr("src","about:blank").remove(),window.CollectGarbage&&window.CollectGarbage()}}this.activeModal.remove(),this.activeModal=null}s.call(this,t,{self:this,state:"close"})}.bind(this),n.animateTime)),this.minimized=!1,this},this.minimize=function(){return function(t){if(this.minimized!==!0){var e=a.modalConfig;"undefined"==typeof t&&(t=n.minimizePosition),this.minimized=!0,this.$.body.hide(),a.modalConfig.originalHeight=e.height,a.modalConfig.height=0,h[t].call(this),s.call(this,e,{self:this,state:"minimize"})}return this}}(),this.maximize=function(){var t=a.modalConfig;return this.minimized&&(this.minimized=!1,this.$.body.show(),a.modalConfig.height=a.modalConfig.originalHeight,a.modalConfig.originalHeight=void 0,this.align({left:"center",top:"middle"}),s.call(this,t,{self:this,state:"restore"})),this},this.css=function(t){return this.activeModal&&!a.fullScreen&&(this.activeModal.css(t),t.width&&(a.modalConfig.width=this.activeModal.width()),t.height&&(a.modalConfig.height=this.activeModal.height(),this.$.iframe&&(this.$["iframe-wrap"].css({height:a.modalConfig.height}),this.$.iframe.css({height:a.modalConfig.height})))),this},this.setModalConfig=function(t){return a.modalConfig=jQuery.extend({},a.modalConfig,t),this.align(),this},this.align=function(){return function(t,e){if(!this.activeModal)return this;var n=a.modalConfig,o={width:n.width,height:n.height},l=n.isFullScreen=function(t){return"undefined"!=typeof t&&(i.isFunction(t)?t():void 0)}(n.fullScreen);return l?(n.header&&this.$.header.show(),o.width=jQuery(window).width(),o.height=n.height,o.left=0,o.top=0):(n.header&&this.$.header.show(),t&&jQuery.extend(!0,n.position,t),n.header?(n.headerHeight=this.$.header.outerHeight(),o.height+=n.headerHeight):n.headerHeight=0,"left"==n.position.left?o.left=n.position.margin||0:"right"==n.position.left?o.left=jQuery(window).width()-o.width-(n.position.margin||0):"center"==n.position.left?o.left=jQuery(window).width()/2-o.width/2:o.left=n.position.left||0,"top"==n.position.top?o.top=n.position.margin||0:"bottom"==n.position.top?o.top=jQuery(window).height()-o.height-(n.position.margin||0):"middle"==n.position.top?o.top=jQuery(window).height()/2-o.height/2:o.top=n.position.top||0,o.left<0&&(o.left=0),o.top<0&&(o.top=0)),this.activeModal.css(o),n.iframe&&(this.$["iframe-wrap"].css({height:o.height-n.headerHeight}),this.$.iframe.css({height:o.height-n.headerHeight})),this}}(),this.main=function(){e.modal_instance=e.modal_instance||[],e.modal_instance.push(this),arguments&&i.isObject(arguments[0])&&this.setConfig(arguments[0])}.apply(this,arguments)};return n}()),t=ax5.ui.modal}(),function(){var t=ax5.ui.modal,e=function(){return' \n
\n {{#header}}\n
\n {{{title}}}\n {{#btns}}\n
\n {{#@each}}\n \n {{/@each}}\n
\n {{/btns}}\n
\n {{/header}}\n
\n {{#iframe}}\n \n
\n
{{{iframeLoadingMsg}}}
\n \n \n
\n \n {{#param}}\n {{#@each}}\n \n {{/@each}}\n {{/param}}\n
\n {{/iframe}}\n \n
\n \n '};t.tmpl={content:e,get:function(e,i,n){return ax5.mustache.render(t.tmpl[e].call(this,n),i)}}}(),function(){var t,e=ax5.ui,i=ax5.util;e.addClass({className:"calendar",version:"1.3.58"},function(){var n=function(){var n,a=this,o=1;this.instanceId=ax5.getGuid(),this.target=null,this.selection=[],this.selectionMap={},this.selectableMap={},this.markerMap={},this.printedDay={start:"",end:""},this.config={clickEventName:"click",theme:"default",startOfWeek:0,mode:"day",dateFormat:"yyyy-MM-dd",displayDate:new Date,animateTime:100,dimensions:{controlHeight:"40",controlButtonWidth:"40",colHeadHeight:"30",itemPadding:2},lang:{yearHeading:"Choose the year",monthHeading:"Choose the month",yearTmpl:"%s",months:ax5.info.months||["JAN","FEB","MAR","APR","MAY","JUN","JUL","AUG","SEP","OCT","NOV","DEC"],dayTmpl:"%s"},multipleSelect:!1,selectMode:"day",defaultMarkerTheme:"holiday",defaultPeriodTheme:"period"},n=this.config;var l=function(t,e){t&&t.onStateChanged?t.onStateChanged.call(e,e):this.onStateChanged&&this.onStateChanged.call(e,e),e=null},s=function(){var e=jQuery.extend(!0,{},n,{controlCSS:{},controlButtonCSS:{}});e.controlButtonCSS.height=e.controlCSS.height=i.cssNumber(n.dimensions.controlHeight),e.controlButtonCSS["line-height"]=e.controlCSS["line-height"]=i.cssNumber(n.dimensions.controlHeight),e.controlButtonCSS.width=i.cssNumber(n.dimensions.controlHeight),e.controlCSS=i.css(e.controlCSS),e.controlButtonCSS=i.css(e.controlButtonCSS);try{return t.tmpl.get.call(this,"frameTmpl",e)}finally{e=null}},r=function(){var t,e,a=i.date(n.displayDate),o="",l="";return n.control&&("day"==n.mode||"d"==n.mode?(o=n.control.yearTmpl?n.control.yearTmpl.replace("%s",a.getFullYear()):a.getFullYear(),l=n.control.monthTmpl?n.control.monthTmpl.replace("%s",n.lang.months[a.getMonth()]):n.lang.months[a.getMonth()],this.$["control-display"].html(function(){return n.control.yearFirst?''+o+''+l+"":''+l+''+o+""}())):"month"==n.mode||"m"==n.mode?(o=n.control.yearTmpl?n.control.yearTmpl.replace("%s",a.getFullYear()):a.getFullYear(),this.$["control-display"].html(''+o+"")):"year"!=n.mode&&"y"!=n.mode||(t=n.control.yearTmpl?n.control.yearTmpl.replace("%s",a.getFullYear()-10):a.getFullYear()-10,e=n.control.yearTmpl?n.control.yearTmpl.replace("%s",Number(a.getFullYear())+9):Number(a.getFullYear())+9,this.$["control-display"].html(t+" ~ "+e)),this.$["control-display"].find("[data-calendar-display]").on(n.clickEventName,function(t){var e,n=i.findParentNode(t.target,function(t){if(t.getAttribute("data-calendar-display"))return!0});n&&(e=n.getAttribute("data-calendar-display"),this.changeMode(e)),n=null,e=null}.bind(this))),a=null,o=null,l=null,t=null,e=null,this},d=function(e){var o,s,d,c,u,p,f=i.date(e),m=new Date(f.getFullYear(),f.getMonth(),1,12),g=n.displayDate,x=function(){var t=m.getDay();0==t&&(t=7),t-=n.startOfWeek;try{return i.date(m,{add:{d:-t}})}finally{t=null}}(),v=f.getMonth(),b={},y=this.$.body.width(),w=Math.floor(y*(6/7));for(n.dimensions.height&&(w=i.number(n.dimensions.height)-i.number(n.dimensions.colHeadHeight)),b.height=Math.floor(w/6)-2*i.number(n.dimensions.itemPadding)+"px",b["line-height"]=b.height,b.padding=i.cssNumber(n.dimensions.itemPadding),u={weekNames:[].concat(ax5.info.weekNames),list:[]},n.startOfWeek&&(u.weekNames=u.weekNames.concat(u.weekNames.slice(0,n.startOfWeek)).splice(n.startOfWeek)),u.weekNames.forEach(function(t){t.colHeadHeight=i.cssNumber(n.dimensions.colHeadHeight)}),o=x,s=0;s<6;){for(d=0;d<7;){c=(7+(d-n.startOfWeek))%7;var _=""+i.date(o,{"return":n.dateFormat}),I={row:s,col:d,isStartOfWeek:0==d,thisDate:""+_,thisDataLabel:n.lang.dayTmpl.replace("%s",o.getDate()),itemStyles:i.css(b),addClass:function(){var t="";return n.selectable?t+=a.selectableMap[_]?o.getMonth()==v?" live":"":" disable":o.getMonth()==v&&(t+=_==i.date(g,{"return":"yyyyMMdd"})?" focus":" live",0==o.getDay()&&(t+=" sunday"),6==o.getDay()&&(t+=" saturday")),t}()+" "+function(){return a.markerMap[_]?a.markerMap[_].theme||n.defaultMarkerTheme:""}()+" "+function(){return a.selectionMap[_]?"selected-day":""}()};u.list.push(I),d++,o=i.date(o,{add:{d:1}}),_=null,I=null}s++}p=t.tmpl.get.call(this,"dayTmpl",u),this.$.body.html(p),this.$.body.find("[data-calendar-item-date]").on(n.clickEventName,function(t){t=t||window.event,h.call(a,t,"date"),i.stopEvent(t)}),this.printedDay={start:x,end:o},l.call(this,null,{self:this,action:"printDay",printedDay:this.printedDay}),r.call(this),f=null,m=null,g=null,x=null,o=null,v=null,b=null,s=null,d=null,y=null,w=null,u=null,p=null},c=function(e){var o,s,d,c,u,p,f=i.date(e),m=f.getMonth(),g={},x=this.$.body.width(),v=Math.floor(x*(6/7));for(n.dimensions.height&&(v=i.number(n.dimensions.height)-i.number(n.dimensions.colHeadHeight)),g.height=Math.floor(v/4)-2*i.number(n.dimensions.itemPadding)+"px",g["line-height"]=g.height,g.padding=i.cssNumber(n.dimensions.itemPadding),u={colHeadHeight:i.cssNumber(n.dimensions.colHeadHeight),colHeadLabel:n.lang.monthHeading,list:[]},c=0,d=0,o=0;o<4;){for(s=0;s<3;){var b={row:o,col:s,isStartOfRow:0==s,thisMonth:f.getFullYear()+"-"+i.setDigit(d+1,2)+"-"+i.setDigit(f.getDate(),2),thisMonthLabel:n.lang.months[d],itemStyles:i.css(g),addClass:function(){return n.selectable?a.selectableMap[d]?"live":"disable":"live"}()+" "+function(){return d==m?"focus":""}()+" "+function(){return a.markerMap[d]?a.markerMap[d].theme||n.defaultMarkerTheme:""}()};u.list.push(b),d++,s++,b=null}o++}p=t.tmpl.get.call(this,"monthTmpl",u),this.$.body.html(p),this.$.body.find("[data-calendar-item-month]").on(n.clickEventName,function(t){t=t||window.event,h.call(a,t,"month"),i.stopEvent(t)}),this.printedDay={start:f.getFullYear()+"-"+i.setDigit(c+1,2),end:f.getFullYear()+"-"+i.setDigit(d,2)},l.call(this,null,{self:this,action:"printMonth",printedDay:this.printedDay}),r.call(this),f=null,m=null,g=null,o=null,s=null,d=null,c=null,x=null,v=null,u=null,p=null},u=function(e){var o,s,d,c,u,p,f=i.date(e),m=f.getFullYear(),g={},x=this.$.body.width(),v=Math.floor(x*(6/7));for(n.dimensions.height&&(v=i.number(n.dimensions.height)-i.number(n.dimensions.colHeadHeight)),g.height=Math.floor(v/5)-2*i.number(n.dimensions.itemPadding)+"px",g["line-height"]=g.height,g.padding=i.cssNumber(n.dimensions.itemPadding),u={colHeadHeight:i.cssNumber(n.dimensions.colHeadHeight),colHeadLabel:n.lang.yearHeading,list:[]},c=m-10,d=m-10,o=0;o<5;){for(s=0;s<4;){var b={row:o,col:s,isStartOfRow:0==s,thisYear:d+"-"+i.setDigit(f.getMonth()+1,2)+"-"+i.setDigit(f.getDate(),2),thisYearLabel:n.lang.yearTmpl.replace("%s",d),itemStyles:i.css(g),addClass:function(){return n.selectable?a.selectableMap[d]?"live":"disable":"live"}()+" "+function(){return d==m?"focus":""}()+" "+function(){return a.selectableMap[d]?a.selectableMap[d].theme||n.defaultMarkerTheme:""}()};u.list.push(b),d++,s++,b=null}o++}p=t.tmpl.get.call(this,"yearTmpl",u),this.$.body.html(p),this.$.body.find("[data-calendar-item-year]").on(n.clickEventName,function(t){t=t||window.event,h.call(this,t,"year"),i.stopEvent(t)}),this.printedDay={start:c,end:d-1},l.call(this,null,{self:this,action:"printYear",printedDay:this.printedDay}),r.call(this),f=null,m=null,g=null,o=null,s=null,d=null,c=null,x=null,v=null,u=null,p=null},h=function(t,e,l,s){var r,d,c;e=e||"date",l=i.findParentNode(t.target,function(t){if(t.getAttribute("data-calendar-item-"+e))return!0}),l&&(s=l.getAttribute("data-calendar-item-"+e),d=i.date(s,{"return":n.dateFormat}),c=!0,o=n.multipleSelect?i.isNumber(n.multipleSelect)?n.multipleSelect:2:1,n.selectable&&(a.selectableMap[d]||(c=!1)),"date"==e?c&&(a.selection.length>=o&&(r=a.selection.splice(0,a.selection.length-(o-1)),r.forEach(function(t){a.$.body.find('[data-calendar-item-date="'+i.date(t,{"return":n.dateFormat})+'"]').removeClass("selected-day")})),jQuery(l).addClass("selected-day"), -a.selection.push(s),a.onClick&&a.onClick.call({self:this,date:s,target:this.target,dateElement:l})):"month"==e?"month"==n.selectMode?c&&(a.selection.length>=o&&(r=a.selection.splice(0,a.selection.length-(o-1)),r.forEach(function(t){a.$.body.find('[data-calendar-item-month="'+i.date(t,{"return":"yyyy-MM-dd"})+'"]').removeClass("selected-month")})),jQuery(l).addClass("selected-month"),a.selection.push(s),a.onClick&&a.onClick.call({self:this,date:s,target:this.target,dateElement:l})):a.changeMode("day",s):"year"==e&&("year"==n.selectMode?c&&(a.selection.length>=o&&(r=a.selection.splice(0,a.selection.length-(o-1)),r.forEach(function(t){a.$.body.find('[data-calendar-item-year="'+i.date(t,{"return":"yyyy-MM-dd"})+'"]').removeClass("selected-year")})),jQuery(l).addClass("selected-year"),a.selection.push(s),a.onClick&&a.onClick.call({self:this,date:s,target:this.target,dateElement:l})):a.changeMode("month",s))),e=null,l=null,s=null,r=null,d=null,c=null},p=function(t,e,a){e=i.findParentNode(t.target,function(t){if(t.getAttribute("data-calendar-move"))return!0}),e&&(a=e.getAttribute("data-calendar-move"),"day"==n.mode||"d"==n.mode?("left"==a?n.displayDate=i.date(n.displayDate,{add:{m:-1}}):n.displayDate=i.date(n.displayDate,{add:{m:1}}),d.call(this,n.displayDate)):"month"==n.mode||"m"==n.mode?("left"==a?n.displayDate=i.date(n.displayDate,{add:{y:-1}}):n.displayDate=i.date(n.displayDate,{add:{y:1}}),c.call(this,n.displayDate)):"year"!=n.mode&&"y"!=n.mode||("left"==a?n.displayDate=i.date(n.displayDate,{add:{y:-10}}):n.displayDate=i.date(n.displayDate,{add:{y:10}}),u.call(this,n.displayDate))),e=null,a=null},f=function(){setTimeout(function(){if("day"===n.mode||"d"===n.mode)for(var t in this.markerMap)this.$.body.find('[data-calendar-item-date="'+t+'"]').addClass(this.markerMap[t].theme||n.defaultMarkerTheme)}.bind(this))},m=function(){setTimeout(function(){for(var t in this.selectionMap)this.$.body.find('[data-calendar-item-date="'+t+'"]').addClass("selected-day")}.bind(this))},g=function(){setTimeout(function(){if("day"===n.mode||"d"===n.mode)for(var t in this.periodMap)this.periodMap[t].label&&this.$.body.find('[data-calendar-item-date="'+t+'"]').find(".addon-footer").html(this.periodMap[t].label),this.$.body.find('[data-calendar-item-date="'+t+'"]').addClass(this.periodMap[t].theme)}.bind(this))},x=function(){if("day"===n.mode||"d"===n.mode)for(var t in this.periodMap)this.$.body.find('[data-calendar-item-date="'+t+'"]').find(".addon-footer").empty(),this.$.body.find('[data-calendar-item-date="'+t+'"]').removeClass(this.periodMap[t].theme)};this.init=function(){this.onStateChanged=n.onStateChanged,this.onClick=n.onClick,n.target||console.log(ax5.info.getError("ax5calendar","401","setConfig")),this.target=jQuery(n.target),n.displayDate=i.date(n.displayDate),this.target.html(s.call(this)),this.$={root:this.target.find('[data-calendar-els="root"]'),control:this.target.find('[data-calendar-els="control"]'),"control-display":this.target.find('[data-calendar-els="control-display"]'),body:this.target.find('[data-calendar-els="body"]')},n.control&&this.$.root.on(n.clickEventName,"[data-calendar-move]",function(t){p.call(this,t||window.event)}.bind(this)),n.selection&&this.setSelection(n.selection,!1),n.selectable&&this.setSelectable(n.selectable,!1),n.marker&&this.setMarker(n.marker,!1),setTimeout(function(){"day"===n.mode||"d"===n.mode?d.call(this,n.displayDate):"month"===n.mode||"m"===n.mode?c.call(this,n.displayDate):"year"!==n.mode&&"y"!==n.mode||u.call(this,n.displayDate)}.bind(this))},this.changeMode=function(t,e){return"undefined"!=typeof e&&(n.displayDate=e),t&&(n.mode=t),this.$.body.removeClass("fadein").addClass("fadeout"),setTimeout(function(){"day"==n.mode||"d"==n.mode?d.call(this,n.displayDate):"month"==n.mode||"m"==n.mode?c.call(this,n.displayDate):"year"!=n.mode&&"y"!=n.mode||u.call(this,n.displayDate),this.$.body.removeClass("fadeout").addClass("fadein")}.bind(this),n.animateTime),this},this.setSelection=function(){a.selectionMap={};var t={arr:function(t,e,o){return e={},i.isArray(t)?(a.selection=t=t.splice(0,o),t.forEach(function(t){i.isDate(t)&&(t=i.date(t,{"return":n.dateFormat})),e[t]=!0}),e):e}};return function(e,a){var l={};if(o=n.multipleSelect?i.isNumber(n.multipleSelect)?n.multipleSelect:2:1,n.selection=e){if(!i.isArray(e))return this;l=t.arr(e,{},o)}return this.selectionMap=jQuery.extend({},l),a!==!1&&m.call(this),l=null,this}}(),this.getSelection=function(){return this.selection},this.setSelectable=function(){a.selectableMap={};var t={arr:function(t,e){return e={},i.isArray(t)?(t.forEach(function(t){i.isDate(t)&&(t=i.date(t,{"return":n.dateFormat})),e[t]=!0}),e):e},obj:function(t,e){if(e={},i.isArray(t))return e;if(t.range)return e;for(var n in t)e[n]=t[n];return e},range:function(t,e){return e={},i.isArray(t)?e:t.range?(t.range.forEach(function(t){if(i.isDateFormat(t.from)&&i.isDateFormat(t.to))for(var a=i.date(t.from);a<=i.date(t.to);a.setDate(a.getDate()+1))e[i.date(a,{"return":n.dateFormat})]=!0;else for(var o=t.from;o<=t.to;o++)e[o]=!0}),e):e}};return function(e,a){var o,l={};if(n.selectable=e)if(i.isArray(e))l=t.arr(e);else{for(o in t)if(e[o]){l=t[o](e);break}0===Object.keys(l).length&&(l=t.obj(e))}return this.selectableMap=l,a!==!1&&this.changeMode(),this}}(),this.setMarker=function(){a.markerMap={};var t={obj:function(t,e){if(e={},i.isArray(t))return e;if(t.range)return e;for(var n in t)e[n]=t[n];return t=null,e},range:function(t,e){return e={},i.isArray(t)?e:t.range?(t.range.forEach(function(t){if(i.isDateFormat(t.from)&&i.isDateFormat(t.to))for(var a=i.date(t.from);a<=i.date(t.to);a.setDate(a.getDate()+1))e[i.date(a,{"return":n.dateFormat})]={theme:t.theme,label:t.label};else for(var o=t.from;o<=t.to;o++)e[o]={theme:t.theme,label:t.label}}),t=null,e):e}};return function(e,i){var a,o={};if(n.marker=e){for(a in t)if(e[a]){o=t[a](e);break}0===Object.keys(o).length&&(o=t.obj(e))}return this.markerMap=o,i!==!1&&f.call(this),this}}(),this.setPeriod=function(){a.periodMap={};var t={range:function(t,e){return e={},i.isArray(t)?e:t.range?(t.range.forEach(function(t){if(i.isDateFormat(t.from)&&i.isDateFormat(t.to))for(var a=new Date(i.date(t.from));a<=i.date(t.to);a.setDate(a.getDate()+1))a.getTime()==i.date(t.from).getTime()?e[i.date(a,{"return":n.dateFormat})]={theme:t.theme||n.defaultPeriodTheme,label:t.fromLabel}:a.getTime()==i.date(t.to).getTime()?e[i.date(a,{"return":n.dateFormat})]={theme:t.theme||n.defaultPeriodTheme,label:t.toLabel}:e[i.date(a,{"return":n.dateFormat})]={theme:t.theme||n.defaultPeriodTheme}}),t=null,e):e}};return function(e,i){var a={};return i!==!1&&x.call(this),(n.period=e)&&(a=t.range(e)),this.periodMap=a,i!==!1&&g.call(this),this}}(),this.main=function(){e.calendar_instance=e.calendar_instance||[],e.calendar_instance.push(this),arguments&&i.isObject(arguments[0])&&this.setConfig(arguments[0])}.apply(this,arguments)};return n}()),t=ax5.ui.calendar}(),function(){var t=ax5.ui.calendar,e=function(t){return'\n
\n {{#control}}\n
\n {{{left}}}\n
\n {{{right}}}\n
\n {{/control}}\n
\n
\n '},i=function(t){return'\n \n \n \n {{#weekNames}}\n \n {{/weekNames}}\n \n \n \n \n {{#list}} \n {{#isStartOfWeek}}\n {{^@first}}\n \n \n {{/@first}}\n {{/isStartOfWeek}}\n \n {{/list}}\n \n \n
\n {{label}}\n
\n \n \n {{thisDataLabel}}\n \n \n
\n '},n=function(t){return'\n \n \n \n \n \n \n \n \n {{#list}} \n {{#isStartOfRow}}\n {{^@first}}\n \n \n {{/@first}}\n {{/isStartOfRow}}\n \n {{/list}}\n \n \n
\n {{colHeadLabel}}\n
\n \n \n {{thisMonthLabel}}\n \n \n
\n '},a=function(t){return'\n \n \n \n \n \n \n \n \n {{#list}} \n {{#isStartOfRow}}\n {{^@first}}\n \n \n {{/@first}}\n {{/isStartOfRow}}\n \n {{/list}}\n \n \n
\n {{colHeadLabel}}\n
\n \n \n {{thisYearLabel}}\n \n \n
\n '};t.tmpl={frameTmpl:e,dayTmpl:i,monthTmpl:n,yearTmpl:a,get:function(e,i,n){return ax5.mustache.render(t.tmpl[e].call(this,n),i)}}}(),function(){var t,e=ax5.ui,i=ax5.util;e.addClass({className:"picker",version:"1.3.58"},function(){var e=function(){var e=this,n=void 0;this.instanceId=ax5.getGuid(),this.config={clickEventName:"click",theme:"default",title:"",lang:{ok:"ok",cancel:"cancel"},animateTime:100,calendar:{multipleSelect:!1,control:{left:ax5.def.picker.date_leftArrow||"←",yearTmpl:ax5.def.picker.date_yearTmpl||"%s",monthTmpl:ax5.def.picker.date_monthTmpl||"%s",right:ax5.def.picker.date_rightArrow||"→",yearFirst:!0}}},this.queue=[],this.activePicker=null,this.activePickerQueueIndex=-1,this.openTimer=null,this.closeTimer=null,n=this.config;var a=function(t,e){return t&&t.onStateChanged?t.onStateChanged.call(e,e):this.onStateChanged&&this.onStateChanged.call(e,e),!0},o=function(){var t={focus:function(t,e){this.open(t)},click:function(t,e){this.open(t)}},e={"@fn":function(t,e){var i=this.queue[t],a=e.length,o={inputLength:a||1};a>1&&(o.btns={ok:{label:n.lang.ok,theme:n.theme}}),this.queue[t]=jQuery.extend(!0,o,i),o=null,a=null},date:function(t,e){var i=this.queue[t],a=i.content?i.content.width||270:270,o=i.content?i.content.margin||5:5,l=e.length,s={contentWidth:a*l+(l-1)*o,content:{width:a,margin:o},inputLength:l||1};l>1&&!i.btns&&(s.btns={ok:{label:n.lang.ok,theme:n.theme}}),this.queue[t]=jQuery.extend(!0,s,i),a=null,o=null,s=null,l=null},"secure-num":function(t,e){var i=this.queue[t],n=e.length,a={inputLength:n||1};this.queue[t]=jQuery.extend(!0,a,i),a=null,n=null},keyboard:function(t,e){var i=this.queue[t],n=e.length,a={inputLength:n||1};this.queue[t]=jQuery.extend(!0,a,i),a=null,n=null},numpad:function(t,e){var i=this.queue[t],n=e.length,a={inputLength:n||1};this.queue[t]=jQuery.extend(!0,a,i),a=null,n=null}};return function(n){var a,o=this.queue[n];if(!o.content)return console.log(ax5.info.getError("ax5picker","501","bind")),this;if(a="INPUT"==o.$target.get(0).tagName.toUpperCase()?o.$target:o.$target.find("input[type]"),i.isFunction(o.content))e["@fn"].call(this,n,a);else for(var l in e)if(o.content.type==l){e[l].call(this,n,a);break}return a.unbind("focus.ax5picker").unbind("click.ax5picker").bind("focus.ax5picker",t.focus.bind(this,n)).bind("click.ax5picker",t.click.bind(this,n)),o.$target.find(".input-group-addon").unbind("click.ax5picker").bind("click.ax5picker",t.click.bind(this,n)),o.content.formatter&&ax5.ui.formatter&&a.ax5formatter(o.content.formatter),a=null,o=null,n=null,this}}(),l=function(t){if(!this.activePicker)return this;var e=function(e){var i,n=jQuery(window),a=jQuery(document.body),o={},l=12,s={},r={};o=e.$target.offset(),s={width:e.$target.outerWidth(),height:e.$target.outerHeight()},r={winWidth:Math.max(n.width(),a.width()),winHeight:Math.max(n.height(),a.height()),width:this.activePicker.outerWidth(),height:this.activePicker.outerHeight()},e.direction&&""!==e.direction&&"auto"!==e.direction?i=e.direction:(i="top",o.top-r.height-l<0?i="top":o.top+s.height+r.height+l>r.winHeight&&(i="bottom")),t&&this.activePicker.addClass("direction-"+i);var d=function(){var t={left:0,top:0};switch(i){case"top":t.left=o.left+s.width/2-r.width/2,t.top=o.top+s.height+l;break;case"bottom":t.left=o.left+s.width/2-r.width/2,t.top=o.top-r.height-l;break;case"left":t.left=o.left+s.width+l,t.top=o.top-r.height/2+s.height/2;break;case"right":t.left=o.left-r.width-l,t.top=o.top-r.height/2+s.height/2}return t}();(function(){"top"!=i&&"bottom"!=i||(d.left<0?(d.left=l,this.activePickerArrow.css({left:o.left+s.width/2-d.left})):d.left+r.width>r.winWidth&&(d.left=r.winWidth-r.width-l,this.activePickerArrow.css({left:o.left+s.width/2-d.left})))}).call(this),this.activePicker.css(d)},i=this.queue[this.activePickerQueueIndex];this.activePicker.css({top:-999}),t&&jQuery(document.body).append(this.activePicker),setTimeout(function(){e.call(this,i)}.bind(this))},s=function(t,e){if(!this.activePicker)return this;var n=this.queue[this.activePickerQueueIndex];return e=i.findParentNode(t.target,function(t){return!!t.getAttribute("data-picker-els")||(n.$target.get(0)==t||void 0)}),e?this:(this.close(),this)},r=function(t,e){if(t.srcElement&&(t.target=t.srcElement),e=i.findParentNode(t.target,function(t){if(t.getAttribute("data-picker-btn"))return!0})){var n=this.queue[this.activePickerQueueIndex],a=e.getAttribute("data-picker-btn");if(n.btns&&n.btns[a].onClick){var o={key:a,value:n.btns[a],self:this,item:n};n.btns[a].onClick.call(o,a)}else this.close()}},d=function(t){t.keyCode==ax5.info.eventKeys.ESC&&this.close()},c=function(t){return i.isString(t)||(t=jQuery(t).data("data-axpicker-id")),i.isString(t)?i.search(this.queue,function(){return this.id==t}):void console.log(ax5.info.getError("ax5picker","402","getQueIdx"))};this.init=function(){this.onStateChanged=n.onStateChanged},this.bind=function(t){var e={},a=void 0;return t=jQuery.extend(!0,e,n,t),t.target?(t.$target=jQuery(t.target),t.$target.get(0)?(t.id||(t.id=t.$target.data("data-axpicker-id")),t.id||(t.id="ax5-picker-"+ax5.getGuid(),t.$target.data("data-axpicker-id",t.id)),a=i.search(this.queue,function(){return this.id==t.id}),a===-1?(this.queue.push(t),o.call(this,this.queue.length-1)):(this.queue[a]=jQuery.extend(!0,{},this.queue[a],t),o.call(this,a)),e=null,a=null,this):(console.log(ax5.info.getError("ax5picker","401","bind")),this)):(console.log(ax5.info.getError("ax5picker","401","bind")),this)},this.setContentValue=function(){var t={date:function(t,e,i){var n,a,o,l=[];return"INPUT"!==t.$target.get(0).tagName.toUpperCase()&&t.$target.find("input[type]").each(function(){l.push(this.value)}),0==e?(l.length>1&&""!==l[1]?(n=ax5.util.dday(l[1],{today:l[0]}),n<0&&(o=i)):o=i,o&&(t.pickerCalendar[1].ax5uiInstance.setSelection([o],!1).changeMode("d",o),this.setContentValue(t.id,1,o)),i):1==e?(l.length>1&&(n=ax5.util.dday(l[1],{today:l[0]}),n<0&&(a=l[1])),a&&(t.pickerCalendar[0].ax5uiInstance.setSelection([a],!1).changeMode("d",a),this.setContentValue(t.id,0,a)),i):void 0}};return function(n,o,l){var s,r=i.isNumber(n)?n:c.call(this,n),d=this.queue[r];if(d){s="INPUT"==d.$target.get(0).tagName.toUpperCase()?d.$target:jQuery(d.$target.find("input[type]").get(o)),s.val(l),d.disableChangeTrigger||s.trigger("change"),d.inputLength>1&&t[d.content.type]&&(l=t[d.content.type].call(this,d,o,l));var u={self:e,state:"changeValue",item:d,inputIndex:o,value:l,values:[l]};"INPUT"!==d.$target.get(0).tagName.toUpperCase()&&(u.values=[],d.$target.find("input[type]").each(function(){u.values.push(this.value)})),a.call(this,d,u),1==d.inputLength&&this.close()}return d=null,n=null,o=null,l=null,this}}(),this.open=function(){var o={"@fn":function(t,e){var i=this.queue[t];return i.content.call(i,function(t){e(t)}),!0},date:function(t){for(var a=this.queue[t],o=[],l=0;l'),l');o.push('
'),a.pickerContent.html(o.join(""));var s=jQuery.extend({},n.calendar,{displayDate:new Date}),r="INPUT"==a.$target.get(0).tagName.toUpperCase()?a.$target:a.$target.find("input[type]");a.pickerCalendar=[],a.pickerContent.find("[data-calendar-target]").each(function(){var t=this.getAttribute("data-calendar-target"),i=r.get(t).value,n=ax5.util.date(i);s.displayDate=n,i&&(s.selection=[n]),s=jQuery.extend(!0,s,a.content.config||{}),s.target=this,s.onClick=function(){e.setContentValue(a.id,t,this.date)},a.pickerCalendar.push({itemId:a.id,inputIndex:t,ax5uiInstance:new ax5.ui.calendar(s)})})},"secure-num":function(t){for(var n=this.queue[t],o=[],l=0;l'),l');o.push('
'),n.pickerContent.html(o.join("")),n.pickerContent.find("[data-secure-num-target]").each(function(){var t=this.getAttribute("data-secure-num-target"),i=[],o=function(t){var e,i,n;for(n=t.length;n;n-=1)e=Math.floor(Math.random()*n),i=t[n-1],t[n-1]=t[e],t[e]=i;return t}([0,1,2,3,4,5,6,7,8,9]),l=[{label:"←",fn:"back"},{label:"C",fn:"clear"}];o.forEach(function(t){i.push('
'),i.push('"),i.push("
")}),l.forEach(function(t){i.push('
'),i.push('"),i.push("
")}),i.push('
'),$(this).html(i.join("")).on("click","[data-secure-num-value]",function(){var i=this.getAttribute("data-secure-num-value"),o="INPUT"==n.$target.get(0).tagName.toUpperCase()?n.$target:jQuery(n.$target.find("input[type]").get(t)),l=o.val();"back"==i?o.val(l.substring(0,l.length-1)):"clear"==i?o.val(""):o.val(l+i),a.call(this,n,{self:e,state:"changeValue",item:n,value:o.val()})})})},keyboard:function(t){for(var n=this.queue[t],o=[],l=0;l'),l');o.push('
'),n.pickerContent.html(o.join(""));var s=[[{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"}]],r=function(t){var e=[];return s.forEach(function(i){e.push('
'),i.forEach(function(i){var a,o,l,s,r;i.fn?(a=i.fn,o=i.label,l=n.content.config.specialBtnWrapStyle,s=n.content.config.specialBtnTheme,r=n.content.config.specialBtnStyle):(o=a=t?i.shiftValue:i.value,l=n.content.config.btnWrapStyle,s=n.content.config.btnTheme,r=n.content.config.btnStyle),e.push('
'),e.push('"),e.push("
")}),e.push("
")}),e.join("")};n.pickerContent.find("[data-keyboard-target]").each(function(){var t=this.getAttribute("data-keyboard-target"),i=$(this),o=!1,l=function(){o=!o,i.html(r(o))};i.html(r(o)).on("mousedown","[data-keyboard-value]",function(){var i=this.getAttribute("data-keyboard-value"),o="INPUT"==n.$target.get(0).tagName.toUpperCase()?n.$target:jQuery(n.$target.find("input[type]").get(t)),s=o.val();switch(i){case"back":o.val(s.substring(0,s.length-1));break;case"clear":o.val("");break;case"shift":return l(),!1;case"close":return e.close(),!1;default:o.val(s+i)}a.call(this,n,{self:e,state:"changeValue",item:n,value:o.val()})})})},numpad:function(t){for(var n=this.queue[t],o=[],l=0;l'),l');o.push('
'),n.pickerContent.html(o.join("")),n.pickerContent.find("[data-numpad-target]").each(function(){var t=this.getAttribute("data-numpad-target"),i=[],o=n.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"}];o.forEach(function(t){var e,a,o,l,s;t.fn?(e=t.fn,a=t.label,l=n.content.config.specialBtnTheme,o=n.content.config.specialBtnWrapStyle,s=n.content.config.specialBtnStyle):(a=e=t.value,l=e?n.content.config.btnTheme:"",o=n.content.config.btnWrapStyle,s=n.content.config.btnStyle),i.push('
'),i.push('"),i.push("
")}),i.push('
'),$(this).html(i.join("")).on("mousedown","[data-numpad-value]",function(){var i=this.getAttribute("data-numpad-value"),o="INPUT"==n.$target.get(0).tagName.toUpperCase()?n.$target:jQuery(n.$target.find("input[type]").get(t)),l=o.val(),s="";switch(i){case"back":s="changeValue",o.val(l.substring(0,l.length-1));break;case"clear":s="changeValue",o.val("");break;case"enter":return e.close(n,"enter"),!1;case"close":return e.close(),!1;default:s="changeValue",o.val(l+i)}a.call(this,n,{self:e,state:s,item:n,value:o.val()})})})}};return function(e,u){var h=i.isNumber(e)?e:c.call(this,e),p=this.queue[h];return this.openTimer&&clearTimeout(this.openTimer),this.activePicker?this.activePickerQueueIndex==h?this:u>2?this:(this.close(),this.openTimer=setTimeout(function(){this.open(h,(u||0)+1)}.bind(this),n.animateTime),this):(this.activePicker=jQuery(t.tmpl.get.call(this,"pickerTmpl",p)),this.activePickerArrow=this.activePicker.find(".ax-picker-arrow"),this.activePickerQueueIndex=h,p.pickerContent=this.activePicker.find('[data-picker-els="content"]'),i.isFunction(p.content)?(p.pickerContent.html("Loading.."),o["@fn"].call(this,h,function(t){p.pickerContent.html(t)})):p.content.type in o&&o[p.content.type].call(this,h),this.activePicker.find("[data-picker-btn]").on(n.clickEventName,function(t){r.call(this,t||window.event,h)}.bind(this)),l.call(this,"append"),jQuery(window).bind("resize.ax5picker",function(){l.call(this)}.bind(this)),jQuery(window).bind("keyup.ax5picker",function(t){t=t||window.event,d.call(this,t),i.stopEvent(t)}.bind(this)),jQuery(window).bind("click.ax5picker",function(t){t=t||window.event,s.call(this,t),i.stopEvent(t)}.bind(this)),a.call(this,p,{self:this,state:"open",item:p}),this)}}(),this.close=function(t,e){return this.closeTimer&&clearTimeout(this.closeTimer),this.activePicker?(t=this.queue[this.activePickerQueueIndex],this.activePicker.addClass("destroy"),jQuery(window).unbind("resize.ax5picker"),jQuery(window).unbind("click.ax5picker"),jQuery(window).unbind("keyup.ax5picker"),this.closeTimer=setTimeout(function(){this.activePicker&&this.activePicker.remove(),this.activePicker=null,this.activePickerQueueIndex=-1,a.call(this,t,{self:this,state:e||"close"})}.bind(this),n.animateTime),this):this},this.main=function(){arguments&&i.isObject(arguments[0])&&this.setConfig(arguments[0])}.apply(this,arguments)};return e}()),t=ax5.ui.picker}(),ax5.ui.picker_instance=new ax5.ui.picker,jQuery.fn.ax5picker=function(){return function(t){if(ax5.util.isString(arguments[0])){var e=arguments[0];switch(e){case"open":return ax5.ui.picker_instance.open(this);case"close":return ax5.ui.picker_instance.close(this);case"setValue":return ax5.ui.picker_instance.setContentValue(this,arguments[1],arguments[2]);default:return this}}else"undefined"==typeof t&&(t={}),jQuery.each(this,function(){var e={target:this};t=jQuery.extend(!0,t,e),ax5.ui.picker_instance.bind(t)});return this}}(),function(){var t=ax5.ui.picker,e=(ax5.util,function(){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'});t.tmpl={pickerTmpl:e,get:function(e,i,n){return ax5.mustache.render(t.tmpl[e].call(this,n),i)}}}(),function(){var t,e=ax5.ui,i=ax5.util;e.addClass({className:"formatter",version:"1.3.58"},function(){var e=(new Date,function(t,e){if("undefined"==typeof e&&(e=t.value.length),t.setSelectionRange)t.focus(),t.setSelectionRange(e,e);else if(t.createTextRange){var i=t.createTextRange();i.collapse(!0),i.moveEnd("character",e),i.moveStart("character",e),i.select()}else t.selectionStart&&(t.focus(),t.selectionStart=e,t.selectionEnd=e)}),n=function(){var n,a=this;this.instanceId=ax5.getGuid(),this.config={animateTime:250},this.queue=[],this.openTimer=null,this.closeTimer=null,n=this.config;var o={focus:function(t,e,i){t.$input.data("__originValue__")||t.$input.data("__originValue__",t.$input.val())},keydown:function(t,e,i){var n=!1;t.enterableKeyCodes&&(i.which&&t.enterableKeyCodes[i.which]||i.metaKey||i.ctrlKey||i.shiftKey||(n=!0)),n&&ax5.util.stopEvent(i)},keyup:function(i,n,a){var o,l,s,r,d,c=i.$input.get(0);"selectionStart"in c?o=c.selectionStart:document.selection&&(r=document.selection.createRange(),d=document.selection.createRange().text.length,r.moveStart("character",-c.value.length),o=r.text.length-d),l=c.value,s=i.pattern in t.formatter?t.formatter[i.pattern].getPatternValue.call(this,i,n,a,c.value):l,s!=l&&(i.$input.val(s).trigger("change"),e(c,o+s.length-l.length))},blur:function(e,i,n,a){var o,l,s=e.$input.get(0);e.$input.removeData("__originValue__"),o=s.value,l=e.pattern in t.formatter?t.formatter[e.pattern].getPatternValue.call(this,e,i,n,s.value,"blur"):o,a?e.$input.val(l):l!=o&&e.$input.val(l).trigger("change")}},l=function(e,i){if(!e.pattern&&("INPUT"==e.$target.get(0).tagName?e.pattern=e.$target.attr("data-ax5formatter"):e.pattern=e.$target.find('input[type="text"]').attr("data-ax5formatter"),!e.pattern))return console.log(ax5.info.getError("ax5formatter","501","bind")),console.log(e.target),this;var n=/[^\(^\))]+/gi,a=e.pattern.match(n);return e.pattern=a[0],e.patternArgument=a[1]||"",e.pattern in t.formatter&&(e.enterableKeyCodes=t.formatter[e.pattern].getEnterableKeyCodes.call(this,e,i)),e.$input.unbind("focus.ax5formatter").bind("focus.ax5formatter",o.focus.bind(this,this.queue[i],i)),e.$input.unbind("keydown.ax5formatter").bind("keydown.ax5formatter",o.keydown.bind(this,this.queue[i],i)),e.$input.unbind("keyup.ax5formatter").bind("keyup.ax5formatter",o.keyup.bind(this,this.queue[i],i)),e.$input.unbind("blur.ax5formatter").bind("blur.ax5formatter",o.blur.bind(this,this.queue[i],i)),o.blur.call(this,this.queue[i],i),this},s=function(t){return i.isString(t)||(t=jQuery(t).data("data-formatter")), -i.search(this.queue,function(){return this.id==t})};this.init=function(){},this.bind=function(t){var e,o={};if(jQuery.extend(!0,o,n),t&&jQuery.extend(!0,o,t),t=o,!t.target)return console.log(ax5.info.getError("ax5formatter","401","bind")),this;if(t.$target=jQuery(t.target),"INPUT"==t.$target.get(0).tagName)t.$input=t.$target;else if(t.$input=t.$target.find('input[type="text"]'),t.$input.length>1)return t.$input.each(function(){t.target=this,a.bind(t)}),this;return t.$input="INPUT"==t.$target.get(0).tagName?t.$target:t.$target.find('input[type="text"]'),t.id||(t.id=t.$input.data("ax5-formatter")),t.id||(t.id="ax5-formatter-"+ax5.getGuid(),t.$input.data("ax5-formatter",t.id)),e=i.search(this.queue,function(){return this.id==t.id}),e===-1?(this.queue.push(t),l.call(this,this.queue[this.queue.length-1],this.queue.length-1)):(this.queue[e]=t,l.call(this,this.queue[e],e)),this},this.formatting=function(t){var e=i.isNumber(t)?t:s.call(this,t);if(e===-1)for(var n=this.queue.length;n--;)o.blur.call(this,this.queue[n],n,null,!0);else o.blur.call(this,this.queue[e],e,null,!0);return this},this.unbind=function(){},this.main=function(){arguments&&i.isObject(arguments[0])&&this.setConfig(arguments[0])}.apply(this,arguments)};return n}()),t=ax5.ui.formatter}(),ax5.ui.formatter_instance=new ax5.ui.formatter,jQuery.fn.ax5formatter=function(){return function(t){if(ax5.util.isString(arguments[0])){var e=arguments[0];switch(e){case"formatting":return ax5.ui.formatter_instance.formatting(this);case"unbind":return ax5.ui.formatter_instance.unbind(this);default:return this}}else"undefined"==typeof t&&(t={}),jQuery.each(this,function(){var e={target:this};t=jQuery.extend({},t,e),ax5.ui.formatter_instance.bind(t)});return this}}(),function(){var t=ax5.ui.formatter,e=ax5.util,i={18:"KEY_ALT",8:"KEY_BACKSPACE",17:"KEY_CONTROL",46:"KEY_DELETE",40:"KEY_DOWN",35:"KEY_END",187:"KEY_EQUAL",27:"KEY_ESC",36:"KEY_HOME",45:"KEY_INSERT",37:"KEY_LEFT",189:"KEY_MINUS",34:"KEY_PAGEDOWN",33:"KEY_PAGEUP",13:"KEY_RETURN",39:"KEY_RIGHT",16:"KEY_SHIFT",9:"KEY_TAB",38:"KEY_UP",91:"KEY_WINDOW"},n={48:1,49:1,50:1,51:1,52:1,53:1,54:1,55:1,56:1,57:1,96:1,97:1,98:1,99:1,100:1,101:1,102:1,103:1,104:1,105:1},a={getEnterableKeyCodes:function(e){var i={188:","};return"int"==e.patternArgument||(i[190]="."),jQuery.extend(i,t.formatter.ctrlKeys,t.formatter.numKeys)},getPatternValue:function(t,i,n,a,o){a=a.replace(/[^0-9^\.^\-]/g,"");var l,s=new RegExp("([0-9])([0-9][0-9][0-9][,.])"),r=a.split(".");r[0]+=".";do r[0]=r[0].replace(s,"$1,$2");while(s.test(r[0]));return l=r.length>1?e.isNumber(t.maxRound)?r[0]+e.left(r[1],t.maxRound):r.join(""):r[0].split(".")[0]}},o={getEnterableKeyCodes:function(e){var i={190:"."};return jQuery.extend(i,t.formatter.ctrlKeys,t.formatter.numKeys)},getPatternValue:function(t,i,n,a,o){a=a.replace(/[^0-9^\.^\-]/g,"");var l,s=a.split(".");return l=s.length>1?e.isNumber(t.maxRound)?s[0]+e.left(s[1],t.maxRound):s.join(""):s[0].split(".")[0]}},l={getEnterableKeyCodes:function(e){var i={189:"-",191:"/"};return jQuery.extend(i,t.formatter.ctrlKeys,t.formatter.numKeys)},getPatternValue:function(t,i,n,a,o){if(a=a.replace(/\D/g,""),""==a)return a;var l=/^([0-9]{4})\-?([0-9]{1,2})?\-?([0-9]{1,2})?.*$/;"time"==t.patternArgument&&(l=/^([0-9]{4})\-?([0-9]{1,2})?\-?([0-9]{1,2})? ?([0-9]{1,2})?:?([0-9]{1,2})?:?([0-9]{1,2})?.*$/);var s=a.match(l),r="",d=function(t,i,n,a){var o={Y:function(t){return"undefined"==typeof t&&(t=TODAY.getFullYear()),""!=t&&"0000"!=t||(t=TODAY.getFullYear()),t.length<4?e.setDigit(t,4):t},M:function(t){return"undefined"==typeof t&&(t=TODAY.getMonth()+1),t>12?12:0==t?"01":e.setDigit(t,2)},D:function(t){"undefined"==typeof t&&(t=TODAY.getDate()+1);var i=e.daysOfMonth(a[1],a[2]-1);return t>i?i:0==t?"01":e.setDigit(t,2)},h:function(t){return t||(t=0),t>23?23:e.setDigit(t,2)},m:function(t){return t||(t=0),t>59?59:e.setDigit(t,2)},s:function(t){return t||(t=0),t>59?59:e.setDigit(t,2)}};return n?o[i](t):t};return r=a.replace(l,function(e,i){var n=[d(arguments[1],"Y",o)];return(arguments[2]||o)&&n.push("-"+d(arguments[2],"M",o)),(arguments[3]||o)&&n.push("-"+d(arguments[3],"D",o,arguments)),"time"==t.patternArgument&&((arguments[4]||o)&&n.push(" "+d(arguments[4],"h",o)),(arguments[5]||o)&&n.push(":"+d(arguments[5],"m",o)),(arguments[6]||o)&&n.push(":"+d(arguments[6],"s",o))),n.join("")}),"blur"!=o||s?s||(r=r.length>4?e.left(r,4):r):r=function(){var e=[d(r,"Y",o)];return e.push("-"+d(0,"M",o)),e.push("-"+d(0,"D",o,arguments)),"time"==t.patternArgument&&(e.push(" "+d(0,"h",o)),e.push(":"+d(0,"m",o)),e.push(":"+d(0,"s",o))),e.join("")}(),r}},s={getEnterableKeyCodes:function(e){var i={186:":"};return jQuery.extend(i,t.formatter.ctrlKeys,t.formatter.numKeys)},getPatternValue:function(t,i,n,a,o){a=a.replace(/\D/g,"");var l=/^([0-9]{1,2})?:?([0-9]{1,2})?:?([0-9]{1,2})?.*$/,s=a.match(l),r=a.replace(l,function(t,e){var i=[arguments[1]];return arguments[2]&&i.push(":"+arguments[2]),arguments[3]&&i.push(":"+arguments[3]),i.join("")});return s||(r=r.length>2?e.left(r,2):r),r}},r={getEnterableKeyCodes:function(e){var i={189:"-"};return jQuery.extend(i,t.formatter.ctrlKeys,t.formatter.numKeys)},getPatternValue:function(t,e,i,n,a){n=n.replace(/\D/g,"");var o=/^([0-9]{3})\-?([0-9]{1,2})?\-?([0-9]{1,5})?.*$/,l=n.replace(o,function(t,e){var i=[arguments[1]];return arguments[2]&&i.push(arguments[2]),arguments[3]&&i.push(arguments[3]),i.join("-")});return l}},d={getEnterableKeyCodes:function(e){var i={189:"-",188:","};return jQuery.extend(i,t.formatter.ctrlKeys,t.formatter.numKeys)},getPatternValue:function(t,e,i,n,a){n=n.replace(/\D/g,"");var o=/^([0-9]{3})\-?([0-9]{1,4})?\-?([0-9]{1,4})?\-?([0-9]{1,4})?\-?([0-9]{1,4})?/;"02"==n.substr(0,2)&&(o=/^([0-9]{2})\-?([0-9]{1,4})?\-?([0-9]{1,4})?\-?([0-9]{1,4})?\-?([0-9]{1,4})?/);var l=n.replace(o,function(t,e){var i=[arguments[1]];return arguments[2]&&i.push(arguments[2]),arguments[3]&&i.push(arguments[3]),arguments[4]&&i.push(arguments[4]),arguments[5]&&i.push(arguments[5]),i.join("-")});return l}},c={getEnterableKeyCodes:function(e){var i={189:"-"};return jQuery.extend(i,t.formatter.ctrlKeys,t.formatter.numKeys)},getPatternValue:function(t,e,i,n,a){n=n.replace(/\D/g,"").substring(0,16);var o=/^([0-9]{4})\-?([0-9]{4})?\-?([0-9]{4})?\-?([0-9]{4})?/,l=n.replace(o,function(t,e){var i=[arguments[1]];return arguments[2]&&i.push(arguments[2]),arguments[3]&&i.push(arguments[3]),arguments[4]&&i.push(arguments[4]),i.join("-")});return l}},u={getEnterableKeyCodes:function(t){return t.getEnterableKeyCodes?t.getEnterableKeyCodes.call(t,{$input:t.$input}):null},getPatternValue:function(t,e,i,n,a){if(t.getPatternValue)return t.getPatternValue.call(t,{event:i,$input:t.$input,value:n})}};t.formatter={ctrlKeys:i,numKeys:n,money:a,number:o,date:l,time:s,bizno:r,phone:d,credit:c,custom:u}}(),function(){var t,e=ax5.ui,i=ax5.util;e.addClass({className:"menu",version:"1.3.58"},function(){var n=function(){var n,a=this;this.instanceId=ax5.getGuid(),this.config={theme:"default",iconWidth:22,acceleratorWidth:100,menuBodyPadding:5,offset:{left:0,top:0},position:"fixed",animateTime:250,items:[],itemClickAndClose:!0,columnKeys:{label:"label",items:"items"}},this.openTimer=null,this.closeTimer=null,this.queue=[],this.menuBar={},this.state=void 0,n=this.config;var o=function(t){t?(jQuery(document).unbind("click.ax5menu-"+this.menuId).bind("click.ax5menu-"+this.menuId,d.bind(this)),jQuery(window).unbind("keydown.ax5menu-"+this.menuId).bind("keydown.ax5menu-"+this.menuId,function(t){t.which==ax5.info.eventKeys.ESC&&a.close()}),jQuery(window).unbind("resize.ax5menu-"+this.menuId).bind("resize.ax5menu-"+this.menuId,function(t){a.close()})):(jQuery(document).unbind("click.ax5menu-"+this.menuId),jQuery(window).unbind("keydown.ax5menu-"+this.menuId),jQuery(window).unbind("resize.ax5menu-"+this.menuId))},l=function(t,e){return t&&t.onStateChanged?t.onStateChanged.call(e,e):this.onStateChanged&&this.onStateChanged.call(e,e),a.state=e.state,t=null,e=null,!0},s=function(t){return this.onLoad&&this.onLoad.call(t,t),t=null,!0},r=function u(e,i,o,r){var d,h,p=e;return p.theme=e.theme||n.theme,p.cfg={icons:jQuery.extend({},n.icons),iconWidth:e.iconWidth||n.iconWidth,acceleratorWidth:e.acceleratorWidth||n.acceleratorWidth},i.forEach(function(t){t.html||t.divide?(t["@isMenu"]=!1,t.html&&(t["@html"]=t.html.call({item:t,config:n,opt:e}))):t["@isMenu"]=!0}),p[n.columnKeys.items]=i,p["@depth"]=o,p["@path"]=r||"root",p["@hasChild"]=function(){return this[n.columnKeys.items]&&this[n.columnKeys.items].length>0},d=jQuery(t.tmpl.get.call(this,"tmpl",p,n.columnKeys)),jQuery(document.body).append(d),h=this.queue.splice(o),h.forEach(function(t){t.$target.remove()}),this.queue.push({$target:d,data:jQuery.extend({},p)}),d.find("[data-menu-item-index]").bind("mouseover",function(){var t,i,o,l,s,r,d=this.getAttribute("data-menu-item-depth"),c=this.getAttribute("data-menu-item-index"),h=this.getAttribute("data-menu-item-path");null!=d&&"undefined"!=typeof d&&(s=a.queue[d].data[n.columnKeys.items][c][n.columnKeys.items],r=a.queue[d].$target,r.find("[data-menu-item-index]").removeClass("hover"),jQuery(this).addClass("hover"),r.attr("data-selected-menu-item-index")!=c&&(r.attr("data-selected-menu-item-index",c),s&&s.length>0?(t=jQuery(this),i=t.offset(),o="fixed"==n.position?jQuery(document).scrollTop():0,l={"@parent":{left:i.left,top:i.top,width:t.outerWidth(),height:t.outerHeight()},left:i.left+t.outerWidth()-n.menuBodyPadding,top:i.top-n.menuBodyPadding-1-o},l=jQuery.extend(!0,e,l),u.call(a,l,s,Number(d)+1,h)):a.queue.splice(Number(d)+1).forEach(function(t){t.$target.remove()}))),d=null,c=null,h=null,t=null,i=null,o=null,l=null,s=null,r=null}),d.find("[data-menu-item-index]").bind("mouseout",function(){var t,e=this.getAttribute("data-menu-item-depth"),i=this.getAttribute("data-menu-item-index");this.getAttribute("data-menu-item-path");t=a.queue[e].data[n.columnKeys.items][i][n.columnKeys.items],t&&t.length>0||jQuery(this).removeClass("hover")}),0==o&&(p.direction&&d.addClass("direction-"+p.direction),l.call(this,null,{self:this,items:i,parent:function(t){if(!t)return!1;var e=null;try{e=Function("","return this.config.items["+t.substring(5).replace(/\./g,"].items[")+"];").call(a)}catch(i){}return e}(p["@path"]),state:"popup"})),c.call(this,d,p),s.call(this,{self:this,items:i,element:d.get(0)}),p=null,d=null,h=null,e=null,i=null,o=null,r=null,this},d=function(t,e,o){if(e=i.findParentNode(t.target,function(t){if(t.getAttribute("data-menu-item-index"))return!0})){if(o=function(t){if(!t)return!1;var e;try{e=Function("","return this.config.items["+t.substring(5).replace(/\./g,"]."+n.columnKeys.items+"[")+"];").call(a)}catch(i){console.log(ax5.info.getError("ax5menu","501","menuItemClick"))}try{return e}finally{e=null}}(e.getAttribute("data-menu-item-path")),!o)return this;o.check&&(function(t){var e={checkbox:function(t){this.checked=!t},radio:function(e){var i=this.name;t.forEach(function(t){t.check&&"radio"===t.check.type&&t.check.name==i&&(t.check.checked=!1)}),this.checked=!e}};e[this.type]&&e[this.type].call(this,this.checked),e=null}.call(o.check,n.items),n.itemClickAndClose||a.queue.forEach(function(t){t.$target.find("[data-menu-item-index]").each(function(){var e=t.data[n.columnKeys.items][this.getAttribute("data-menu-item-index")];e.check&&jQuery(this).find(".item-checkbox-wrap").attr("data-item-checked",e.check.checked)})})),a.onClick&&a.onClick.call(o,o),o[n.columnKeys.items]&&0!=o[n.columnKeys.items].length||!n.itemClickAndClose||a.close()}else a.close();return e=null,o=null,this},c=function(t,e){var i=jQuery(window),a=jQuery(document),o="fixed"==n.position?i.height():a.height(),l=i.width(),s=t.outerHeight(),r=t.outerWidth(),d=e.left,c=e.top,u=n.position||"fixed";return d+r>l&&(d=e["@parent"]?e["@parent"].left-r+n.menuBodyPadding:l-r),c+s>o&&(c=o-s),t.css({left:d,top:c,position:u}),t=null,e=null,i=null,a=null,o=null,l=null,s=null,r=null,d=null,c=null,u=null,this};this.init=function(){a.menuId=ax5.getGuid(),this.onStateChanged=n.onStateChanged,this.onClick=n.onClick,this.onLoad=n.onLoad,l.call(this,null,{self:this,state:"init"})},this.popup=function(){var t={event:function(t,e){t={left:t.clientX,top:"fixed"==n.position?t.clientY:t.pageY,width:n.width,theme:n.theme},n.offset&&(n.offset.left&&(t.left+=n.offset.left),n.offset.top&&(t.top+=n.offset.top)),e=jQuery.extend(!0,t,e);try{return e}finally{t=null}},object:function(t,e){t={left:t.left,top:t.top,width:t.width||n.width,theme:t.theme||n.theme},n.offset&&(n.offset.left&&(t.left+=n.offset.left),n.offset.top&&(t.top+=n.offset.top)),e=jQuery.extend(!0,t,e);try{return e}finally{t=null}}},e=function(t){t&&(n.theme=t)};return function(i,a){if(!i)return this;a=t["undefined"==typeof i.clientX?"object":"event"].call(this,i,a),e(a.theme);var l=[].concat(n.items);if(a.filter){var s=function d(t){var e=[];return t.forEach(function(t){t.items&&t.items.length>0&&(t.items=d(t.items)),a.filter.call(t)&&e.push(t)}),e};l=s(l)}return l.length&&(r.call(this,a,l,0),o.call(this,!0)),i=null,this}}(),this.attach=function(){var e={object:function(t,e){t={left:t.left,top:t.top,width:t.width||n.width,theme:t.theme||n.theme,direction:t.direction||n.direction},e=jQuery.extend(!0,e,t);try{return e}finally{t=null,e=null}}},l=function(t,i,l){var s=jQuery(t),d=s.offset(),c=s.outerHeight(),u=Number(t.getAttribute("data-menu-item-index")),h="fixed"==n.position?jQuery(document).scrollTop():0;if(n.items&&n.items[u][n.columnKeys.items]&&n.items[u][n.columnKeys.items].length){if(a.menuBar.openedIndex==u)return"click"==l&&a.close(),!1;a.menuBar.target.find("[data-menu-item-index]").removeClass("hover"),a.menuBar.opened=!0,a.menuBar.openedIndex=u,s.attr("data-menu-item-opened","true"),s.addClass("hover"),n.offset&&(n.offset.left&&(d.left+=n.offset.left),n.offset.top&&(d.top+=n.offset.top)),i=e.object.call(this,{left:d.left,top:d.top+c-h},i),r.call(a,i,n.items[u][n.columnKeys.items],0,"root."+t.getAttribute("data-menu-item-index")),o.call(a,!0)}t=null,i=null,s=null,d=null,c=null,u=null,h=null},s=function(t,e,i){var o=jQuery(t),l=(o.offset(),o.outerHeight(),Number(t.getAttribute("data-menu-item-index")));"fixed"==n.position?jQuery(document).scrollTop():0;!n.items||n.items[l][n.columnKeys.items]&&0!=n.items[l][n.columnKeys.items].length||a.onClick&&a.onClick.call(n.items[l],n.items[l])};return function(e,o){var r,d={},c=n.items;return"undefined"==typeof o&&(o={}),d.theme=o.theme||n.theme,d.cfg={icons:jQuery.extend({},n.icons),iconWidth:o.iconWidth||n.iconWidth,acceleratorWidth:o.acceleratorWidth||n.acceleratorWidth},c.forEach(function(t){t.html||t.divide?(t["@isMenu"]=!1,t.html&&(t["@html"]=t.html.call({item:t,config:n,opt:o}))):t["@isMenu"]=!0}),d[n.columnKeys.items]=c,r=jQuery(t.tmpl.get.call(this,"tmplMenubar",d,n.columnKeys)),a.menuBar={target:jQuery(e),opened:!1},a.menuBar.target.html(r),a.menuBar.target.bind("click",function(t){if(!t)return this;var e=i.findParentNode(t.target,function(t){if(t.getAttribute("data-menu-item-index"))return!0});e&&(s(e,o,"click"),l(e,o,"click")),e=null}),a.menuBar.target.bind("mouseover",function(t){if(!a.menuBar.opened)return!1;var e=i.findParentNode(t.target,function(t){if(t.getAttribute("data-menu-item-index"))return!0});e&&l(e,o,"mouseover"),e=null}),e=null,o=null,d=null,c=null,r=null,this}}(),this.close=function(){return a.menuBar&&a.menuBar.target&&(a.menuBar.target.find("[data-menu-item-index]").removeClass("hover"),a.menuBar.opened=!1,a.menuBar.openedIndex=null),o.call(this,!1),this.queue.forEach(function(t){t.$target.remove()}),this.queue=[],l.call(this,null,{self:this,state:"close"}),this},this.getCheckValue=function(){var t={},e=function(n){for(var a=n.length;a--;)n[a].check&&n[a].check.checked&&(t[n[a].check.name]?(i.isString(t[n[a].check.name])&&(t[n[a].check.name]=[t[n[a].check.name]]),t[n[a].check.name].push(n[a].check.value)):t[n[a].check.name]=n[a].check.value),n[a].items&&n[a].items.length>0&&e(n[a].items)};e(n.items);try{return t}finally{t=null,e=null}},this.main=function(){e.menu_instance=e.menu_instance||[],e.menu_instance.push(this),arguments&&i.isObject(arguments[0])&&this.setConfig(arguments[0])}.apply(this,arguments)};return n}()),t=ax5.ui.menu}(),function(){var t=ax5.ui.menu,e=function(t){return'\n
\n
\n {{#'+t.items+'}}\n {{^@isMenu}}\n {{#divide}}\n
\n {{/divide}}\n {{#html}}\n
{{{@html}}}
\n {{/html}}\n {{/@isMenu}}\n {{#@isMenu}}\n
\n \n {{#check}}\n \n {{/check}}\n {{^check}}\n \n {{/check}}\n \n {{#icon}}\n {{{.}}}\n {{/icon}}\n {{{'+t.label+'}}}\n {{#accelerator}}\n {{.}}\n {{/accelerator}}\n {{#@hasChild}}\n {{{cfg.icons.arrow}}}\n {{/@hasChild}}\n
\n {{/@isMenu}}\n\n {{/'+t.items+'}}\n
\n
\n
\n '},i=function(t){return'\n
\n
\n {{#'+t.items+'}}\n {{^@isMenu}}\n {{#divide}}\n
\n {{/divide}}\n {{#html}}\n
{{{@html}}}
\n {{/html}}\n {{/@isMenu}}\n {{#@isMenu}}\n
\n {{#icon}}\n {{{.}}}\n {{/icon}}\n {{{'+t.label+"}}}\n
\n {{/@isMenu}}\n {{/"+t.items+"}}\n
\n
\n "};t.tmpl={tmpl:e,tmplMenubar:i,get:function(e,i,n){return ax5.mustache.render(t.tmpl[e].call(this,n),i)}}}(),function(){var t,e=ax5.ui,i=ax5.util;e.addClass({className:"select",version:"1.3.58"},function(){var e=function(){var e,n=this;this.instanceId=ax5.getGuid(),this.config={theme:"default",animateTime:100,lang:{noSelected:"",noOptions:"no options",loading:"now loading..",multipleLabel:'"{{label}}"외 {{length}}건'},columnKeys:{optionValue:"value",optionText:"text",optionSelected:"selected"}},this.queue=[],this.activeSelectOptionGroup=null,this.activeSelectQueueIndex=-1,this.openTimer=null,this.closeTimer=null,this.waitOptionsCallback=null,this.keyUpTimer=null,this.xvar={},e=this.config;var a=jQuery(window),o={18:"KEY_ALT",8:"KEY_BACKSPACE",17:"KEY_CONTROL",46:"KEY_DELETE",40:"KEY_DOWN",35:"KEY_END",187:"KEY_EQUAL",27:"KEY_ESC",36:"KEY_HOME",45:"KEY_INSERT",37:"KEY_LEFT",189:"KEY_MINUS",34:"KEY_PAGEDOWN",33:"KEY_PAGEUP",13:"KEY_RETURN",39:"KEY_RIGHT",16:"KEY_SHIFT",9:"KEY_TAB",38:"KEY_UP",91:"KEY_WINDOW"},l=function(t,e){return t&&t.onStateChanged?t.onStateChanged.call(e,e):this.onStateChanged&&this.onStateChanged.call(e,e),"changeValue"==e.state&&(t&&t.onChange?t.onChange.call(e,e):this.onChange&&this.onChange.call(e,e)),t=null,e=null,!0},s=function(){for(var t,e=this.queue.length;e--;)this.queue[e].$display&&(t=Math.max(this.queue[e].$select.outerWidth(),i.number(this.queue[e].minWidth)),this.queue[e].$display.css({"min-width":t}),this.queue[e].reset&&this.queue[e].$display.find(".addon-icon-reset").css({"line-height":this.queue[e].$display.height()+"px"}));return e=null,t=null,this},r=function(t){if(!this.activeSelectOptionGroup)return this;var e,i=this.queue[this.activeSelectQueueIndex],n={},o=0,l={},s={};t&&jQuery(document.body).append(this.activeSelectOptionGroup),n=i.$target.offset(),l={width:i.$target.outerWidth(),height:i.$target.outerHeight()},s={winWidth:Math.max(a.width(),jQuery(document.body).width()),winHeight:Math.max(a.height(),jQuery(document.body).height()),width:this.activeSelectOptionGroup.outerWidth(),height:this.activeSelectOptionGroup.outerHeight()},i.direction&&""!==i.direction&&"auto"!==i.direction?e=i.direction:(e="top",n.top-s.height-o<0?e="top":n.top+l.height+s.height+o>s.winHeight&&(e="bottom")),t&&this.activeSelectOptionGroup.addClass("direction-"+e),this.activeSelectOptionGroup.css(function(){if("top"==e){if(n.top+l.height+s.height+o>s.winHeight){var t=n.top+l.height/2-s.height/2;return t+s.height+o>s.winHeight&&(t=0),t<0&&(t=0),{left:n.left,top:t,width:l.width}}return{left:n.left,top:n.top+l.height+1,width:l.width}}if("bottom"==e)return{left:n.left,top:n.top-s.height-1,width:l.width}}.call(this))},d=function(t,e){if(!this.activeSelectOptionGroup)return this;var n=this.queue[this.activeSelectQueueIndex],a="display";return(e=i.findParentNode(t.target,function(t){return t.getAttribute("data-option-value")?(a="optionItem",!0):n.$target.get(0)==t?(a="display",!0):void 0}))?("optionItem"===a&&(this.val(n.id,{index:{gindex:e.getAttribute("data-option-group-index"),index:e.getAttribute("data-option-index")}},void 0,"internal"),n.$select.trigger("change"),n.$display.focus(),n.multiple||this.close()),this):(this.close(),this)},c=function(t){if(t.keyCode==ax5.info.eventKeys.ESC)this.close();else if(t.which==ax5.info.eventKeys.RETURN)if(this.queue[this.activeSelectQueueIndex].optionFocusIndex>-1){var e=this.activeSelectOptionGroup.find('[data-option-focus-index="'+this.queue[this.activeSelectQueueIndex].optionFocusIndex+'"]');this.val(this.queue[this.activeSelectQueueIndex].id,{index:{gindex:e.attr("data-option-group-index"),index:e.attr("data-option-index")}},void 0,"internal"),this.queue[this.activeSelectQueueIndex].$select.trigger("change"),this.queue[this.activeSelectQueueIndex].multiple||this.close()}else this.close()},u=function(t){var e=this.queue[t],n=[];return i.isArray(e.selected)&&e.selected.length>0?e.selected.forEach(function(t){t.selected&&n.push(t[e.columnKeys.optionText])}):!e.multiple&&e.options&&e.options[0]?e.options[0].optgroup?n[0]=e.options[0].options[0][e.columnKeys.optionText]:n[0]=e.options[0][e.columnKeys.optionText]:n[0]=e.lang.noSelected,function(){if(e.multiple&&n.length>1){var t={label:n[0],length:n.length-1};return ax5.mustache.render(e.lang.multipleLabel,t)}return n[0]}()},h=function(t){this.queue[t].$displayLabel.html(u.call(this,t))},p=function(t,e){var i,n=[],a=-1,o=this.queue[t].indexedOptions.length-1;if(e){for(;o-a++;){if(i=this.queue[t].indexedOptions[a],(""+i.value).toLowerCase()==e.toLowerCase()){n=[{"@findex":i["@findex"],optionsSort:0}];break}var l=(""+i.value).toLowerCase().search(e.toLowerCase());if(l>-1&&(n.push({"@findex":i["@findex"],optionsSort:l}),n.length>2))break;l=null}n.sort(function(t,e){return t.optionsSort-e.optionsSort})}n&&n.length>0&&f.call(this,t,void 0,n[0]["@findex"]);try{return n}finally{n=null,a=null,o=null,i=null}},f=function(t,e,i){var n,a,o,l;if(this.activeSelectOptionGroup&&this.queue[t].options&&this.queue[t].options.length>0){"undefined"!=typeof i?n=i:(a=this.queue[t].optionFocusIndex==-1?this.queue[t].optionSelectedIndex||-1:this.queue[t].optionFocusIndex,a==-1?n=e>0?0:this.queue[t].optionItemLength-1:(n=a+e,n<0?n=0:n>this.queue[t].optionItemLength-1&&(n=this.queue[t].optionItemLength-1))),this.queue[t].optionFocusIndex=n,this.activeSelectOptionGroup.find("[data-option-focus-index]").removeClass("hover"),o=this.activeSelectOptionGroup.find('[data-option-focus-index="'+n+'"]').addClass("hover"),l=this.activeSelectOptionGroup.find('[data-els="content"]');var s=o.outerHeight(),r=l.innerHeight(),d=l.scrollTop(),c=o.position().top+l.scrollTop();r+dc&&l.scrollTop(c)}},m=function(){var e=i.debounce(function(t,e){p.call(n,e,t),n.queue[e].$displayInput.val("")},300),a={click:function(t,e){var a=i.findParentNode(e.target,function(t){if(t.getAttribute("data-selected-clear"))return!0});a?this.val(t,{clear:!0}):n.activeSelectQueueIndex==t?this.queue[t].optionFocusIndex==-1&&n.close():(n.open(t),i.stopEvent(e))},keyUp:function(t,i){i.which==ax5.info.eventKeys.SPACE?a.click.call(this,t,i):o[i.which]||e(this.queue[t].$displayInput.val(),t)},keyDown:function(t,e){e.which==ax5.info.eventKeys.DOWN?(f.call(this,t,1),i.stopEvent(e)):e.which==ax5.info.eventKeys.UP&&(f.call(this,t,-1),i.stopEvent(e))},blur:function(t,e){},selectChange:function(t,e){this.val(t,this.queue[t].$select.val(),!0)}};return function(e){var i=this.queue[e],n={};return i.selected=[],i.$display?(i.$displayLabel.html(u.call(this,e)),i.options=g.call(this,e,i.options),s.call(this)):(n.instanceId=this.instanceId,n.id=i.id,n.name=i.name,n.theme=i.theme,n.tabIndex=i.tabIndex,n.multiple=i.multiple,n.reset=i.reset,n.label=u.call(this,e),n.formSize=function(){return i.size?"input-"+i.size:""}(),i.$display=t.tmpl.get.call(this,"tmpl",n),i.$displayLabel=i.$display.find('[data-ax5select-display="label"]'),i.$target.find("select").get(0)?(i.$select=i.$target.find("select"),i.$select.attr("tabindex","-1").attr("class","form-control "+n.formSize),n.name&&i.$select.attr("name","name"),n.multiple&&i.$select.attr("multiple","multiple")):(i.$select=t.tmpl.get.call(this,"selectTmpl",n),i.$target.append(i.$select)),i.$target.append(i.$display),i.$displayInput=i.$display.find('[data-ax5select-display="input"]'),i.options=g.call(this,e,i.options),s.call(this),i.$displayInput.unbind("blur.ax5select").bind("blur.ax5select",a.blur.bind(this,e)).unbind("keyup.ax5select").bind("keyup.ax5select",a.keyUp.bind(this,e)).unbind("keydown.ax5select").bind("keydown.ax5select",a.keyDown.bind(this,e))),i.$display.unbind("click.ax5select").bind("click.ax5select",a.click.bind(this,e)).unbind("keyup.ax5select").bind("keyup.ax5select",a.keyUp.bind(this,e)),i.$select.unbind("change.ax5select").bind("change.ax5select",a.selectChange.bind(this,e)),n=null,i=null,e=null,this}}(),g=function(){var t=function(t,e){e?this.queue[t].multiple?this.queue[t].selected.push(jQuery.extend({},e)):this.queue[t].selected[0]=jQuery.extend({},e):this.queue[t].selected=[]};return function(e,a){var o,l,s,r=this.queue[e],d=0;return t.call(this,e,!1),a?(r.options=a,r.indexedOptions=[],o=[],r.options.forEach(function(i,a){i.optgroup?(i["@gindex"]=a,i.options.forEach(function(i,a){i["@index"]=a,i["@findex"]=d,o.push('"),i[r.columnKeys.optionSelected]&&t.call(n,e,i),r.indexedOptions.push({"@findex":d,value:i[r.columnKeys.optionValue],text:i[r.columnKeys.optionText]}),d++})):(i["@index"]=a,i["@findex"]=d,o.push('"),i[r.columnKeys.optionSelected]&&t.call(n,e,i),r.indexedOptions.push({"@findex":d,value:i[r.columnKeys.optionValue],text:i[r.columnKeys.optionText]}),d++)}),r.optionItemLength=d,r.$select.html(o.join(""))):(l=i.toArray(r.$select.get(0).options),s=[],l.forEach(function(i,a){var o={};o[r.columnKeys.optionValue]=i.value,o[r.columnKeys.optionText]=i.text,o[r.columnKeys.optionSelected]=i.selected,o["@index"]=a,o["@findex"]=a,i.selected&&t.call(n,e,o),s.push(o),o=null}),r.options=s,r.indexedOptions=s),!r.multiple&&0==r.selected.length&&r.options&&r.options[0]&&(r.options[0].optgroup?(r.options[0].options[0][r.columnKeys.optionSelected]=!0,r.selected.push(jQuery.extend({},r.options[0].options[0]))):(r.options[0][r.columnKeys.optionSelected]=!0,r.selected.push(jQuery.extend({},r.options[0])))),o=null,l=null,s=null,r.options}}(),x=function(t){return i.isString(t)||(t=jQuery(t).data("data-ax5select-id")),i.isString(t)?i.search(this.queue,function(){return this.id==t}):void console.log(ax5.info.getError("ax5select","402","getQueIdx"))};this.init=function(){this.onStateChanged=e.onStateChanged,this.onChange=e.onChange,jQuery(window).bind("resize.ax5select-display-"+this.instanceId,function(){s.call(this)}.bind(this))},this.bind=function(t){var n,a={};return t=jQuery.extend(!0,a,e,t),t.target?(t.$target=jQuery(t.target),t.id||(t.id=t.$target.data("data-ax5select-id")),t.id||(t.id="ax5select-"+ax5.getGuid(),t.$target.data("data-ax5select-id",t.id)),t.name=t.$target.attr("data-ax5select"),t.options&&(t.options=JSON.parse(JSON.stringify(t.options))),function(e){i.isObject(e)&&!e.error&&(t=jQuery.extend(!0,t,e))}(i.parseJson(t.$target.attr("data-ax5select-config"),!0)),n=i.search(this.queue,function(){return this.id==t.id}),n===-1?(this.queue.push(t),m.call(this,this.queue.length-1)):(this.queue[n].selected=[],this.queue[n].options=t.options,this.queue[n]=jQuery.extend(!0,{},this.queue[n],t),m.call(this,n)),a=null,n=null,this):(console.log(ax5.info.getError("ax5select","401","bind")),this)},this.open=function(){var n=function(e){e.onExpand.call({self:this,item:e},function(e){if(this.waitOptionsCallback){var n={},a=this.queue[this.activeSelectQueueIndex];!function(t,e){var n={};e.options.forEach(function(e,i){e["@index"]=i,n[e[t.columnKeys.optionValue]]=e}),i.isArray(t.selected)&&t.selected.forEach(function(i){n[i[t.columnKeys.optionValue]]&&(e.options[n[i[t.columnKeys.optionValue]]["@index"]][t.columnKeys.optionSelected]=!0)})}(a,e),a.$displayLabel.html(u.call(this,this.activeSelectQueueIndex)),a.options=g.call(this,this.activeSelectQueueIndex,e.options),s.call(this),n.id=a.id,n.theme=a.theme,n.size="ax5select-option-group-"+a.size,n.multiple=a.multiple,n.lang=a.lang,n.options=a.options,this.activeSelectOptionGroup.find('[data-els="content"]').html(t.tmpl.get.call(this,"optionsTmpl",n,a.columnKeys))}}.bind(this))};return function(a,o){this.waitOptionsCallback=null;var s,u,h=i.isNumber(a)?a:x.call(this,a),p=this.queue[h],f={};return p.$display.attr("disabled")?this:(this.openTimer&&clearTimeout(this.openTimer),this.activeSelectOptionGroup?this.activeSelectQueueIndex==h?this:o>2?this:(this.close(),this.openTimer=setTimeout(function(){this.open(h,(o||0)+1)}.bind(this),e.animateTime),this):(p.optionFocusIndex=-1,p.selected&&p.selected.length>0&&(p.optionSelectedIndex=p.selected[0]["@findex"]),f.id=p.id,f.theme=p.theme,f.size="ax5select-option-group-"+p.size,f.multiple=p.multiple,f.lang=p.lang,p.$display.attr("data-select-option-group-opened","true"),p.onExpand&&(f.waitOptions=!0),f.options=p.options,this.activeSelectOptionGroup=t.tmpl.get.call(this,"optionGroupTmpl",f),this.activeSelectOptionGroup.find('[data-els="content"]').html(t.tmpl.get.call(this,"optionsTmpl",f,p.columnKeys)),this.activeSelectQueueIndex=h, -r.call(this,"append"),jQuery(window).bind("resize.ax5select-"+this.instanceId,function(){r.call(this)}.bind(this)),p.selected&&p.selected.length>0&&(u=this.activeSelectOptionGroup.find('[data-option-index="'+p.selected[0]["@index"]+'"]'),u.get(0)&&(s=u.position().top-this.activeSelectOptionGroup.height()/3,this.activeSelectOptionGroup.find('[data-els="content"]').stop().animate({scrollTop:s},p.animateTime,"swing",function(){}))),p.$displayInput.val(""),setTimeout(function(){p.$displayInput.trigger("focus"),jQuery(window).bind("keyup.ax5select-"+this.instanceId,function(t){t=t||window.event,c.call(this,t),i.stopEvent(t)}.bind(this)),jQuery(window).bind("click.ax5select-"+this.instanceId,function(t){t=t||window.event,d.call(this,t),i.stopEvent(t)}.bind(this))}.bind(this),300),l.call(this,p,{self:this,state:"open",item:p}),p.onExpand&&(this.waitOptionsCallback=!0,n.call(this,p)),f=null,s=null,u=null,this))}}(),this.update=function(t){return this.bind(t),this},this.val=function(){var t=function(t,e,i){return"undefined"==typeof i?!t.multiple||!e:i},e=function(t){this.queue[t].options.forEach(function(t){t.optgroup?t.options.forEach(function(t){t.selected=!1}):t.selected=!1})},a={index:function(e,a,o){var l=this.queue[e];i.isString(a.index.gindex)?(l.options[a.index.gindex].options[a.index.index][l.columnKeys.optionSelected]=t(l,l.options[a.index.gindex].options[a.index.index][l.columnKeys.optionSelected],o),n.activeSelectOptionGroup.find('[data-option-group-index="'+a.index.gindex+'"][data-option-index="'+a.index.index+'"]').attr("data-option-selected",l.options[a.index.gindex].options[a.index.index][l.columnKeys.optionSelected].toString())):(l.options[a.index.index][l.columnKeys.optionSelected]=t(l,l.options[a.index.index][l.columnKeys.optionSelected],o),n.activeSelectOptionGroup.find('[data-option-index="'+a.index.index+'"]').attr("data-option-selected",l.options[a.index.index][l.columnKeys.optionSelected].toString())),g.call(this,e,l.options),h.call(this,e),r.call(this)},arr:function(t,e,o){e.forEach(function(e){if(i.isString(e)||i.isNumber(e))a.value.call(n,t,e,o);else for(var l in a)if(e[l]){a[l].call(n,t,e,o);break}})},value:function(e,n,a){var o=this.queue[e],l=i.search(o.options,function(){return this[o.columnKeys.optionValue]==n});return l>-1?(o.options[l][o.columnKeys.optionSelected]=t(o,o.options[l][o.columnKeys.optionSelected],a),g.call(this,e,o.options),void h.call(this,e)):void console.log(ax5.info.getError("ax5select","501","val"))},text:function(e,n,a){var o=this.queue[e],l=i.search(o.options,function(){return this[o.columnKeys.optionText]==n});return l>-1?(o.options[l][o.columnKeys.optionSelected]=t(o,o.options[l][o.columnKeys.optionSelected],a),g.call(this,e,o.options),void h.call(this,e)):void console.log(ax5.info.getError("ax5select","501","val"))},clear:function(t){e.call(this,t),g.call(this,t,this.queue[t].options),h.call(this,t),this.activeSelectOptionGroup&&this.activeSelectOptionGroup.find("[data-option-index]").attr("data-option-selected","false")}};return function(t,n,o,s){var r=i.isNumber(t)?t:x.call(this,t);if(r===-1)return void console.log(ax5.info.getError("ax5select","402","val"));if("undefined"==typeof n||this.queue[r].multiple||e.call(this,r),"undefined"==typeof n)return this.queue[r].selected;if(i.isArray(n))a.arr.call(this,r,n,o);else if(i.isString(n)||i.isNumber(n))a.value.call(this,r,n,o);else if(null===n)a.clear.call(this,r);else for(var d in a)if(n[d]){a[d].call(this,r,n,o);break}return"undefined"!=typeof n&&l.call(this,this.queue[r],{self:this,item:this.queue[r],state:s?"changeValue":"setValue",value:this.queue[r].selected,internal:s}),t=null,this}}(),this.close=function(t){return this.closeTimer&&clearTimeout(this.closeTimer),this.activeSelectOptionGroup?(t=this.queue[this.activeSelectQueueIndex],t.optionFocusIndex=-1,t.$displayInput.val("").trigger("blur"),t.$display.removeAttr("data-select-option-group-opened").trigger("focus"),this.activeSelectOptionGroup.addClass("destroy"),jQuery(window).unbind("resize.ax5select-"+this.instanceId).unbind("click.ax5select-"+this.instanceId).unbind("keyup.ax5select-"+this.instanceId),this.closeTimer=setTimeout(function(){this.activeSelectOptionGroup&&this.activeSelectOptionGroup.remove(),this.activeSelectOptionGroup=null,this.activeSelectQueueIndex=-1;var e={self:this,item:t,value:t.selected,state:"close"};l.call(this,t,e),t.onClose&&t.onClose.call(e)}.bind(this),e.animateTime),this.waitOptionsCallback=null,this):this},this.enable=function(t){var e=x.call(this,t);return this.queue[e].$display.removeAttr("disabled"),this.queue[e].$select.removeAttr("disabled"),l.call(this,this.queue[e],{self:this,state:"enable"}),this},this.disable=function(t){var e=x.call(this,t);return this.queue[e].$display.attr("disabled","disabled"),this.queue[e].$select.attr("disabled","disabled"),l.call(this,this.queue[e],{self:this,state:"disable"}),this},this.main=function(){arguments&&i.isObject(arguments[0])?this.setConfig(arguments[0]):this.init()}.apply(this,arguments)};return e}()),t=ax5.ui.select}(),ax5.ui.select_instance=new ax5.ui.select,jQuery.fn.ax5select=function(){return function(t){if(ax5.util.isString(arguments[0])){var e=arguments[0];switch(e){case"open":return ax5.ui.select_instance.open(this);case"close":return ax5.ui.select_instance.close(this);case"setValue":return ax5.ui.select_instance.val(this,arguments[1],arguments[2]);case"getValue":return ax5.ui.select_instance.val(this);case"enable":return ax5.ui.select_instance.enable(this);case"disable":return ax5.ui.select_instance.disable(this);default:return this}}else"undefined"==typeof t&&(t={}),jQuery.each(this,function(){var e={target:this};t=jQuery.extend({},t,e),ax5.ui.select_instance.bind(t)});return this}}(),function(){var t=ax5.ui.select,e=function(t){return'\n
\n
\n
\n
\n
\n
\n'},i=function(t){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=function(t){return'\n\n'},a=function(t){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 {{'+t.optionText+'}}\n
\n
\n {{/options}}\n
\n {{/optgroup}}\n {{^optgroup}}\n
\n
\n {{#multiple}}\n \n \n \n {{/multiple}}\n {{'+t.optionText+'}}\n
\n
\n {{/optgroup}}\n {{/options}}\n {{^options}}\n
\n
\n \n {{{lang.noOptions}}}\n \n
\n
\n {{/options}}\n{{/waitOptions}}\n'};t.tmpl={optionGroupTmpl:e,tmpl:i,selectTmpl:n,optionsTmpl:a,get:function(e,i,n){return jQuery(ax5.mustache.render(t.tmpl[e].call(this,n),i))}}}(),function(){var t,e=ax5.ui,i=ax5.util;e.addClass({className:"grid",version:"1.3.58"},function(){var n=function(){var n,a=this;this.instanceId=ax5.getGuid(),this.config={theme:"default",animateTime:250,frozenColumnIndex:0,frozenRowIndex:0,showLineNumber:!1,showRowSelector:!1,multipleSelect:!0,height:0,columnMinWidth:100,lineNumberColumnWidth:30,rowSelectorColumnWidth:26,sortable:void 0,remoteSort:!1,header:{align:!1,columnHeight:26,columnPadding:3,columnBorderWidth:1},body:{align:!1,columnHeight:26,columnPadding:3,columnBorderWidth:1,grouping:!1},rightSum:!1,footSum:!1,page:{height:25,display:!0,navigationItemCount:5},scroller:{size:15,barMinSize:15,trackPadding:4},columnKeys:{selected:"__selected__",modified:"__modified__",deleted:"__deleted__",disableSelection:"__disable_selection__"}},this.xvar={bodyTrHeight:0,scrollContentWidth:0,scrollContentHeight:0},this.columns=[],this.colGroup=[],this.footSumColumns=[],this.bodyGrouping={},this.list=[],this.page={},this.selectedDataIndexs=[],this.deletedList=[],this.sortInfo={},this.focusedColumn={},this.selectedColumn={},this.isInlineEditing=!1,this.inlineEditing={},this.headerTable={},this.leftHeaderData={},this.headerData={},this.rightHeaderData={},this.bodyRowTable={},this.leftBodyRowData={},this.bodyRowData={},this.rightBodyRowData={},this.bodyRowMap={},this.bodyGroupingTable={},this.leftBodyGroupingData={},this.bodyGroupingData={},this.rightBodyGroupingData={},this.footSumTable={},this.leftFootSumData={},this.footSumData={},this.needToPaintSum=!0,n=this.config;var o=function(){var e={instanceId:this.id};return this.$target.html(t.tmpl.get("main",e)),this.$={container:{hidden:this.$target.find('[data-ax5grid-container="hidden"]'),root:this.$target.find('[data-ax5grid-container="root"]'),header:this.$target.find('[data-ax5grid-container="header"]'),body:this.$target.find('[data-ax5grid-container="body"]'),page:this.$target.find('[data-ax5grid-container="page"]'),scroller:this.$target.find('[data-ax5grid-container="scroller"]')},panel:{"aside-header":this.$target.find('[data-ax5grid-panel="aside-header"]'),"left-header":this.$target.find('[data-ax5grid-panel="left-header"]'),header:this.$target.find('[data-ax5grid-panel="header"]'),"header-scroll":this.$target.find('[data-ax5grid-panel-scroll="header"]'),"right-header":this.$target.find('[data-ax5grid-panel="right-header"]'),"top-aside-body":this.$target.find('[data-ax5grid-panel="top-aside-body"]'),"top-left-body":this.$target.find('[data-ax5grid-panel="top-left-body"]'),"top-body":this.$target.find('[data-ax5grid-panel="top-body"]'),"top-body-scroll":this.$target.find('[data-ax5grid-panel-scroll="top-body"]'),"top-right-body":this.$target.find('[data-ax5grid-panel="top-right-body"]'),"aside-body":this.$target.find('[data-ax5grid-panel="aside-body"]'),"aside-body-scroll":this.$target.find('[data-ax5grid-panel-scroll="aside-body"]'),"left-body":this.$target.find('[data-ax5grid-panel="left-body"]'),"left-body-scroll":this.$target.find('[data-ax5grid-panel-scroll="left-body"]'),body:this.$target.find('[data-ax5grid-panel="body"]'),"body-scroll":this.$target.find('[data-ax5grid-panel-scroll="body"]'),"right-body":this.$target.find('[data-ax5grid-panel="right-body"]'),"right-body-scroll":this.$target.find('[data-ax5grid-panel-scroll="right-body"]'),"bottom-aside-body":this.$target.find('[data-ax5grid-panel="bottom-aside-body"]'),"bottom-left-body":this.$target.find('[data-ax5grid-panel="bottom-left-body"]'),"bottom-body":this.$target.find('[data-ax5grid-panel="bottom-body"]'),"bottom-body-scroll":this.$target.find('[data-ax5grid-panel-scroll="bottom-body"]'),"bottom-right-body":this.$target.find('[data-ax5grid-panel="bottom-right-body"]')},livePanelKeys:[],scroller:{vertical:this.$target.find('[data-ax5grid-scroller="vertical"]'),"vertical-bar":this.$target.find('[data-ax5grid-scroller="vertical-bar"]'),horizontal:this.$target.find('[data-ax5grid-scroller="horizontal"]'),"horizontal-bar":this.$target.find('[data-ax5grid-scroller="horizontal-bar"]'),corner:this.$target.find('[data-ax5grid-scroller="corner"]')},page:{navigation:this.$target.find('[data-ax5grid-page="navigation"]'),status:this.$target.find('[data-ax5grid-page="status"]')},form:{clipboard:this.$target.find('[data-ax5grid-form="clipboard"]')},resizer:{vertical:this.$target.find('[data-ax5grid-resizer="vertical"]'),horizontal:this.$target.find('[data-ax5grid-resizer="horizontal"]')}},this.$.container.root.css({height:this.config.height}),this},l=function(e){this.columns=i.deepCopy(e),this.headerTable=t.util.makeHeaderTable.call(this,this.columns),this.xvar.frozenColumnIndex=n.frozenColumnIndex>this.columns.length?this.columns.length:n.frozenColumnIndex,this.bodyRowTable=t.util.makeBodyRowTable.call(this,this.columns),this.bodyRowMap=t.util.makeBodyRowMap.call(this,this.bodyRowTable),this.xvar.bodyTrHeight=this.bodyRowTable.rows.length*this.config.body.columnHeight;for(var a={},o=0,l=this.headerTable.rows.length;o0)for(t=(o-l)/s.length,e=0,a=s.length;ei?this.config.scroller.size:0}.call(this),i>0&&(e=o-p-f-h-i0?(a.width=e,a.height=s,a.bottom=i+f):o=!0;break;case"horizontal":i>0?(a.width=l,a.height=i,a.right=e,a.bottom=f):o=!0;break;case"corner":e>0&&i>0?(a.width=e,a.height=i,a.bottom=f):o=!0}return o?(t.hide(),this):void t.show().css(a)};this.$.container.header.css({height:p}),this.$.container.body.css({height:m}),g.call(this,this.$.panel["aside-header"],"","aside","header"),g.call(this,this.$.panel["left-header"],"","left","header"),g.call(this,this.$.panel.header,"","","header"),g.call(this,this.$.panel["right-header"],"","right","header"),g.call(this,this.$.panel["top-aside-body"],"top","aside","body"),g.call(this,this.$.panel["top-left-body"],"top","left","body"),g.call(this,this.$.panel["top-body"],"top","","body"),g.call(this,this.$.panel["top-right-body"],"top","right","body"),g.call(this,this.$.panel["aside-body"],"","aside","body"),g.call(this,this.$.panel["left-body"],"","left","body"),g.call(this,this.$.panel.body,"","","body"),g.call(this,this.$.panel["right-body"],"","right","body"),g.call(this,this.$.panel["bottom-aside-body"],"bottom","aside","body"),g.call(this,this.$.panel["bottom-left-body"],"bottom","left","body"),g.call(this,this.$.panel["bottom-body"],"bottom","","body"),g.call(this,this.$.panel["bottom-right-body"],"bottom","right","body"),x.call(this,this.$.scroller.vertical,e,i,"vertical"),x.call(this,this.$.scroller.horizontal,e,i,"horizontal"),x.call(this,this.$.scroller.corner,e,i,"corner"),g.call(this,this.$.container.page,"","","page")},h=function(e){if(t.header.repaint.call(this),i.isFunction(this.config.remoteSort)){var n={sortInfo:[]};for(var a in e)n.sortInfo.push({key:a,orderBy:e[a].orderBy,seq:e[a].seq});n.sortInfo.sort(function(t,e){return t.seq>e.seq}),this.config.remoteSort.call(n,n)}else this.config.body.grouping?this.list=t.data.initData.call(this,t.data.sort.call(this,e,t.data.clearGroupingData.call(this,this.list))):this.list=t.data.sort.call(this,e,t.data.clearGroupingData.call(this,this.list)),t.body.repaint.call(this,!0),t.scroller.resize.call(this)};this.init=function(e){if(n=jQuery.extend(!0,{},n,e),!n.target)return console.log(ax5.info.getError("ax5grid","401","init")),this;this.onStateChanged=n.onStateChanged,this.onClick=n.onClick,this.onLoad=n.onLoad,this.onDataChanged=n.body.onDataChanged,this.$target=jQuery(n.target),function(t){i.isObject(t)&&!t.error&&(n=jQuery.extend(!0,n,t))}.call(this,i.parseJson(this.$target.attr("data-ax5grid-config"),!0));var s=this.config=n;this.config.height||(this.config.height=this.$target.height()),this.id||(this.id=this.$target.data("data-ax5grid-id")),this.id||(this.id="ax5grid-"+this.instanceId,this.$target.data("data-ax5grid-id",s.id)),o.call(this),l.call(this,s.columns),r.call(this),s.footSum&&d.call(this,s.footSum),s.body.grouping&&c.call(this,s.body.grouping),u.call(this,!0),t.header.init.call(this),t.header.repaint.call(this),t.body.init.call(this),t.body.repaint.call(this),t.scroller.init.call(this),t.scroller.resize.call(this),jQuery(window).bind("resize.ax5grid-"+this.id,function(){u.call(this),t.scroller.resize.call(this)}.bind(this)),jQuery(document.body).on("click.ax5grid-"+this.id,function(e){var n=!1,o=i.findParentNode(e.target,function(t){return!!(n=t.getAttribute("data-ax5grid-inline-edit-picker"))||"root"===t.getAttribute("data-ax5grid-container")});o&&o.getAttribute("data-ax5grid-instance")===this.id?a.focused=!0:(a.focused=!1,t.body.blur.call(this))}.bind(this));var h={33:"KEY_PAGEUP",34:"KEY_PAGEDOWN",35:"KEY_END",36:"KEY_HOME",37:"KEY_LEFT",38:"KEY_UP",39:"KEY_RIGHT",40:"KEY_DOWN"};return jQuery(window).on("keydown.ax5grid-"+this.instanceId,function(e){a.focused&&(a.isInlineEditing?e.which==ax5.info.eventKeys.ESC?a.keyDown("ESC",e.originalEvent):e.which==ax5.info.eventKeys.RETURN?a.keyDown("RETURN",e.originalEvent):e.which==ax5.info.eventKeys.TAB?(a.keyDown("TAB",e.originalEvent),i.stopEvent(e)):e.which==ax5.info.eventKeys.UP?a.keyDown("RETURN",{shiftKey:!0}):e.which==ax5.info.eventKeys.DOWN&&a.keyDown("RETURN",{}):e.metaKey||e.ctrlKey?67==e.which&&a.copySelect():h[e.which]?(a.keyDown(h[e.which],e.originalEvent),i.stopEvent(e)):e.which==ax5.info.eventKeys.ESC?a.focused&&t.body.blur.call(a):e.which==ax5.info.eventKeys.RETURN?a.keyDown("RETURN",e.originalEvent):e.which==ax5.info.eventKeys.TAB?i.stopEvent(e):e.which!=ax5.info.eventKeys.SPACE&&Object.keys(a.focusedColumn).length&&a.keyDown("INLINE_EDIT",e.originalEvent))}),setTimeout(function(){this.onLoad&&this.onLoad.call({self:this})}.bind(this)),this},this.align=function(){return u.call(this),t.scroller.resize.call(this),this},this.keyDown=function(){var e={KEY_UP:function(){t.body.moveFocus.call(this,"UP")},KEY_DOWN:function(){t.body.moveFocus.call(this,"DOWN")},KEY_LEFT:function(){t.body.moveFocus.call(this,"LEFT")},KEY_RIGHT:function(){t.body.moveFocus.call(this,"RIGHT")},KEY_HOME:function(){t.body.moveFocus.call(this,"HOME")},KEY_END:function(){t.body.moveFocus.call(this,"END")},INLINE_EDIT:function(e){t.body.inlineEdit.active.call(this,this.focusedColumn,e),/[0-9a-zA-Z]/.test(e.key)||i.stopEvent(e)},ESC:function(e){t.body.inlineEdit.keydown.call(this,"ESC")},RETURN:function(e){var i=0;for(var n in this.inlineEditing)i++,t.body.inlineEdit.keydown.call(this,"RETURN",n),1==i&&t.body.moveFocus.call(this,e.shiftKey?"UP":"DOWN")&&t.body.inlineEdit.keydown.call(this,"RETURN");0==i&&t.body.inlineEdit.keydown.call(this,"RETURN")},TAB:function(e){var i=0;for(var n in this.inlineEditing)i++,t.body.inlineEdit.keydown.call(this,"RETURN",n,{moveFocus:!0}),1==i&&t.body.moveFocus.call(this,e.shiftKey?"LEFT":"RIGHT")&&t.body.inlineEdit.keydown.call(this,"RETURN",void 0,{moveFocus:!0})}};return function(t,i){return t in e&&e[t].call(this,i),this}}(),this.copySelect=function(){var t,e,i,n,a=this.$.form.clipboard,o=[],l="",s=0;for(var r in this.selectedColumn){var d=this.selectedColumn[r];if(d){"undefined"==typeof n&&(n=d.dindex,e=d.rowIndex,i=d.rowIndex),n==d.dindex&&e==d.rowIndex||s++,o[s]||(o[s]=[]);var c=this.bodyRowMap[d.rowIndex+"_"+d.colIndex];c?this.list[d.dindex].__isGrouping?o[s].push(this.list[d.dindex][d.colIndex]):o[s].push(this.list[d.dindex][c.key]):o[s].push(""),n=d.dindex,e=d.rowIndex}}o.forEach(function(t){l+=t.join("\t")+"\n"}),a.get(0).innerText=l,a.select();try{t=document.execCommand("copy")}catch(u){t=!1}return t},this.setData=function(e){return t.data.set.call(this,e),u.call(this),t.body.repaint.call(this),t.scroller.resize.call(this),t.page.navigationUpdate.call(this),t.body.scrollTo.call(this,{top:0}),this},this.getList=function(e){return t.data.getList.call(this,e)},this.setHeight=function(e){return"100%"==e&&(e=this.$target.offsetParent().innerHeight()),this.$target.css({height:e}),this.$.container.root.css({height:e}),u.call(this),t.body.repaint.call(this,"reset"),t.scroller.resize.call(this),this},this.addRow=function(e,i,n){return t.data.add.call(this,e,i,n),u.call(this),t.body.repaint.call(this,"reset"),t.body.moveFocus.call(this,this.config.body.grouping?"START":"END"),t.scroller.resize.call(this),this},this.removeRow=function(e){return t.data.remove.call(this,e),u.call(this),t.body.repaint.call(this,"reset"),t.body.moveFocus.call(this,this.config.body.grouping?"START":"END"),t.scroller.resize.call(this),this},this.updateRow=function(e,i){return t.data.update.call(this,e,i),t.body.repaintRow.call(this,i),this},this.deleteRow=function(e){return t.data.deleteRow.call(this,e),u.call(this),t.body.repaint.call(this,"reset"),t.scroller.resize.call(this),this},this.setValue=function(e,i,n){if(t.data.setValue.call(this,e,i,n)){var a=function(e,i,n,a,o){for(var l=0,s=i.length;ln?t.body.repaintCell.call(this,"top-"+e,n,l,r,o):t.body.repaintCell.call(this,e+"-scroll",n,l,r,o))};a.call(this,"left-body",this.leftBodyRowData.rows,e,i,n),a.call(this,"body",this.bodyRowData.rows,e,i,n)}return this},this.addColumn=function(){var t={first:function(t){this.config.columns=[].concat(t).concat(this.config.columns)},last:function(t){this.config.columns=this.config.columns.concat([].concat(t))}};return function(e,n){if("undefined"==typeof e)throw"_column must not be null";if("undefined"==typeof n&&(n="last"),n in t)t[n].call(this,e);else{if(!i.isNumber(n))throw"invalid argument _cindex";this.config.columns.splice(n,[].concat(e))}return s.call(this),this}}(),this.removeColumn=function(){var t={first:function(t){this.config.columns.splice(t,1)},last:function(){this.config.columns.splice(this.config.columns.length-1,1)}};return function(e){if("undefined"==typeof e&&(e="last"),e in t)t[e].call(this,e);else{if(!i.isNumber(e))throw"invalid argument _cindex";this.config.columns.splice(e,1)}return s.call(this),this}}(),this.updateColumn=function(t,e){if(!i.isNumber(e))throw"invalid argument _cindex";return this.config.columns.splice(e,1,t),s.call(this),this},this.setColumnWidth=function(e,i){return this.colGroup[this.xvar.columnResizerIndex]._width=e,this.needToPaintSum=!0,t.header.repaint.call(this),t.body.repaint.call(this,!0),t.scroller.resize.call(this),u.call(this),this},this.getColumnSortInfo=function(){var t={sortInfo:[]};for(var e in this.sortInfo)t.sortInfo.push({key:e,orderBy:this.sortInfo[e].orderBy,seq:this.sortInfo[e].seq});return t.sortInfo.sort(function(t,e){return t.seq>e.seq}),t.sortInfo},this.setColumnSort=function(e){return"undefined"!=typeof e&&(this.sortInfo=e,t.header.applySortStatus.call(this,e)),h.call(this,e||this.sortInfo),this},this.select=function(e,n){if(i.isNumber(e)){var a=e;this.config.multipleSelect?n&&n.selectedClear&&this.clearSelect():this.clearSelect(),t.data.select.call(this,a,n&&n.selected),t.body.updateRowState.call(this,["selected"],a)}return this},this.clearSelect=function(){return t.body.updateRowState.call(this,["selectedClear"]),t.data.clearSelect.call(this),this},this.selectAll=function(e){return t.data.selectAll.call(this,e&&e.selected,e),t.body.updateRowStateAll.call(this,["selected"]),this},this.exportExcel=function(e){var i=[];return i.push(''),i.push(t.header.getExcelString.call(this)),i.push(t.body.getExcelString.call(this)),i.push("
"),"undefined"==typeof e?i.join(""):(t.excel["export"].call(this,[i.join("")],e),this)},this.focus=function(e){var i=this;if(t.body.moveFocus.call(this,e)){var n=void 0;for(var a in this.focusedColumn){n=jQuery.extend({},this.focusedColumn[a],!0);break}n&&this.select(n.dindex,{selectedClear:!0})}else"undefined"==typeof this.selectedDataIndexs[0]?this.select(0):!function(){var n=i.selectedDataIndexs[0],a={UP:function(){n>0&&(this.select(n-1,{selectedClear:!0}),t.body.moveFocus.call(this,n-1))},DOWN:function(){ne&&r.push("top"),l.xvar.frozenColumnIndex>n&&r.push("left"),r.push("body"),"top"!==r[0]&&r.push("scroll"),d=r.join("-"),l.selectedColumn[e+"_"+n+"_"+a]={panelName:d,dindex:e,rowIndex:a,colIndex:n,colspan:t.colspan},r=null,d=null}e=null,n=null,a=null;for(var c in l.selectedColumn){var u=l.selectedColumn[c];u&&l.$.panel[u.panelName].find('[data-ax5grid-tr-data-index="'+u.dindex+'"]').find('[data-ax5grid-column-rowindex="'+u.rowIndex+'"][data-ax5grid-column-colindex="'+u.colIndex+'"]').attr("data-ax5grid-column-selected","true")}}},n={on:function(t){var a=this;this.inlineEditing[t.dindex+"_"+t.colIndex+"_"+t.rowIndex]||(i.init.call(a,t),this.$.container.body.on("mousemove.ax5grid-"+this.instanceId,'[data-ax5grid-column-attr="default"]',function(t){this.getAttribute("data-ax5grid-column-rowIndex")&&(i.update.call(a,{panelName:this.getAttribute("data-ax5grid-panel-name"),dindex:Number(this.getAttribute("data-ax5grid-data-index")),rowIndex:Number(this.getAttribute("data-ax5grid-column-rowIndex")),colIndex:Number(this.getAttribute("data-ax5grid-column-colIndex")),colspan:Number(this.getAttribute("colspan"))}),e.stopEvent(t))}).on("mouseup.ax5grid-"+this.instanceId,function(){n.off.call(a)}).on("mouseleave.ax5grid-"+this.instanceId,function(){n.off.call(a)}),jQuery(document.body).attr("unselectable","on").css("user-select","none").on("selectstart",!1))},off:function(){this.$.container.body.off("mousemove.ax5grid-"+this.instanceId).off("mouseup.ax5grid-"+this.instanceId).off("mouseleave.ax5grid-"+this.instanceId),jQuery(document.body).removeAttr("unselectable").css("user-select","auto").off("selectstart")}},a=function(t,e,i){var n=this,a=this.config,o={selected:function(t){for(var e=this.$.livePanelKeys.length;e--;)this.$.panel[this.$.livePanelKeys[e]].find('[data-ax5grid-tr-data-index="'+t+'"]').attr("data-ax5grid-selected",this.list[t][a.columnKeys.selected])},selectedClear:function(){for(var t=this.selectedDataIndexs.length;t--;)for(var e=this.selectedDataIndexs[t],i=this.$.livePanelKeys.length;i--;)this.$.panel[this.$.livePanelKeys[i]].find('[data-ax5grid-tr-data-index="'+e+'"]').attr("data-ax5grid-selected",!1),this.list[e][a.columnKeys.selected]=!1},cellChecked:function(t,e){var i=(e.key,e.rowIndex),n=e.colIndex,a=function(){var e=[];return this.xvar.frozenRowIndex>t&&e.push("top"),this.xvar.frozenColumnIndex>n&&e.push("left"),e.push("body"),"top"!==e[0]&&e.push("scroll"),e.join("-")}.call(this);this.$.panel[a].find('[data-ax5grid-tr-data-index="'+t+'"]').find('[data-ax5grid-column-rowIndex="'+i+'"][data-ax5grid-column-colIndex="'+n+'"]').find('[data-ax5grid-editor="checkbox"]').attr("data-ax5grid-checked",""+e.checked)}};t.forEach(function(t){if(!o[t])throw"invaild state name";o[t].call(n,e,i)})},o=function(e,i){var n=this,a=(this.config,{selected:function(e){t.body.repaint.call(this,!0)}});e.forEach(function(t){if(!a[t])throw"invaild state name";a[t].call(n,i)})},l=function(){var i=this;this.$.container.body.on("click","[data-ax5grid-column-attr]",function(e){var n,o,l,s,r,d,c,u={"default":function(e){var n=i.bodyRowMap[e.rowIndex+"_"+e.colIndex],o={self:i,page:i.page,list:i.list,item:i.list[e.dindex],dindex:e.dindex,rowIndex:e.rowIndex,colIndex:e.colIndex,column:n,value:i.list[e.dindex][n.key]};if(n.editor&&"checkbox"==n.editor.type){var l,s,r=t.data.getValue.call(i,e.dindex,n.key);s=n.editor.config&&n.editor.config.trueValue?(l=!(r==n.editor.config.trueValue))?n.editor.config.trueValue:n.editor.config.falseValue:l=0==r||"false"==r||r<"1"?"true":"false",t.data.setValue.call(i,e.dindex,n.key,s),a.call(i,["cellChecked"],e.dindex,{key:n.key,rowIndex:e.rowIndex,colIndex:e.colIndex,editorConfig:n.editor.config,checked:l})}else i.config.body.onClick&&i.config.body.onClick.call(o)},rowSelector:function(e){return!i.list[e.dindex][i.config.columnKeys.disableSelection]&&(i.config.multipleSelect||i.selectedDataIndexs[0]===e.dindex||(t.body.updateRowState.call(i,["selectedClear"]),t.data.clearSelect.call(i)),t.data.select.call(i,e.dindex,void 0,{internalCall:!0}),void a.call(i,["selected"],e.dindex))},lineNumber:function(t){}};n=this.getAttribute("data-ax5grid-panel-name"),o=this.getAttribute("data-ax5grid-column-attr"),l=Number(this.getAttribute("data-ax5grid-column-row")),s=Number(this.getAttribute("data-ax5grid-column-col")),d=Number(this.getAttribute("data-ax5grid-column-rowIndex")),c=Number(this.getAttribute("data-ax5grid-column-colIndex")),r=Number(this.getAttribute("data-ax5grid-data-index")),o in u&&u[o]({panelName:n,attr:o,row:l,col:s,dindex:r,rowIndex:d,colIndex:c})}),this.$.container.body.on("dblclick","[data-ax5grid-column-attr]",function(e){var n,a,o,l,s,r,d,c={"default":function(n){if(this.isInlineEditing)for(var a in this.inlineEditing)if(a==n.dindex+"_"+n.colIndex+"_"+n.rowIndex)return this;var o=i.bodyRowMap[n.rowIndex+"_"+n.colIndex],l="";o&&(i.list[s].__isGrouping||(l=t.data.getValue.call(i,s,o.key))),t.body.inlineEdit.active.call(i,i.focusedColumn,e,l)},rowSelector:function(t){},lineNumber:function(t){}};n=this.getAttribute("data-ax5grid-panel-name"),a=this.getAttribute("data-ax5grid-column-attr"),o=Number(this.getAttribute("data-ax5grid-column-row")),l=Number(this.getAttribute("data-ax5grid-column-col")),r=Number(this.getAttribute("data-ax5grid-column-rowIndex")),d=Number(this.getAttribute("data-ax5grid-column-colIndex")),s=Number(this.getAttribute("data-ax5grid-data-index")),a in c&&c[a]({panelName:n,attr:a,row:o,col:l,dindex:s,rowIndex:r,colIndex:d})}),this.$.container.body.on("mouseover","tr",function(){return}),this.$.container.body.on("mousedown",'[data-ax5grid-column-attr="default"]',function(t){this.getAttribute("data-ax5grid-column-rowIndex")&&n.on.call(i,{panelName:this.getAttribute("data-ax5grid-panel-name"),dindex:Number(this.getAttribute("data-ax5grid-data-index")),rowIndex:Number(this.getAttribute("data-ax5grid-column-rowIndex")),colIndex:Number(this.getAttribute("data-ax5grid-column-colIndex")),colspan:Number(this.getAttribute("colspan"))})}).on("dragstart",function(t){return e.stopEvent(t),!1}),s.call(this)},s=function(){var e=this.config,i=t.util.divideTableByFrozenColumnIndex(this.bodyRowTable,this.xvar.frozenColumnIndex);if(this.asideBodyRowData=function(t){for(var i={rows:[]},n=0,a=t.rows.length;n":">"};if("__d-index__"===s)return"undefined"!=typeof n.__index?n.__index+1:"";if("__d-checkbox__"===s)return'
';if(o.editor&&function(e){return e.type in t.inlineEditor&&"inline"==t.inlineEditor[e.type].editMode}(o.editor))return l=l||t.data.getValue.call(this,a,s),e.isFunction(o.editor.disabled)&&o.editor.disabled.call({list:i,dindex:a,item:i[a],key:s,value:l})?l:t.inlineEditor[o.editor.type].getHtml(this,o.editor,l);if(o.formatter){var d={key:s,value:l||t.data.getValue.call(this,a,s),dindex:a,item:n,list:i};return e.isFunction(o.formatter)?o.formatter.call(d):t.formatter[o.formatter].call(d)}var c="";return"undefined"!=typeof l?c=l:(l=t.data.getValue.call(this,a,s),null!==l&&"undefined"!=typeof l&&(c=l)),"number"==typeof c?c:c.replace(/[<>]/g,function(t){return r[t]||t})},d=function(i,n,a){var o,l,s=a.key,r=a.label;return"undefined"==typeof s?(l={key:s,list:i.__groupingList,groupBy:i.__groupingBy},o=e.isFunction(r)?r.call(l):r,i[a.colIndex]=o,o):"__d-index__"===s?"":"__d-checkbox__"===s?"":a.collector?(l={key:s,list:i.__groupingList},o=e.isFunction(a.collector)?a.collector.call(l):t.collector[a.collector].call(l),i[a.colIndex]=o,a.formatter?(l.value=o,e.isFunction(a.formatter)?a.formatter.call(l):t.formatter[a.formatter].call(l)):o):" "},c=function(i,n){var a=n.key,o=n.label;if("undefined"==typeof a)return o;if("__d-index__"===a||"__d-checkbox__"===a)return" ";if(n.collector){var l,s={key:a,list:i};return l=e.isFunction(n.collector)?n.collector.call(s):t.collector[n.collector].call(s),n.formatter?(s.value=l,e.isFunction(n.formatter)?n.formatter.call(s):t.formatter[n.formatter].call(s)):l}return" "},u=function(i){var n=this.config,a=this.list;i&&(s.call(this),this.xvar.paintStartRowIndex=void 0);var o=Math.floor(Math.abs(this.$.panel["body-scroll"].position().top)/this.xvar.bodyTrHeight)+this.xvar.frozenRowIndex;if(this.xvar.dataRowCount===a.length&&this.xvar.paintStartRowIndex===o)return this;var l="undefined"==typeof this.xvar.paintStartRowIndex,u=this.asideBodyRowData,h=this.leftBodyRowData,p=this.bodyRowData,f=this.leftFootSumData,m=this.footSumData,g=this.asideBodyGroupingData,x=this.leftBodyGroupingData,v=this.bodyGroupingData,b=n.body.align,y=Math.ceil(this.$.panel.body.height()/this.xvar.bodyTrHeight)+1;this.xvar.scrollContentHeight=this.xvar.bodyTrHeight*(this.list.length-this.xvar.frozenRowIndex),this.$.livePanelKeys=[];var w=function(t,i,a,o,s,c){var u=this.$.panel[t];if(!l&&!c)return this.$.livePanelKeys.push(t),!1;var h,p,f,m,g,x,v,y,w,_,I,k=[],C=function(){return"undefined"!=typeof c&&"undefined"!=typeof c.paintStartRowIndex||(c={paintStartRowIndex:0,paintRowCount:s.length},!1)}();for(k.push(''),k.push(""),h=0,p=i.length;h');for(k.push(""),k.push(""),f=c.paintStartRowIndex,m=function(){var t;return t=s.length,c.paintRowCount+c.paintStartRowIndex"),v=0,y=$.rows[g].cols.length;v'),k.push(function(t){var e=n.body.columnHeight-2*n.body.columnPadding-n.body.columnBorderWidth;return w.multiLine||(t=n.body.columnHeight-n.body.columnBorderWidth),''}(_),S?d.call(this,s[f],f,w):r.call(this,s,s[f],f,w),""),k.push("");k.push(""),k.push("")}}return k.push("
"),C&&u.css({paddingTop:(c.paintStartRowIndex-this.xvar.frozenRowIndex)*c.bodyTrHeight}),u.empty().get(0).innerHTML=k.join(""),this.$.livePanelKeys.push(t),!0},_=function(t,i,a,o,s){var r=this.$.panel[t];if(!l&&!s)return this.$.livePanelKeys.push(t),!1;var d,u,h,p,f,m,g,x,v,y=[];for(y.push(''),y.push(""),d=0,u=i.length;d');for(y.push(""),y.push(""),h=0,p=a.rows.length;h'),f=0,m=a.rows[h].cols.length;f'),y.push(function(t){var e=n.body.columnHeight-2*n.body.columnPadding-n.body.columnBorderWidth;return g.multiLine||(t=n.body.columnHeight-n.body.columnBorderWidth),''}(x),c.call(this,o,g),""),y.push("");y.push(""),y.push("")}return y.push("
"),r.empty().get(0).innerHTML=y.join(""),this.$.livePanelKeys.push(t),!0},I={paintStartRowIndex:o,paintRowCount:y,bodyTrHeight:this.xvar.bodyTrHeight};n.asidePanelWidth>0&&(this.xvar.frozenRowIndex>0&&w.call(this,"top-aside-body",this.asideColGroup,u,g,a.slice(0,this.xvar.frozenRowIndex)),w.call(this,"aside-body-scroll",this.asideColGroup,u,g,a,I),n.footSum),this.xvar.frozenColumnIndex>0&&(this.xvar.frozenRowIndex>0&&w.call(this,"top-left-body",this.leftHeaderColGroup,h,x,a.slice(0,this.xvar.frozenRowIndex)),w.call(this,"left-body-scroll",this.leftHeaderColGroup,h,x,a,I),n.footSum&&this.needToPaintSum&&_.call(this,"bottom-left-body",this.leftHeaderColGroup,f,a)),this.xvar.frozenRowIndex>0&&w.call(this,"top-body-scroll",this.headerColGroup,p,v,a.slice(0,this.xvar.frozenRowIndex)),w.call(this,"body-scroll",this.headerColGroup,p,v,a,I),n.footSum&&this.needToPaintSum&&_.call(this,"bottom-body-scroll",this.headerColGroup,m,a,I),n.rightSum,this.xvar.paintStartRowIndex=o,this.xvar.paintRowCount=y,this.xvar.dataRowCount=a.length,this.needToPaintSum=!1,t.page.statusUpdate.call(this)},h=function(i,n,a,o,l){var s=this,u=this.config,h=this.list,p=this.$.panel[i].find('[data-ax5grid-tr-data-index="'+n+'"]').find('[data-ax5grid-column-rowindex="'+a+'"][data-ax5grid-column-colindex="'+o+'"]').find("[data-ax5grid-cellholder]"),f=this.colGroup,m=f[o];p.html(r.call(this,h,h[n],n,m)),m.editor&&m.editor.updateWith&&m.editor.updateWith.forEach(function(e){f.forEach(function(i){if(i.key==e){var a=i.rowIndex,o=i.colIndex,l=t.util.findPanelByColumnIndex.call(s,n,o,a).panelName,d=s.$.panel[l].find('[data-ax5grid-tr-data-index="'+n+'"]').find('[data-ax5grid-column-rowindex="'+a+'"][data-ax5grid-column-colindex="'+o+'"]').find("[data-ax5grid-cellholder]");d.html(r.call(s,h,h[n],n,i))}})});var g=Math.floor(Math.abs(this.$.panel["body-scroll"].position().top)/this.xvar.bodyTrHeight)+this.xvar.frozenRowIndex,x=this.leftFootSumData,v=this.footSumData,b=(this.asideBodyGroupingData,this.leftBodyGroupingData),y=this.bodyGroupingData,w=u.body.align,_=Math.ceil(this.$.panel.body.height()/this.xvar.bodyTrHeight)+1,I={paintStartRowIndex:g,paintRowCount:_,bodyTrHeight:this.xvar.bodyTrHeight},k=function(t,i,n,a,o){var l,s,r,d,h,p,f,m,g,x=this.$.panel[t],v=[];for(v.push(''),v.push(""),l=0,s=i.length;l');for(v.push(""),v.push(""),r=0,d=n.rows.length;r'),h=0,p=n.rows[r].cols.length;h'),v.push(function(t){var e=u.body.columnHeight-2*u.body.columnPadding-u.body.columnBorderWidth;return f.multiLine||(t=u.body.columnHeight-u.body.columnBorderWidth),''}(m),c.call(this,a,f),""),v.push("");v.push(""),v.push("")}return v.push("
"),x.empty().get(0).innerHTML=v.join(""),!0},C=function(t,i,n,a,o){var l,s,r,c,h,p,f,m,g,x=this.$.panel[t],v=[];for(l=o.paintStartRowIndex,s=function(){var t;return t=a.length,o.paintRowCount+o.paintStartRowIndex'),v.push(function(t){var e=u.body.columnHeight-2*u.body.columnPadding-u.body.columnBorderWidth;return f.multiLine||(t=u.body.columnHeight-u.body.columnBorderWidth),''}(m),d.call(this,a[l],l,f),""),v.push("");v.push("")}x.find('tr[data-ax5grid-tr-data-index="'+l+'"]').empty().get(0).innerHTML=v.join("")}};u.body.grouping&&(this.xvar.frozenColumnIndex>0&&(this.xvar.frozenRowIndex>0&&C.call(this,"top-left-body",this.leftHeaderColGroup,b,h.slice(0,this.xvar.frozenRowIndex),{paintStartRowIndex:0,paintRowCount:this.xvar.frozenRowIndex,bodyTrHeight:this.xvar.bodyTrHeight}),C.call(this,"left-body-scroll",this.leftHeaderColGroup,b,h,I)),this.xvar.frozenRowIndex>0&&C.call(this,"top-body-scroll",this.headerColGroup,y,h.slice(0,this.xvar.frozenRowIndex),{paintStartRowIndex:0,paintRowCount:this.xvar.frozenRowIndex,bodyTrHeight:this.xvar.bodyTrHeight}),C.call(this,"body-scroll",this.headerColGroup,y,h,I)),this.xvar.frozenColumnIndex>0&&u.footSum&&this.needToPaintSum&&k.call(this,"bottom-left-body",this.leftHeaderColGroup,x,h),u.footSum&&this.needToPaintSum&&k.call(this,"bottom-body-scroll",this.headerColGroup,v,h,I)},p=function(t){var i=this.config,n=this.list,a=Math.floor(Math.abs(this.$.panel["body-scroll"].position().top)/this.xvar.bodyTrHeight)+this.xvar.frozenRowIndex,o=(this.asideBodyRowData,this.leftBodyRowData),l=this.bodyRowData,s=this.leftFootSumData,u=this.footSumData,h=(this.asideBodyGroupingData,this.leftBodyGroupingData),p=this.bodyGroupingData,f=i.body.align,m=Math.ceil(this.$.panel.body.height()/this.xvar.bodyTrHeight)+1,g={paintStartRowIndex:a,paintRowCount:m,bodyTrHeight:this.xvar.bodyTrHeight},x=function(t,n,a,o){var l,s,r,d,u,h,p,m,g,x=this.$.panel[t],v=[];for(v.push(''),v.push(""),l=0,s=n.length;l');for(v.push(""),v.push(""),r=0,d=a.rows.length;r'),u=0,h=a.rows[r].cols.length;u'),v.push(function(t){var e=i.body.columnHeight-2*i.body.columnPadding-i.body.columnBorderWidth;return p.multiLine||(t=i.body.columnHeight-i.body.columnBorderWidth),''}(m),c.call(this,o,p),""),v.push("");v.push(""),v.push("")}return v.push("
"),x.empty().get(0).innerHTML=v.join(""),!0},v=function(t,n,a,o,l){var s,r,c,u,h,p,m,g,x,v=this.$.panel[t],b=[];for(s=l.paintStartRowIndex,r=function(){var t;return t=o.length,l.paintRowCount+l.paintStartRowIndex'),b.push(function(t){var e=i.body.columnHeight-2*i.body.columnPadding-i.body.columnBorderWidth;return m.multiLine||(t=i.body.columnHeight-i.body.columnBorderWidth),''}(g),d.call(this,o[s],s,m),""),b.push("");b.push("")}v.find('tr[data-ax5grid-tr-data-index="'+s+'"]').empty().get(0).innerHTML=b.join("")}},b=function(t,n,a,o,l){var l,s,d,c,u,h,p,m,g=this.$.panel[t],x=[],v=a;for(s=0,d=v.rows.length;s'),x.push(function(t){var e=i.body.columnHeight-2*i.body.columnPadding-i.body.columnBorderWidth;return h.multiLine||(t=i.body.columnHeight-i.body.columnBorderWidth),''}(p),r.call(this,o,o[l],l,h),""),x.push("");x.push("")}g.find('tr[data-ax5grid-tr-data-index="'+l+'"]').empty().get(0).innerHTML=x.join("")};this.xvar.frozenColumnIndex>0&&(this.xvar.frozenRowIndex>0&&b.call(this,"top-left-body",this.leftHeaderColGroup,o,n,t),b.call(this,"left-body-scroll",this.leftHeaderColGroup,o,n,t)),this.xvar.frozenRowIndex>0&&b.call(this,"top-body-scroll",this.headerColGroup,l,n,t),b.call(this,"body-scroll",this.headerColGroup,l,n,t),i.body.grouping&&(this.xvar.frozenColumnIndex>0&&(this.xvar.frozenRowIndex>0&&v.call(this,"top-left-body",this.leftHeaderColGroup,h,n.slice(0,this.xvar.frozenRowIndex)),v.call(this,"left-body-scroll",this.leftHeaderColGroup,h,n,g)),this.xvar.frozenRowIndex>0&&v.call(this,"top-body-scroll",this.headerColGroup,p,n.slice(0,this.xvar.frozenRowIndex)),v.call(this,"body-scroll",this.headerColGroup,p,n,g)),this.xvar.frozenColumnIndex>0&&i.footSum&&this.needToPaintSum&&x.call(this,"bottom-left-body",this.leftHeaderColGroup,s,n),i.footSum&&this.needToPaintSum&&x.call(this,"bottom-body-scroll",this.headerColGroup,u,n,g)},f=function(e,i){var n=this.config;if(this.isInlineEditing)for(var a in this.inlineEditing)t.body.inlineEdit.deActive.call(this,"ESC",a);n.asidePanelWidth>0&&"top"in e&&this.$.panel["aside-body-scroll"].css({top:e.top}),this.xvar.frozenColumnIndex>0&&"top"in e&&this.$.panel["left-body-scroll"].css({top:e.top}),this.xvar.frozenRowIndex>0&&"left"in e&&this.$.panel["top-body-scroll"].css({left:e.left}),this.$.panel["body-scroll"].css(e),n.footSum&&"left"in e&&this.$.panel["bottom-body-scroll"].css({left:e.left}),!i&&"top"in e&&u.call(this)},m=function(){i.focusClear.call(this),i.clear.call(this),this.isInlineEditing&&x.deActive.call(this)},g=function(e){var n={UD:function(e){var n=!0,a=void 0,o=void 0,l=void 0;for(var s in this.focusedColumn){a=jQuery.extend({},this.focusedColumn[s],!0);break}if(!a)return!1;for(o=this.bodyRowMap[a.rowIndex+"_"+a.colIndex],i.focusClear.call(this),i.clear.call(this),e>0?a.rowIndex+(o.rowspan-1)+e>this.bodyRowTable.rows.length-1?(a.dindex=a.dindex+e,a.rowIndex=0,a.dindex>this.list.length-1&&(a.dindex=this.list.length-1,n=!1)):a.rowIndex=a.rowIndex+e:a.rowIndex+e<0?(a.dindex=a.dindex+e,a.rowIndex=this.bodyRowTable.rows.length-1,a.dindex<0&&(a.dindex=0,n=!1)):a.rowIndex=a.rowIndex+e,l=0;"undefined"==typeof this.bodyRowMap[a.rowIndex+"_"+a.colIndex];){if(0==a.rowIndex||l%2==(e>0?0:1)?a.colIndex--:a.rowIndex--,a.rowIndex<=0&&a.colIndex<=0){n=!1;break}l++}var r=t.util.findPanelByColumnIndex.call(this,a.dindex,a.colIndex);return a.panelName=r.panelName,function(){a.dindex+1>this.xvar.frozenRowIndex&&(a.dindex<=this.xvar.paintStartRowIndex?(f.call(this,{top:-(a.dindex-this.xvar.frozenRowIndex)*this.xvar.bodyTrHeight}),t.scroller.resize.call(this)):a.dindex+1>this.xvar.paintStartRowIndex+(this.xvar.paintRowCount-2)&&(f.call(this,{top:-(a.dindex-this.xvar.frozenRowIndex-this.xvar.paintRowCount+3)*this.xvar.bodyTrHeight}),t.scroller.resize.call(this)))}.call(this),this.focusedColumn[a.dindex+"_"+a.colIndex+"_"+a.rowIndex]=a,this.$.panel[a.panelName].find('[data-ax5grid-tr-data-index="'+a.dindex+'"]').find('[data-ax5grid-column-rowindex="'+a.rowIndex+'"][data-ax5grid-column-colindex="'+a.colIndex+'"]').attr("data-ax5grid-column-focused","true"),n},LR:function(e){var n,a,o=!0,l=0,s=!1,r="";for(var d in this.focusedColumn){n=jQuery.extend({},this.focusedColumn[d],!0);break}if(!n)return!1;for(a=this.bodyRowMap[n.rowIndex+"_"+n.colIndex],i.focusClear.call(this),i.clear.call(this),e<0?(n.colIndex=n.colIndex+e,n.colIndex<0&&(n.colIndex=0,o=!1)):(n.colIndex=n.colIndex+(a.colspan-1)+e,n.colIndex>this.colGroup.length-1&&(n.colIndex=this.colGroup.length-1,o=!1)),"undefined"==typeof this.bodyRowMap[n.rowIndex+"_"+n.colIndex]&&(n.rowIndex=0), -l=0;"undefined"==typeof this.bodyRowMap[n.rowIndex+"_"+n.colIndex];){if(n.colIndex--,n.rowIndex<=0&&n.colIndex<=0){o=!1;break}l++}var c=t.util.findPanelByColumnIndex.call(this,n.dindex,n.colIndex);n.panelName=c.panelName,r=c.containerPanelName,s=c.isScrollPanel,this.focusedColumn[n.dindex+"_"+n.colIndex+"_"+n.rowIndex]=n;var u=this.$.panel[n.panelName].find('[data-ax5grid-tr-data-index="'+n.dindex+'"]').find('[data-ax5grid-column-rowindex="'+n.rowIndex+'"][data-ax5grid-column-colindex="'+n.colIndex+'"]').attr("data-ax5grid-column-focused","true");if(u&&s){var h=function(){return u.position().left+u.outerWidth()>Math.abs(this.$.panel[n.panelName].position().left)+this.$.panel[r].width()?u.position().left+u.outerWidth()-this.$.panel[r].width():Math.abs(this.$.panel[n.panelName].position().left)>u.position().left?u.position().left:void 0}.call(this);"undefined"!=typeof h&&(t.header.scrollTo.call(this,{left:-h}),f.call(this,{left:-h}),t.scroller.resize.call(this))}return o},INDEX:function(e){var n,a,o,l=!0;for(var s in this.focusedColumn){n=jQuery.extend({},this.focusedColumn[s],!0);break}for(n||(n={rowIndex:0,colIndex:0}),a=this.bodyRowMap[n.rowIndex+"_"+n.colIndex],i.focusClear.call(this),i.clear.call(this),"end"==e&&(e=this.list.length-1),n.dindex=e,n.rowIndex=0,o=0;"undefined"==typeof this.bodyRowMap[n.rowIndex+"_"+n.colIndex]&&(0==n.rowIndex||o%2==(_dy>0?0:1)?n.colIndex--:n.rowIndex--,!(n.rowIndex<=0&&n.colIndex<=0));)o++;var r=t.util.findPanelByColumnIndex.call(this,n.dindex,n.colIndex);return n.panelName=r.panelName,function(){n.dindex+1>this.xvar.frozenRowIndex&&(n.dindexthis.xvar.paintStartRowIndex+(this.xvar.paintRowCount-2)&&(f.call(this,{top:-(n.dindex-this.xvar.frozenRowIndex-this.xvar.paintRowCount+3)*this.xvar.bodyTrHeight}),t.scroller.resize.call(this)))}.call(this),this.focusedColumn[n.dindex+"_"+n.colIndex+"_"+n.rowIndex]=n,this.$.panel[n.panelName].find('[data-ax5grid-tr-data-index="'+n.dindex+'"]').find('[data-ax5grid-column-rowindex="'+n.rowIndex+'"][data-ax5grid-column-colindex="'+n.colIndex+'"]').attr("data-ax5grid-column-focused","true"),l}},a={UP:function(){return n.UD.call(this,-1)},DOWN:function(){return n.UD.call(this,1)},LEFT:function(){return n.LR.call(this,-1)},RIGHT:function(){return n.LR.call(this,1)},HOME:function(){return n.INDEX.call(this,0)},END:function(){return n.INDEX.call(this,"end")},position:function(t){return n.INDEX.call(this,t)}};return e in a?a[e].call(this):a.position.call(this,e)},x={active:function(i,n,o){var l,s,r,d,c,u,h,p=this;for(var f in i){if(d=i[f].panelName,l=i[f].dindex,s=i[f].colIndex,r=i[f].rowIndex,c=i[f].colspan,u=this.colGroup[s],!(h=u.editor))return this;if(e.isFunction(h.disabled)&&h.disabled.call({list:this.list,dindex:l,item:this.list[l],key:u.key,value:o}))return this;if(!function(e,i){if(e.type in t.inlineEditor)return"popup"==t.inlineEditor[e.type].editMode}(h)){if("checkbox"==h.type){var m,g;g=h.config&&h.config.trueValue?(m=!(o==h.config.trueValue))?h.config.trueValue:h.config.falseValue:m=0==o||"false"==o||o<"1"?"true":"false",t.data.setValue.call(p,l,u.key,g),a.call(p,["cellChecked"],l,{key:u.key,rowIndex:r,colIndex:s,editorConfig:u.editor.config,checked:m})}return this}if(this.list[l].__isGrouping)return!1;if(f in this.inlineEditing)return!1;this.inlineEditing[f]={editor:h,panelName:d,columnKey:f,column:i[f],useReturnToSave:t.inlineEditor[h.type].useReturnToSave},this.isInlineEditing=!0}if(this.isInlineEditing){var x=t.data.getValue.call(p,l,u.key),v=function(t,i){return e.isNothing(t)&&(t=e.isNothing(x)?"":x),"money"==i.type?e.number(t,{money:!0}):t}.call(this,o,h);return this.inlineEditing[f].$inlineEditorCell=this.$.panel[d].find('[data-ax5grid-tr-data-index="'+l+'"]').find('[data-ax5grid-column-rowindex="'+r+'"][data-ax5grid-column-colindex="'+s+'"]').find("[data-ax5grid-cellholder]"),this.inlineEditing[f].$inlineEditor=t.inlineEditor[h.type].init(this,f,h,this.inlineEditing[f].$inlineEditorCell,v),!0}},deActive:function(i,n,a){if(!this.inlineEditing[n])return this;var o=this.inlineEditing[n].panelName,l=this.inlineEditing[n].column.dindex,s=this.inlineEditing[n].column.rowIndex,r=this.inlineEditing[n].column.colIndex,d=this.bodyRowMap[this.inlineEditing[n].column.rowIndex+"_"+this.inlineEditing[n].column.colIndex],c=function(t){return"undefined"==typeof a?"SELECT"==t.get(0).tagName||"INPUT"==t.get(0).tagName||"TEXTAREA"==t.get(0).tagName?t.val():(i="CANCEL",!1):a}(this.inlineEditing[n].$inlineEditor),u=function(t,i){return"money"==i.type?e.number(t):t}.call(this,c,d.editor),h={CANCEL:function(t,e,i){h.__clear.call(this)},RETURN:function(e,i,n){t.data.setValue.call(this,e,i.key,n)?(h.__clear.call(this),t.body.repaintCell.call(this,o,l,s,r,n)):h.__clear.call(this)},__clear:function(){this.isInlineEditing=!1;var t=this.inlineEditing[n].$inlineEditor.data("binded-ax5ui");"ax5picker"==t?this.inlineEditing[n].$inlineEditor.ax5picker("close"):"ax5select"==t&&this.inlineEditing[n].$inlineEditor.ax5select("close"),this.inlineEditing[n].$inlineEditor.remove(),this.inlineEditing[n].$inlineEditor=null,this.inlineEditing[n].$inlineEditorCell=null,this.inlineEditing[n]=void 0,delete this.inlineEditing[n]}};i in h?h[i||"RETURN"].call(this,l,d,u):h.__clear.call(this)},keydown:function(e,i,n){var o={ESC:function(){for(var t in this.inlineEditing)x.deActive.call(this,"CANCEL",t)},RETURN:function(){if(this.isInlineEditing)this.inlineEditing[i]&&this.inlineEditing[i].useReturnToSave&&x.deActive.call(this,"RETURN",i);else for(var e in this.focusedColumn){var o=this.focusedColumn[e],l=this.bodyRowMap[o.rowIndex+"_"+o.colIndex],s=o.dindex,r="";l&&(this.list[s].__isGrouping||(r=t.data.getValue.call(this,s,l.key)));var d=this.colGroup[o.colIndex];if("inline"===t.inlineEditor[d.editor.type].editMode){if(n&&n.moveFocus);else if(l.editor&&"checkbox"==l.editor.type){r=t.data.getValue.call(this,s,l.key);var c,u;u=l.editor.config&&l.editor.config.trueValue?(c=!(r==l.editor.config.trueValue))?l.editor.config.trueValue:l.editor.config.falseValue:c=0==r||"false"==r||r<"1"?"true":"false",t.data.setValue.call(this,o.dindex,l.key,u),a.call(this,["cellChecked"],s,{key:l.key,rowIndex:o.rowIndex,colIndex:o.colIndex,editorConfig:l.editor.config,checked:c})}}else t.body.inlineEdit.active.call(this,this.focusedColumn,null,r)}}};e in o&&o[e].call(this,e,i,n)}},v=function(){var t=this.config,e=this.list,i=this.bodyRowData,n=this.footSumData,a=this.bodyGroupingData,o=function(t,e,i,n){var a,o,l,s,c,u,h,p=[];for(a=0,o=n.length;a"),c=0,u=f.rows[l].cols.length;c",m?d.call(this,n[a],a,h):r.call(this,n,n[a],a,h),"");p.push("\n")}}return p.join("")},l=function(t,e,i){var n=[],a=void 0,o=void 0,l=void 0,s=void 0,r=void 0;for(a=0,o=e.rows.length;a"),l=0,s=e.rows[a].cols.length;l",c.call(this,i,r),"");n.push("\n")}return n.join("")},s=[];return s.push(o.call(this,this.headerColGroup,i,a,e)),t.footSum&&s.push(l.call(this,this.headerColGroup,n,e)),t.rightSum,s.join("")};t.body={init:l,repaint:u,repaintCell:h,repaintRow:p,updateRowState:a,updateRowStateAll:o,scrollTo:f,blur:m,moveFocus:g,inlineEdit:x,getExcelString:v}}(),function(){var t=ax5.ui.grid,e=ax5.util,i=function(){for(var t=0,i=this.list.length;i--;)"__groupingList"in this.list[i]||(t+=e.number(this.list[i][this.key]));return t},n=function(){for(var t=0,i=this.list.length,n=0;i--;)"__groupingList"in this.list[i]||(t+=e.number(this.list[i][this.key]),n++);return e.number(t/(n||1),{round:2})};t.collector={sum:i,avg:n}}(),function(){var t=ax5.ui.grid,e=ax5.util,i=function(){},n=function(t){for(var e=0,i=t.length,n=[];e0&&s!=d[c].compareString){for(var p={keys:[],labels:[],list:d[c].list},f=0;fthis.list.length?this.list.length:this.config.frozenRowIndex,this.xvar.paintStartRowIndex=void 0,t.page.navigationUpdate.call(this),this.config.body.grouping,this},l=function(t){return{list:this.list,page:this.page}},s=function(e){var i=[],n=0,a=this.list.length;switch(e){case"modified":for(;nthis.list.length?this.list.length:this.config.frozenRowIndex,this.xvar.paintStartRowIndex=void 0,t.page.navigationUpdate.call(this),this},d=function(i){var o=this.config.body.grouping?n.call(this,this.list):this.list,l={first:function(){o.splice(i,1)},last:function(){var t=o.length-1;o.splice(t,1)}};if("undefined"==typeof i&&(i="last"),i in l)l[i].call(this,i);else{if(!e.isNumber(i))throw"invalid argument _dindex";o.splice(i,1)}return o=this.config.body.grouping?a.call(this,x.call(this,this.sortInfo,o)):Object.keys(this.sortInfo).length?a.call(this,x.call(this,this.sortInfo,o)):a.call(this,o),this.list=o,this.needToPaintSum=!0,this.xvar.frozenRowIndex=this.config.frozenRowIndex>this.list.length?this.list.length:this.config.frozenRowIndex,this.xvar.paintStartRowIndex=void 0,t.page.navigationUpdate.call(this),this},c=function(i){var o=this.config.body.grouping?n.call(this,this.list):this.list,l={first:function(){o[0][this.config.columnKeys.deleted]=!0},last:function(){o[o.length-1][this.config.columnKeys.deleted]=!0},selected:function(){for(var t=o.length;t--;)o[t][this.config.columnKeys.selected]&&(o[t][this.config.columnKeys.deleted]=!0)}};if("undefined"==typeof i&&(i="last"),i in l)l[i].call(this,i);else{if(!e.isNumber(i))throw"invalid argument _dindex";o[i][this.config.columnKeys.deleted]=!0}return o=this.config.body.grouping?a.call(this,x.call(this,this.sortInfo,o)):Object.keys(this.sortInfo).length?a.call(this,x.call(this,this.sortInfo,o)):a.call(this,o),this.list=o,this.needToPaintSum=!0,this.xvar.frozenRowIndex=this.config.frozenRowIndex>this.list.length?this.list.length:this.config.frozenRowIndex,this.xvar.paintStartRowIndex=void 0,t.page.navigationUpdate.call(this),this},u=function(t,i){if(!e.isNumber(i))throw"invalid argument _dindex";this.needToPaintSum=!0,this.list.splice(i,1,t),this.config.body.grouping&&(this.list=a.call(this,n.call(this,this.list)))},h=function(e,i,n){var a=p.call(this,e,i);if(this.needToPaintSum=!0,a!==n){if(/[\.\[\]]/.test(i))try{this.list[e][this.config.columnKeys.modified]=!0,Function("val","this"+t.util.getRealPathForDataItem(i)+" = val;").call(this.list[e],n)}catch(o){}else this.list[e][this.config.columnKeys.modified]=!0,this.list[e][i]=n;this.onDataChanged&&this.onDataChanged.call({self:this,list:this.list,dindex:e,item:this.list[e],key:i,value:n})}return!0},p=function(e,i,n){if(/[\.\[\]]/.test(i))try{n=Function("","return this"+t.util.getRealPathForDataItem(i)+";").call(this.list[e])}catch(a){}else n=this.list[e][i];return n},f=function(){this.selectedDataIndexs=[]},m=function(t,e,i){var n=this.config;return!this.list[t].__isGrouping&&(!this.list[t][n.columnKeys.disableSelection]&&("undefined"==typeof e?(this.list[t][n.columnKeys.selected]=!this.list[t][n.columnKeys.selected])&&this.selectedDataIndexs.push(t):(this.list[t][n.columnKeys.selected]=e)&&this.selectedDataIndexs.push(t),this.onDataChanged&&i&&i.internalCall&&this.onDataChanged.call({self:this,list:this.list,dindex:t,item:this.list[t],key:n.columnKeys.selected,value:this.list[t][n.columnKeys.selected]}),this.list[t][n.columnKeys.selected]))},g=function(t,e){var i=this.config,n=this.list.length;if("undefined"==typeof t)for(;n--;)this.list[n].__isGrouping||e&&e.filter&&e.filter.call(this.list[n])!==!0||this.list[n][i.columnKeys.disableSelection]||(this.list[n][i.columnKeys.selected]=!this.list[n][i.columnKeys.selected])&&this.selectedDataIndexs.push(n);else for(;n--;)this.list[n].__isGrouping||e&&e.filter&&e.filter.call(this.list[n])!==!0||this.list[n][i.columnKeys.disableSelection]||(this.list[n][i.columnKeys.selected]=t)&&this.selectedDataIndexs.push(n);return this.onDataChanged&&e&&e.internalCall&&this.onDataChanged.call({self:this,list:this.list}),this.list},x=function(i,n){var a=n||this.list,o=[],l=function(e,i,n){if(/[\.\[\]]/.test(i))try{n=Function("","return this"+t.util.getRealPathForDataItem(i)+";").call(e)}catch(a){}else n=e[i];return n};for(var s in i)o[i[s].seq]={key:s,order:i[s].orderBy};o=e.filter(o,function(){return"undefined"!=typeof this});var r=0,d=o.length,c=void 0,u=void 0;return a.sort(function(t,e){for(r=0;ru)return"asc"===o[r].order?1:-1}}),n?a:(this.xvar.frozenRowIndex=this.config.frozenRowIndex>this.list.length?this.list.length:this.config.frozenRowIndex,this.xvar.paintStartRowIndex=void 0,t.page.navigationUpdate.call(this),this)};t.data={init:i,set:o,get:l,getList:s,setValue:h,getValue:p,clearSelect:f,select:m,selectAll:g,add:r,remove:d,deleteRow:c,update:u,sort:x,initData:a,clearGroupingData:n}}(),function(){var t=ax5.ui.grid,e=(ax5.util,function(t){return window.btoa(unescape(encodeURIComponent(t)))}),i="data:application/vnd.ms-excel;base64,",n=function(){return"\ufeff\n{{#tables}}{{{body}}}{{/tables}}\n"},a=function(t,a){var o,l=[].concat(t);o=ax5.mustache.render(n(),{worksheet:function(){var t=[];return l.forEach(function(e,i){t.push({name:"Sheet"+(i+1)})}),t}(),tables:function(){var t=[];return l.forEach(function(e,i){t.push({body:e})}),t}()});var s=navigator.userAgent.indexOf("Chrome")>-1,r=!s&&navigator.userAgent.indexOf("Safari")>-1,d=!!document.documentMode;if(navigator.msSaveOrOpenBlob){var c=new Blob([o],{type:"text/html"});window.navigator.msSaveOrOpenBlob(c,a)}else if(r){var u=window.open("about:blank",this.id+"-excel-export","width=600,height=400");u.document.write(o),u=null}else if(d&&"undefined"==typeof Blob){var h=jQuery('');jQuery(document.body).append(h);var p=window[this.id+"-excel-export"];p.document.open("text/html","replace"),p.document.write(o),p.document.close(),p.focus(),p.document.execCommand("SaveAs",!0,a),h.remove()}else{var f=document.body.appendChild(document.createElement("a"));"download"in f&&(f.download=a,f.href=i+e(o),f.click(),document.body.removeChild(f))}return!0};t.excel={"export":a}}(),function(){var t=ax5.ui.grid,e=ax5.util,i=function(){return e.number(this.value,{money:!0})};t.formatter={money:i}}(),function(){var t=ax5.ui.grid,e=ax5.util,i={on:function(n,a){var o=this,l=$(n),s=l.offset().left,r=o.$.container.root.offset().left;o.xvar.columnResizerIndex=a;var d={min:-o.colGroup[a]._width+2,max:o.colGroup[a+1]?o.colGroup[a+1]._width:o.$.container.root.width()-2};jQuery(document.body).bind(t.util.ENM.mousemove+".ax5grid-"+this.instanceId,function(e){var i=t.util.getMousePosition(e);o.xvar.__da=i.clientX-o.xvar.mousePosition.clientX,d.min>o.xvar.__da?o.xvar.__da=d.min:d.max':t.label||" "},l=function(t){var i=this.config,n=this.colGroup;t&&(a.call(this),this.xvar.paintStartRowIndex=void 0);var l=this.asideHeaderData,s=this.leftHeaderData,r=this.headerData,d=i.header.align;this.leftHeaderColGroup=n.slice(0,this.config.frozenColumnIndex),this.headerColGroup=n.slice(this.config.frozenColumnIndex);var c=function(t,a,l){var s=0,r=[];r.push(''),r.push("");for(var c=0,u=a.length;c'),s+=a[c]._width;r.push(""),r.push("");for(var h=0,p=l.rows.length;h');for(var m=0,g=l.rows[h].cols.length;m'),r.push(function(){var t=i.header.columnHeight-2*i.header.columnPadding-i.header.columnBorderWidth;return''}(),function(){var t="";return e.isNothing(x.key)||e.isNothing(x.colIndex)||i.sortable!==!0&&x.sortable!==!0||x.sortable===!1||(t+=''),t}(),o.call(this,x),""),e.isNothing(x.colIndex)||i.enableFilter&&r.push(''),r.push("")}r.push(""),r.push("")}return r.push("
"),t.html(r.join("")),function(){for(var n=i.header.columnHeight*l.rows.length-i.header.columnBorderWidth,o=0,s=[],r=0,d=a.length;r'))}t.append(s)}.call(this),s};i.asidePanelWidth>0&&c.call(this,this.$.panel["aside-header"],this.asideColGroup,l),i.frozenColumnIndex>0&&c.call(this,this.$.panel["left-header"],this.leftHeaderColGroup,s),this.xvar.scrollContentWidth=c.call(this,this.$.panel["header-scroll"],this.headerColGroup,r),i.rightSum},s=function(t){return this.$.panel["header-scroll"].css(t),this},r=function(t){var e="",i={},n=0;for(var a in this.sortInfo)this.sortInfo[a].fixed&&(i[a]=this.sortInfo[a],n++);for(var o=0,l=this.colGroup.length;o");for(var l=0,s=e.rows[n].cols.length;l",o.call(this,r),"")}i.push("")}return i.join("")};return i.call(this,t,e)};t.header={init:n,repaint:l,scrollTo:s,toggleSort:r,applySortStatus:d,getExcelString:c}}(),function(){var t=ax5.ui.grid,e={useReturnToSave:!0,editMode:"popup",getHtml:function(t,e,i,n){return''},init:function(e,i,n,a,o){var l;return a.append(l=jQuery(this.getHtml(e,i,n,o))),this.bindUI(e,i,l,n,a,o),l.on("blur",function(){t.body.inlineEdit.deActive.call(e,"RETURN",i)}),l},bindUI:function(t,e,i,n,a,o){i.focus().select()}},i={useReturnToSave:!0,editMode:"popup",getHtml:function(t,e,i,n){return''},init:function(e,i,n,a,o){var l;return a.append(l=jQuery(this.getHtml(e,i,n,o))),this.bindUI(e,i,l,n,a,o),l.on("blur",function(){t.body.inlineEdit.deActive.call(e,"RETURN",i)}),l},bindUI:function(t,e,i,n,a,o){i.data("binded-ax5ui","ax5formater"),i.ax5formatter({pattern:"money"}),i.focus().select()}},n={useReturnToSave:!0,editMode:"popup",getHtml:function(t,e,i,n){return''},init:function(e,i,n,a,o){var l;return a.append(l=jQuery(this.getHtml(e,i,n,o))),this.bindUI(e,i,l,n,a,o),l.on("blur",function(){t.body.inlineEdit.deActive.call(e,"RETURN",i)}),l},bindUI:function(t,e,i,n,a,o){i.data("binded-ax5ui","ax5formater"),i.ax5formatter({pattern:"number"}),i.focus().select()}},a={useReturnToSave:!0,editMode:"popup",getHtml:function(t,e,i,n){return''},init:function(t,e,i,n,a){var o;return n.append(o=jQuery(this.getHtml(t,e,i,a))),this.bindUI(t,e,o,i,n,a),o},bindUI:function(e,i,n,a,o,l){var s=e;n.data("binded-ax5ui","ax5picker"),n.ax5picker({direction:"auto",content:{type:"date",formatter:{pattern:"date"}},onStateChanged:function(){"open"==this.state?this.self.activePicker.attr("data-ax5grid-inline-edit-picker","date"):"close"==this.state&&t.body.inlineEdit.deActive.call(s,"RETURN",i)}}),n.focus().select()}},o={useReturnToSave:!1,editMode:"popup",getHtml:function(t,e,i,n){var a=[];return a.push('
'),a.push("
"),a.join("")},init:function(t,e,i,n,a){var o;return n.append(o=jQuery(this.getHtml(t,e,i,a))),this.bindUI(t,e,o,i,n,a),o},bindUI:function(e,i,n,a,o,l){var s={columnKeys:{optionValue:"value",optionText:"text",optionSelected:"selected"}};jQuery.extend(!0,s,a.config),s.options.forEach(function(t){t[s.columnKeys.optionValue]==l&&(t[s.columnKeys.optionSelected]=!0)});var r=e;n.data("binded-ax5ui","ax5select"),n.ax5select({direction:"auto",columnKeys:s.columnKeys,options:s.options,onStateChanged:function(){"open"==this.state?this.self.activeSelectOptionGroup.attr("data-ax5grid-inline-edit-picker","select"):"changeValue"==this.state?t.body.inlineEdit.deActive.call(r,"RETURN",i,this.value[0][s.columnKeys.optionValue]):"close"==this.state&&t.body.inlineEdit.deActive.call(r,"ESC",i)}}),n.ax5select("open"),n.ax5select("setValue",l),n.find("a").focus()}},l={editMode:"inline",getHtml:function(t,e,i){var n,a=t.config.body.columnHeight-2*t.config.body.columnPadding-t.config.body.columnBorderWidth;n=e.config&&e.config.trueValue?i==e.config.trueValue?"true":"false":0==i||"false"==i||i<"1"?"false":"true";var o={marginTop:2,height:a-4};return jQuery.extend(!0,o,e.config),o.marginTop=(a-o.height)/2,'
'}};t.inlineEditor={text:e,money:i,number:n,date:a,select:o,checkbox:l}}(),function(){var t=ax5.ui.grid,e=ax5.util,i=function(t){var e=function(t){this.page.currentPage!=t&&(this.page.selectPage=t,this.config.page.onChange&&this.config.page.onChange.call({self:this,page:this.page,data:this.data}))},i={first:function(){e.call(this,0)},prev:function(){var t=this.page.currentPage-1;t<0&&(t=0),e.call(this,t)},next:function(){var t=this.page.currentPage+1;t>this.page.totalPages-1&&(t=this.page.totalPages-1),e.call(this,t)},last:function(){e.call(this,this.page.totalPages-1)}};t in i?i[t].call(this):e.call(this,t-1)},n=function(){var e=this;if(this.page){var n={hasPage:!1,currentPage:this.page.currentPage,pageSize:this.page.pageSize,totalElements:this.page.totalElements,totalPages:this.page.totalPages,firstIcon:this.config.page.firstIcon,prevIcon:this.config.page.prevIcon||"«",nextIcon:this.config.page.nextIcon||"»",lastIcon:this.config.page.lastIcon},a=this.config.page.navigationItemCount;n["@paging"]=function(){var t=[],e=n.currentPage-Math.floor(a/2);e<0&&(e=0);var i=n.currentPage+a;i>n.totalPages&&(i=n.totalPages),i-e>a&&(i=e+a),i-e0&&(n.hasPage=!0),this.$.page.navigation.html(t.tmpl.get("page_navigation",n)),this.$.page.navigation.find("[data-ax5grid-page-move]").on("click",function(){var t=this.getAttribute("data-ax5grid-page-move");i.call(e,t)})}else this.$.page.navigation.empty()},a=function(){var i=this.xvar.paintStartRowIndex,n=this.xvar.paintStartRowIndex+this.xvar.paintRowCount-1,a=this.xvar.dataRowCount;n>a&&(n=a),this.$.page.status.html(t.tmpl.get("page_status",{fromRowIndex:e.number(i+1,{money:!0}),toRowIndex:e.number(n,{money:!0}),totalElements:e.number(a,{money:!0}),dataRowCount:a!==this.xvar.dataRealRowCount&&e.number(this.xvar.dataRealRowCount,{money:!0})}))};t.page={navigationUpdate:n,statusUpdate:a}}(),function(){var t=ax5.ui.grid,e=ax5.util,i={vertical:function(t,e){var i=e._content_height-e._panel_height,n=e._vertical_scroller_height-e.verticalScrollBarHeight,a=i*t.top/n;return a<0?a=0:il){s=-l;var r=i[a].call(this,{top:-s},{_content_width:n._content_width,_content_height:n._content_height,_panel_width:n._panel_width,_panel_height:n._panel_height,_horizontal_scroller_width:n._horizontal_scroller_width,_vertical_scroller_height:n._vertical_scroller_height,verticalScrollBarHeight:n.verticalScrollBarHeight,horizontalScrollBarWidth:n.horizontalScrollBarWidth});t.body.scrollTo.call(this,r)}return-s},horizontal:function(e,n){var a="horizontal",o=n._content_width-n._panel_width,l=n._horizontal_scroller_width-n.horizontalScrollBarWidth,s=l*e/o;if(-s>l){s=-l;var r=i[a].call(this,{left:-s},{_content_width:n._content_width,_content_height:n._content_height,_panel_width:n._panel_width,_panel_height:n._panel_height,_horizontal_scroller_width:n._horizontal_scroller_width,_vertical_scroller_height:n._vertical_scroller_height,verticalScrollBarHeight:n.verticalScrollBarHeight,horizontalScrollBarWidth:n.horizontalScrollBarWidth});t.header.scrollTo.call(this,r),t.body.scrollTo.call(this,r)}return-s}},a={click:function(e,n,a,o){if((new Date).getTime()-t.scroller.moveout_timer<20)return!1;var l=this,s=e.offset(),r={width:n.outerWidth(),height:n.outerHeight()},d={width:e.innerWidth(),height:e.innerHeight()},c=l.$.scroller.vertical.innerHeight(),u=l.$.panel.body.height(),h=l.$.scroller.horizontal.innerWidth(),p=l.$.panel.body.width(),f=l.xvar.scrollContentHeight,m=l.xvar.scrollContentWidth,g=l.$.scroller["vertical-bar"].outerHeight(),x=l.$.scroller["horizontal-bar"].outerWidth(),v={vertical:function(e){ -var i=t.util.getMousePosition(e),n=i.clientY-s.top;return n<0?n=0:n+r.height>d.height&&(n=d.height-r.height),{top:n}},horizontal:function(e){var i=t.util.getMousePosition(e),n=i.clientX-s.left;return n<0?n=0:n+r.width>d.width&&(n=d.width-r.width),{left:n}}},b=v[a](o);n.css(b);var y=i[a].call(l,b,{_content_width:m,_content_height:f,_panel_width:p,_panel_height:u,_horizontal_scroller_width:h,_vertical_scroller_height:c,verticalScrollBarHeight:g,horizontalScrollBarWidth:x});"horizontal"===a&&t.header.scrollTo.call(l,y),t.body.scrollTo.call(l,y)},on:function(e,n,o,l){var s=this,r=n.position(),d={width:n.outerWidth(),height:n.outerHeight()},c={width:e.innerWidth(),height:e.innerHeight()},u=s.$.scroller.vertical.innerHeight(),h=s.$.panel.body.height(),p=s.$.scroller.horizontal.innerWidth(),f=s.$.panel.body.width(),m=s.xvar.scrollContentHeight,g=s.xvar.scrollContentWidth,x=s.$.scroller["vertical-bar"].outerHeight(),v=s.$.scroller["horizontal-bar"].outerWidth(),b={vertical:function(e){var i=t.util.getMousePosition(e);s.xvar.__da=i.clientY-s.xvar.mousePosition.clientY;var n=r.top+s.xvar.__da;return n<0?n=0:n+d.height>c.height&&(n=c.height-d.height),{top:n}},horizontal:function(e){var i=t.util.getMousePosition(e);s.xvar.__da=i.clientX-s.xvar.mousePosition.clientX;var n=r.left+s.xvar.__da;return n<0?n=0:n+d.width>c.width&&(n=c.width-d.width),{left:n}}};s.xvar.__da=0,jQuery(document.body).bind(t.util.ENM.mousemove+".ax5grid-"+this.instanceId,function(e){var a=b[o](e);n.css(a);var l=i[o].call(s,a,{_content_width:g,_content_height:m,_panel_width:f,_panel_height:h,_horizontal_scroller_width:p,_vertical_scroller_height:u,verticalScrollBarHeight:x,horizontalScrollBarWidth:v});"horizontal"===o&&t.header.scrollTo.call(s,l),t.body.scrollTo.call(s,l)}).bind(t.util.ENM.mouseup+".ax5grid-"+this.instanceId,function(t){a.off.call(s)}).bind("mouseleave.ax5grid-"+this.instanceId,function(t){a.off.call(s)}),jQuery(document.body).attr("unselectable","on").css("user-select","none").on("selectstart",!1)},off:function(){t.scroller.moveout_timer=(new Date).getTime(),jQuery(document.body).unbind(t.util.ENM.mousemove+".ax5grid-"+this.instanceId).unbind(t.util.ENM.mouseup+".ax5grid-"+this.instanceId).unbind("mouseleave.ax5grid-"+this.instanceId),jQuery(document.body).removeAttr("unselectable").css("user-select","auto").off("selectstart")}},o={wheel:function(e){var i=this,n=i.$.panel["body-scroll"].position(),a=i.$.panel.body.height(),o=i.$.panel.body.width(),l=i.xvar.scrollContentHeight,r=i.xvar.scrollContentWidth;if(isNaN(l)||isNaN(r))return!1;var d,c,u=!1,h=!1;return d=n.left-e.x,c=n.top-e.y,c>=0?(c=0,u=!0):c<=a-l?(c=a-l,c>=0&&(c=0),u=!0):0==e.y&&(u=!0),d>=0?(d=0,h=!0):d<=o-r?(d=o-r,d>=0&&(d=0),h=!0):0==e.x&&(h=!0),t.header.scrollTo.call(this,{left:d}),t.body.scrollTo.call(this,{left:d,top:c}),s.call(this),!u||!h},on:function(){var i=this,n=i.$.panel["body-scroll"].position(),a=i.$.panel.body.height(),l=i.$.panel.body.width(),r=i.xvar.scrollContentHeight,d=i.xvar.scrollContentWidth,c=function(e){var o,s,c=t.util.getMousePosition(e);return i.xvar.__x_da=c.clientX-i.xvar.mousePosition.clientX,i.xvar.__y_da=c.clientY-i.xvar.mousePosition.clientY,o=n.left+i.xvar.__x_da,s=n.top+i.xvar.__y_da,s>=0?s=0:s<=a-r&&(s=a-r,s>=0&&(s=0)),o>=0?o=0:o<=l-d&&(o=l-d,o>=0&&(o=0)),{left:o,top:s}};this.xvar.__x_da=0,this.xvar.__y_da=0,jQuery(document.body).bind("touchmove.ax5grid-"+this.instanceId,function(n){var a=c(n);t.header.scrollTo.call(i,{left:a.left}),t.body.scrollTo.call(i,a,"noRepaint"),s.call(i),e.stopEvent(n)}).bind("touchend.ax5grid-"+this.instanceId,function(n){var a=c(n);t.header.scrollTo.call(i,{left:a.left}),t.body.scrollTo.call(i,a),s.call(i),e.stopEvent(n),o.off.call(i)}),jQuery(document.body).attr("unselectable","on").css("user-select","none").on("selectstart",!1)},off:function(){jQuery(document.body).unbind("touchmove.ax5grid-"+this.instanceId).unbind("touchend.ax5grid-"+this.instanceId),jQuery(document.body).removeAttr("unselectable").css("user-select","auto").off("selectstart")}},l=function(){var i=this,n=this.config.scroller.trackPadding;this.$.scroller["vertical-bar"].css({width:this.config.scroller.size-(n+1),left:n/2}),this.$.scroller["horizontal-bar"].css({height:this.config.scroller.size-(n+1),top:n/2}),this.$.scroller["vertical-bar"].on(t.util.ENM.mousedown,function(e){this.xvar.mousePosition=t.util.getMousePosition(e),a.on.call(this,this.$.scroller.vertical,this.$.scroller["vertical-bar"],"vertical",e)}.bind(this)).on("dragstart",function(t){return e.stopEvent(t),!1}),this.$.scroller.vertical.on("click",function(t){"vertical"==t.target.getAttribute("data-ax5grid-scroller")&&a.click.call(this,this.$.scroller.vertical,this.$.scroller["vertical-bar"],"vertical",t)}.bind(this)),this.$.scroller["horizontal-bar"].on(t.util.ENM.mousedown,function(e){this.xvar.mousePosition=t.util.getMousePosition(e),a.on.call(this,this.$.scroller.horizontal,this.$.scroller["horizontal-bar"],"horizontal",e)}.bind(this)).on("dragstart",function(t){return e.stopEvent(t),!1}),this.$.scroller.horizontal.on("click",function(t){"horizontal"==t.target.getAttribute("data-ax5grid-scroller")&&a.click.call(this,this.$.scroller.horizontal,this.$.scroller["horizontal-bar"],"horizontal",t)}.bind(this)),this.$.container.body.on("mousewheel DOMMouseScroll",function(t){var i=t.originalEvent,n={x:0,y:0};i.detail?n.y=10*i.detail:"undefined"==typeof i.deltaY?(n.y=-i.wheelDelta,n.x=0):(n.y=i.deltaY,n.x=i.deltaX),o.wheel.call(this,n)&&e.stopEvent(t)}.bind(this)),document.addEventListener&&ax5.info.supportTouch&&this.$.container.body.on("touchstart","[data-ax5grid-panel]",function(e){i.xvar.mousePosition=t.util.getMousePosition(e),o.on.call(i)})},s=function(){var t=this.$.scroller.vertical.height(),e=this.$.scroller.horizontal.width(),i=this.$.panel.body.height(),a=this.$.panel.body.width(),o=this.xvar.scrollContentHeight,l=this.xvar.scrollContentWidth,s=i*t/o,r=a*e/l;s\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
\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
\n '},i=function(){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=function(){return"{{fromRowIndex}} - {{toRowIndex}} of {{totalElements}}{{#dataRowCount}} ({{dataRowCount}}){{/dataRowCount}}"};t.tmpl={main:e,page_navigation:i,page_status:n,get:function(e,i,n){return ax5.mustache.render(t.tmpl[e].call(this,n),i)}}}(),function(){var t=ax5.ui.grid,e=ax5.util,i=function(t,e){for(var i={rows:[]},n={rows:[]},a=0,o=t.rows.length;a0?(a.rows[e]||(a.rows[e]={cols:[]}),a.rows[e].cols=a.rows[e].cols.concat(l.cols),l.cols.length-1+c):c};l(i,0);for(var s=0,r=a.rows.length;s0?(n.rows[e]||(n.rows[e]={cols:[]}),n.rows[e].cols=n.rows[e].cols.concat(o.cols),o.cols.length-1+u):u};return o(i,0),function(t){for(var e=0,i=t.rows.length;ethis.columns.length);l++){var r=a[l].colspan||1;a[l].label||a[l].key?e.rows[i].cols.push({colspan:r,rowspan:1,colIndex:o,columnAttr:"sum",align:a[l].align,label:a[l].label,key:a[l].key,collector:a[l].collector,formatter:a[l].formatter}):e.rows[i].cols.push({colIndex:o,colspan:r,rowspan:1,label:" "}),o+=r}if(othis.columns.length);a++){var l=t[a].colspan||1;t[a].label||t[a].key?e.rows[i].cols.push({colspan:l,rowspan:1,rowIndex:0,colIndex:n,columnAttr:"default",align:t[a].align,label:t[a].label,key:t[a].key,collector:t[a].collector,formatter:t[a].formatter}):e.rows[i].cols.push({rowIndex:0,colIndex:n,colspan:l,rowspan:1,label:" "}),n+=l}if(nt&&o.push("top"),this.xvar.frozenColumnIndex>e&&o.push("left"),o.push("body"),(this.xvar.frozenColumnIndex<=e||this.xvar.frozenRowIndex<=t)&&(n=o.join("-"),o.push("scroll"),a=!0),{panelName:o.join("-"),containerPanelName:n,isScrollPanel:a}},u=function(t){var e=[],i=[].concat(t.split(/[\.\[\]]/g));return i.forEach(function(t){""!==t&&e.push('["'+t.replace(/['\"]/g,"")+'"]')}),i=null,e.join("")};t.util={divideTableByFrozenColumnIndex:i,getMousePosition:n,ENM:a,makeHeaderTable:o,makeBodyRowTable:l,makeBodyRowMap:s,makeFootSumTable:r,makeBodyGroupingTable:d,findPanelByColumnIndex:c,getRealPathForDataItem:u}}(),function(){var t,e=ax5.ui,i=ax5.util;e.addClass({className:"mediaViewer",version:"1.3.58"},function(){var n=function(){var n,a=this,o={mousedown:ax5.info.supportTouch?"touchstart":"mousedown",mousemove:ax5.info.supportTouch?"touchmove":"mousemove",mouseup:ax5.info.supportTouch?"touchend":"mouseup"},l=function(t){var e="changedTouches"in t.originalEvent?t.originalEvent.changedTouches[0]:t;return{clientX:e.clientX,clientY:e.clientY,time:(new Date).getTime()}};this.instanceId=ax5.getGuid(),this.config={clickEventName:"click",theme:"default",animateTime:250,columnKeys:{src:"src",poster:"poster",html:"html"},loading:{icon:"",text:"Now Loading"},viewer:{prevHandle:!1,nextHandle:!1,ratio:16/9},media:{prevHandle:"<",nextHandle:">",width:36,height:36,list:[]}},this.queue=[],this.openTimer=null,this.closeTimer=null,this.selectedIndex=0,this.mousePosition={},n=this.config;var s=function(){var e=jQuery.extend(!0,{id:this.id},n);try{return t.tmpl.get.call(this,"frame",e,n.columnKeys)}finally{e=null}},r=function(t,e){var o,l="",s={thumbnail:function(t){this.select(t.getAttribute("data-media-thumbnail"))},prev:function(t){this.selectedIndex>0?this.select(this.selectedIndex-1):this.select(n.media.list.length-1)},next:function(t){this.selectedIndex0){for(var t=n.media.list.length,e=0;t--;)if(n.media.list[t].selected){e=t;break}0==e&&(n.media.list[0].selected=!0);try{return e}finally{t=null,e=null}}},c=function(){var t=this.$.list.find("[data-media-thumbnail="+this.selectedIndex+"]"),e=t.position(),i=t.outerWidth(),n=this.$.list.outerWidth(),a=this.$["list-table"].position().left,o=this.$["list-table"].outerWidth(),l=0;e.left+i+a>n?(l=n-(e.left+i),a!=l&&this.$["list-table"].css({left:a=l})):e.left+a<0&&(l=e.left,l>0&&(l=0),a!=l&&this.$["list-table"].css({left:a=l})),a!=l&&a+o0&&(l=0),this.$["list-table"].css({left:l})),t=null,e=null,i=null,n=null,a=null,l=null},u={on:function(t){var e=function(e){var i=e;return"changedTouches"in e.originalEvent&&(i=e.originalEvent.changedTouches[0]),t.__dx=i.clientX-t.clientX,t.__dy=i.clientY-t.clientY,t.__time=(new Date).getTime(),Math.abs(t.__dx)>Math.abs(t.__dy)?{left:t.__dx}:{top:t.__dy}},l=this.$.viewer.width();jQuery(document.body).bind(o.mousemove+".ax5media-viewer-"+this.instanceId,function(t){var o=e(t);if("left"in o){if(a.$["viewer-holder"].css(o),Math.abs(a.mousePosition.__dx)>l/3){var s=0;a.mousePosition.__dx>0?s=a.selectedIndex>0?a.selectedIndex-1:n.media.list.length-1:a.selectedIndex0&&this.attach(n.target)},this.attach=function(t,e){return t||console.log(ax5.info.getError("ax5mediaViewer","401","setConfig")),"undefined"!=typeof e&&this.setConfig(e,!1),this.target=jQuery(t),this.target.html(s.call(this)),this.$={root:this.target.find("[data-ax5-ui-media-viewer]"),"viewer-holder":this.target.find('[data-media-viewer-els="viewer-holder"]'),viewer:this.target.find('[data-media-viewer-els="viewer"]'),"viewer-loading":this.target.find('[data-media-viewer-els="viewer-loading"]'),"list-holder":this.target.find('[data-media-viewer-els="media-list-holder"]'),"list-prev-handle":this.target.find('[data-media-viewer-els="media-list-prev-handle"]'),list:this.target.find('[data-media-viewer-els="media-list"]'),"list-table":this.target.find('[data-media-viewer-els="media-list-table"]'),"list-next-handle":this.target.find('[data-media-viewer-els="media-list-next-handle"]')},this.align(),jQuery(window).unbind("resize.ax5media-viewer-"+this.id).bind("resize.ax5media-viewer-"+this.id,function(){this.align(),c.call(this)}.bind(this)),this.target.unbind("click").bind("click",function(t){t=t||window.event,r.call(this,t),i.stopEvent(t)}.bind(this)),this.$.viewer.unbind(o.mousedown).bind(o.mousedown,function(t){this.mousePosition=l(t),u.on.call(this,this.mousePosition)}.bind(this)).unbind("dragstart").bind("dragstart",function(t){return i.stopEvent(t),!1}),this.select(d.call(this)),this},this.align=function(){if(this.$["viewer-holder"].css({height:this.$.viewer.width()/n.viewer.ratio}),this.$.viewer.css({height:this.$.viewer.width()/n.viewer.ratio}),"image"==this.$.viewer.data("media-type")){var t=this.$.viewer.find("img");t.css({width:this.$.viewer.height()*this.$.viewer.data("img-ratio"),height:this.$.viewer.height()}),setTimeout(function(t){t.css({left:(this.$.viewer.width()-t.width())/2})}.bind(this,t),1)}else"video"==this.$.viewer.data("media-type")&&this.$.viewer.find("iframe").css({width:this.$.viewer.height()*this.$.viewer.data("img-ratio"),height:this.$.viewer.height()});this.$["viewer-loading"].css({height:this.$.viewer.height()});var e="%"==i.right(n.media.width,1)?i.number(n.media.width)/100*this.$.viewer.width():i.number(n.media.width),a="%"==i.right(n.media.height,1)?i.number(n.media.height)/100*this.$.viewer.width():i.number(n.media.height);return e=Math.floor(e),a=Math.floor(a),this.$["list-prev-handle"].css({width:1.5*e}),this.$["list-next-handle"].css({width:1.5*e}),this.$.list.css({height:a}),this.$["list-table"].find("[data-media-thumbnail]").css({width:e,height:a}),this.$["list-table"].find("[data-media-thumbnail-video]").css({width:e,height:a}),this},this.select=function(){var t={image:function(t,e){a.$["viewer-loading"].show();var i=[this.$.viewer.width(),this.$.viewer.height()],o=new Image;return o.src=t.image[n.columnKeys.src],o.onload=function(){a.$["viewer-loading"].fadeOut();var t=i[1],n=t*o.width/o.height;e(o,Math.floor(n),t)},o},video:function(t,e){a.$["viewer-loading"].show();var i=[this.$.viewer.width(),this.$.viewer.height()],o=jQuery(t.video[n.columnKeys.html]);e(o,i[0],i[1]),a.$["viewer-loading"].fadeOut()}},e={image:function(t,e,i){t.width=e,t.height=i;var n=$(t);this.$.viewer.html(n),n.css({left:(this.$.viewer.width()-e)/2}),this.$.viewer.data("media-type","image"),this.$.viewer.data("img-ratio",e/i)},video:function(t,e,i){t.css({width:e,height:i}),this.$.viewer.html(t),this.$.viewer.data("media-type","video"),this.$.viewer.data("img-ratio",e/i)}},i=function(t){this.$.list.find("[data-media-thumbnail]").removeClass("selected"),this.$.list.find("[data-media-thumbnail="+t+"]").addClass("selected"),c.call(this)};return function(a){if("undefined"==typeof a)return this;this.selectedIndex=Number(a);var o=n.media.list[a];i.call(this,a);for(var l in t)if(o[l]){t[l].call(this,o,e[l].bind(this));break}return this}}(),this.setMediaList=function(t){return n.media.list=[].concat(t),this.attach(n.target),this},this.main=function(){e.mediaViewer_instance=e.mediaViewer_instance||[],e.mediaViewer_instance.push(this),arguments&&i.isObject(arguments[0])?this.setConfig(arguments[0]):this.init()}.apply(this,arguments)};return n}()),t=ax5.ui.mediaViewer}(),function(){var t=ax5.ui.mediaViewer,e=function(t){return'\n
\n
\n
\n
\n
\n
\n
\n {{{loading.icon}}}\n {{{loading.text}}}\n
\n
\n
\n {{#media}}\n
\n
{{{prevHandle}}}
\n
\n
\n {{#list}}\n
\n {{#image}}\n
\n \n
\n {{/image}}\n {{#video}}\n
{{#'+t.poster+'}}>{{/'+t.poster+"}}{{^"+t.poster+'}}{{{media.'+t.poster+"}}}{{/"+t.poster+'}}
\n {{/video}}\n
\n {{/list}}\n
\n
\n
{{{nextHandle}}}
\n
\n {{/media}}\n
\n '};t.tmpl={frame:e,get:function(e,i,n){return ax5.mustache.render(t.tmpl[e].call(this,n),i)}}}(),function(){var t=ax5.ui,e=ax5.util,i=void 0;t.addClass({className:"uploader",version:"1.3.58"},function(){var n=function(){var n=this,a=void 0;this.instanceId=ax5.getGuid(),this.config={clickEventName:"click",theme:"default",lang:{upload:"Upload",abort:"Abort"},uploadedBox:{columnKeys:{name:"name",type:"type",size:"size",uploadedName:"uploadedName",uploadedPath:"uploadedPath",downloadPath:"downloadPath",previewPath:"previewPath",thumbnail:"thumbnail"}},animateTime:100,accept:"*/*",multiple:!1,manualUpload:!1,progressBox:!0},this.defaultBtns={upload:{label:this.config.lang.upload,theme:"btn-primary"},abort:{label:this.config.lang.abort,theme:this.config.theme}},this.uploadedFiles=[],this.$target=null,this.$inputContainer=null,this.$inputFile=null,this.$inputFileForm=null,this.$fileSelector=null,this.$dropZone=null,this.$uploadedBox=null,this.__uploading=!1,this.selectedFiles=[],this.selectedFilesTotal=0,this.__loaded=0,a=this.config;var o=function(t){return a.onStateChanged?a.onStateChanged.call(t,t):this.onStateChanged&&this.onStateChanged.call(t,t),t=null,!0},l=function(t){var i=void 0;return ax5.info.supportFileApi&&("dataTransfer"in t?i=t.dataTransfer.files:"target"in t?i=t.target.files:t&&(i=t)),!!i&&(length in i?this.selectedFiles=e.toArray(i):this.selectedFiles=[i],a.progressBox&&c(),void(a.manualUpload||this.send()))}.bind(this),s=function(){this.$fileSelector.off("click.ax5uploader").on("click.ax5uploader",function(){this.$inputFile.trigger("click")}.bind(this)),this.$inputFile.off("change.ax5uploader").on("change.ax5uploader",function(t){l(t)}.bind(this)),function(){if(!this.$dropZone||!this.$dropZone.get(0))return!1;this.$dropZone.on("click",function(t){var e=ax5.util.findParentNode(t.target,function(t){if(t.hasAttribute("data-uploaded-item-cell"))return!0});e||n.$inputFile.trigger("click")}),this.$dropZone.get(0).addEventListener("dragover",function(t){e.stopEvent(t),n.$dropZone.addClass("dragover")},!1),this.$dropZone.get(0).addEventListener("dragleave",function(t){e.stopEvent(t),n.$dropZone.removeClass("dragover")},!1),this.$dropZone.get(0).addEventListener("drop",function(t){e.stopEvent(t),n.$dropZone.removeClass("dragover"),l(t||window.event)},!1)}.call(this)},r=function(){},d=function(t){var e=function(){var e=jQuery(window),i=jQuery(document.body),n={},o=6,l={},s={},r=void 0;n=this.$progressBox.parent().get(0)==this.$target.get(0)?this.$fileSelector.position():this.$fileSelector.offset(),l={width:this.$fileSelector.outerWidth(),height:this.$fileSelector.outerHeight()},s={winWidth:Math.max(e.width(),i.width()),winHeight:Math.max(e.height(),i.height()),width:this.$progressBox.outerWidth(),height:this.$progressBox.outerHeight()},a.direction&&""!==a.direction&&"auto"!==a.direction?r=a.direction:(r="top",n.top-s.height-o<0?r="top":n.top+l.height+s.height+o>s.winHeight&&(r="bottom")),t&&this.$progressBox.addClass("direction-"+r);var d=function(){var t={left:0,top:0};switch(r){case"top":t.left=n.left+l.width/2-s.width/2,t.top=n.top+l.height+o;break;case"bottom":t.left=n.left+l.width/2-s.width/2,t.top=n.top-s.height-o;break;case"left":t.left=n.left+l.width+o,t.top=n.top-s.height/2+l.height/2;break;case"right":t.left=n.left-s.width-o,t.top=n.top-s.height/2+l.height/2}return t}();(function(){"top"!=r&&"bottom"!=r||(d.left<0?(d.left=o,this.$progressBoxArrow.css({left:n.left+l.width/2-d.left})):d.left+s.width>s.winWidth&&(d.left=s.winWidth-s.width-o,this.$progressBoxArrow.css({left:n.left+l.width/2-d.left})))}).call(this),this.$progressBox.css(d)};this.$progressBox.css({top:-999}),t&&(function(){return a.viewport?jQuery(a.viewport.selector):this.$target}.call(this).append(this.$progressBox),this.$progressBox.off("click.ax5uploader").on("click.ax5uploader","button",function(t){var e=t.target.getAttribute("data-pregressbox-btn"),i={upload:function(){this.send()},abort:function(){this.abort()}};i[e]&&i[e].call(this)}.bind(this))),setTimeout(function(){e.call(this)}.bind(this))},c=function(){this.$progressBox.removeClass("destroy"),this.$progressUpload.removeAttr("disabled"),this.$progressAbort.removeAttr("disabled"),d.call(this,"append"),o.call(this,{self:this,state:"open"})}.bind(this),u=function(){this.$progressBox.addClass("destroy"),setTimeout(function(){this.$progressBox.remove()}.bind(this),a.animateTime)}.bind(this),h=function(){var t={html5:function(){var t=this.selectedFiles.shift();if(!t)return m(),this;var i=new FormData;this.$target.find("input").each(function(){i.append(this.name,this.value)}),i.append(a.form.fileName,t),this.xhr=new XMLHttpRequest,this.xhr.open("post",a.form.action,!0),this.xhr.onload=function(t){var i=t.target.response;try{"string"==typeof i&&(i=e.parseJson(i))}catch(t){return!1}return a.debug&&console.log(i),i.error?(a.debug&&console.log(i.error),!1):(f(i),void n.send())},this.xhr.upload.onprogress=function(t){p(t),e.isFunction(a.onprogress)&&a.onprogress.call({loaded:t.loaded,total:t.total},t)},this.xhr.send(i)},form:function(){var t=$('');$(document.body).append(t)}};if(this.__uploading===!1){var i=0;this.selectedFiles.forEach(function(t){i+=t.size}),this.selectedFilesTotal=i,this.__loaded=0,this.__uploading=!0,this.$progressUpload.attr("disabled","disabled"),this.$progressAbort.removeAttr("disabled")}t[ax5.info.supportFileApi?"html5":"form"].call(this)}.bind(this),p=function(t){this.__loaded+=t.loaded,this.$progressBar.css({width:e.number(this.__loaded/this.selectedFilesTotal*100,{round:2})+"%"}),t.lengthComputable&&t.loaded>=t.total}.bind(this),f=function(t){a.debug&&console.log(t),this.uploadedFiles.push(t),x(),e.isFunction(a.onuploaded)&&a.onuploaded.call({self:this},t)}.bind(this),m=function(){this.__uploading=!1,this.$progressUpload.removeAttr("disabled"),this.$progressAbort.attr("disabled","disabled"),a.progressBox&&u(),e.isFunction(a.onuploadComplete)&&a.onuploadComplete.call({self:this})}.bind(this),g=function(){var t={html5:function(){this.xhr&&this.xhr.abort()},form:function(){}};this.__uploading=!1,this.$progressUpload.removeAttr("disabled"),this.$progressAbort.attr("disabled","disabled"),t[ax5.info.supportFileApi?"html5":"form"].call(this),a.progressBox&&u(),this.$inputFile.get(0).value="",console.log("cancelUpload")}.bind(this),x=function(){return null===this.$uploadedBox?this:void this.$uploadedBox.html(i.tmpl.get("upoadedBox",{uploadedFiles:this.uploadedFiles,icon:a.uploadedBox.icon,lang:a.uploadedBox.lang},a.uploadedBox.columnKeys))}.bind(this);this.init=function(t){return a=jQuery.extend(!0,{},a,t),a.target?(this.$target=jQuery(a.target),a.dropZone&&(this.$dropZone=jQuery(a.dropZone),this.$dropZone.attr("data-ax5uploader-dropzone",this.instanceId)),a.uploadedBox&&a.uploadedBox.target&&(this.$uploadedBox=jQuery(a.uploadedBox.target), -this.$uploadedBox.on("click","[data-uploaded-item-cell]",function(){var t=jQuery(this),e=t.attr("data-uploaded-item-cell"),i=Number(t.parents("[data-ax5uploader-uploaded-item]").attr("data-ax5uploader-uploaded-item")),o={};a.uploadedBox&&a.uploadedBox.onclick&&(o={self:n,cellType:e,uploadedFiles:n.uploadedFiles,fileIndex:i},a.uploadedBox.onclick.call(o,o)),t=null,e=null,i=null,o=null})),function(t){e.isObject(t)&&!t.error&&(a=jQuery.extend(!0,a,t))}.call(this,e.parseJson(this.$target.attr("data-ax5uploader-config"),!0)),this.$fileSelector=this.$target.find('[data-ax5uploader-button="selector"]'),0===this.$fileSelector.length?(console.log(ax5.info.getError("ax5uploader","402","can not find file selector")),this):(this.$inputFile=jQuery(i.tmpl.get.call(this,"inputFile",{instanceId:this.instanceId,multiple:a.multiple,accept:a.accept})),ax5.info.supportFileApi?jQuery(document.body).append(this.$inputFile):(this.$inputFileForm=jQuery(i.tmpl.get.call(this,"inputFileForm",{instanceId:this.instanceId})),this.$inputFileForm.append(this.$inputFile),jQuery(document.body).append(this.$inputFileForm)),a.btns=jQuery.extend({},this.defaultBtns,a.btns),this.$progressBox=jQuery(i.tmpl.get.call(this,"progressBox",{instanceId:this.instanceId,btns:a.btns})),this.$progressBar=this.$progressBox.find('[role="progressbar"]'),this.$progressBoxArrow=this.$progressBox.find(".ax-progressbox-arrow"),this.$progressUpload=this.$progressBox.find('[data-pregressbox-btn="upload"]'),this.$progressAbort=this.$progressBox.find('[data-pregressbox-btn="abort"]'),r.call(this),s.call(this),this)):(console.log(ax5.info.getError("ax5uploader","401","init")),this)},this.send=function(){return function(){return h(),this}}(),this.abort=function(){return function(){return g(),this}}(),this.setUploadedFiles=function(t){return e.isArray(t)&&(this.uploadedFiles=t),x(),this},this.removeFile=function(t){return isNaN(Number(t))||this.uploadedFiles.splice(t,1),x(),this},this.removeFileAll=function(){return this.uploadedFiles=[],x(),this},this.main=function(){t.uploader_instance=t.uploader_instance||[],t.uploader_instance.push(this),arguments&&e.isObject(arguments[0])&&this.setConfig(arguments[0])}.apply(this,arguments)};return n}()),i=ax5.ui.uploader}(),function(){var t=ax5.ui.uploader,e=function(t){return"\n "},i=function(t){return''},n=function(t){return'
'},a=function(t){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'},o=function(t){return'\n{{#uploadedFiles}}
\n
\n
{{{icon.download}}}
\n
{{'+t.name+'}}
\n
({{#@fn_get_byte}}{{'+t.size+'}}{{/@fn_get_byte}})
\n
{{{icon.delete}}}
\n
\n
{{/uploadedFiles}}\n{{^uploadedFiles}}\n{{{lang.emptyList}}}\n{{/uploadedFiles}}\n'};t.tmpl={uploadProgress:e,inputFile:i,inputFileForm:n,progressBox:a,upoadedBox:o,get:function(e,i,n){return i["@fn_get_byte"]=function(){return function(t,e){return ax5.util.number(e(t),{round:2,"byte":!0})}},ax5.mustache.render(t.tmpl[e].call(this,n),i)}}}(),function(){var t,e=ax5.ui,i=ax5.util;e.addClass({className:"combobox",version:"1.3.58"},function(){var e=function(){var e,n=this;this.instanceId=ax5.getGuid(),this.config={theme:"default",animateTime:250,removeIcon:"X",lang:{noSelected:"",noOptions:"no options",loading:"now loading.."},columnKeys:{optionValue:"value",optionText:"text",optionSelected:"selected"}},this.queue=[],this.activecomboboxOptionGroup=null,this.activecomboboxQueueIndex=-1,this.openTimer=null,this.closeTimer=null,this.waitOptionsCallback=null,this.keyUpTimer=null,e=this.config;var a=jQuery(window),o=function(t,e){return t&&t.onStateChanged?t.onStateChanged.call(e,e):this.onStateChanged&&this.onStateChanged.call(e,e),"changeValue"==e.state&&(t&&t.onChange?t.onChange.call(e,e):this.onChange&&this.onChange.call(e,e)),t=null,e=null,!0},l=function(){for(var t,e=this.queue.length;e--;){var n=this.queue[e];if(n.$display&&(t=Math.max(n.$select.outerWidth(),i.number(n.minWidth)),n.$display.css({"min-width":t}),n.reset&&n.$display.find(".addon-icon-reset").css({"line-height":this.queue[e].$display.height()+"px"}),n.multiple)){var a=function(){return i.number(n.$display.css("border-top-width"))+i.number(n.$display.css("border-bottom-width"))}.call(this);n.$target.height(""),n.$display.height("");var o=n.$displayTable.outerHeight();Math.abs(o-n.$target.height())>a&&(n.$target.css({height:o+a+4}),n.$display.css({height:o+a+4}))}}return e=null,t=null,this},s=function(t){if(!this.activecomboboxOptionGroup)return this;var e,i=this.queue[this.activecomboboxQueueIndex],n={},o=0,l={},s={};t&&jQuery(document.body).append(this.activecomboboxOptionGroup),n=i.$target.offset(),l={width:i.$target.outerWidth(),height:i.$target.outerHeight()},s={winWidth:Math.max(a.width(),jQuery(document.body).width()),winHeight:Math.max(a.height(),jQuery(document.body).height()),width:this.activecomboboxOptionGroup.outerWidth(),height:this.activecomboboxOptionGroup.outerHeight()},i.direction&&""!==i.direction&&"auto"!==i.direction?e=i.direction:(e="top",n.top-s.height-o<0?e="top":n.top+l.height+s.height+o>s.winHeight&&(e="bottom")),t&&this.activecomboboxOptionGroup.addClass("direction-"+e),this.activecomboboxOptionGroup.css(function(){if("top"==e){if(n.top+l.height+s.height+o>s.winHeight){var t=n.top+l.height/2-s.height/2;return t+s.height+o>s.winHeight&&(t=0),t<0&&(t=0),{left:n.left,top:t,width:l.width}}return{left:n.left,top:n.top+l.height+1,width:l.width}}if("bottom"==e)return{left:n.left,top:n.top-s.height-1,width:l.width}}.call(this))},r=function(t,e){if(!this.activecomboboxOptionGroup)return this;var n=this.queue[this.activecomboboxQueueIndex],a="display";return(e=i.findParentNode(t.target,function(t){return t.getAttribute("data-option-value")?(a="optionItem",!0):n.$target.get(0)==t?(a="display",!0):void 0}))?("optionItem"===a&&(_.call(this,n.id,{index:{gindex:e.getAttribute("data-option-group-index"),index:e.getAttribute("data-option-index")}},void 0,!0),l.call(this),s.call(this),n.multiple||this.close()),this):(this.close(),this)},d=function(e){var i=this.queue[e],n={};return n.id=i.id,n.theme=i.theme,n.size="ax5combobox-option-group-"+i.size,n.multiple=i.multiple,n.lang=i.lang,n.options=i.options,n.selected=i.selected,n.hasSelected=n.selected&&n.selected.length>0,n.removeIcon=i.removeIcon,t.tmpl.get.call(this,"label",n,i.columnKeys)},c=function(t){var e=this.queue[t];e.$displayLabel.find("[data-ax5combobox-selected-label]").remove(),e.$displayLabelInput.before(d.call(this,t))},u=function(t){return this.queue[t].disabled?this:(this.queue[t].$displayLabel.trigger("focus"),void this.queue[t].$displayLabelInput.focus())},h=function(t){this.queue[t].$displayLabelInput.val("")},p=function(t){this.queue[t].$displayLabel.trigger("blur"),this.queue[t].$displayLabelInput.trigger("blur")},f=function(e,n){this.queue[e].waitOptions=!0,this.activecomboboxOptionGroup.find('[data-els="content"]').html(jQuery(t.tmpl.get.call(this,"option",this.queue[e],this.queue[e].columnKeys))),this.queue[e].onSearch.call({self:this,item:this.queue[e],searchWord:n},function(e){var n={},a=this.queue[this.activecomboboxQueueIndex];return!!a&&(function(t,e){var n={};e.options.forEach(function(e,i){e["@index"]=i,n[e[t.columnKeys.optionValue]]=e}),i.isArray(t.selected)&&t.selected.forEach(function(i){n[i[t.columnKeys.optionValue]]&&(e.options[n[i[t.columnKeys.optionValue]]["@index"]][t.columnKeys.optionSelected]=!0)})}(a,e),a.options=v.call(this,this.activecomboboxQueueIndex,e.options),l.call(this),n.id=a.id,n.theme=a.theme,n.size="ax5combobox-option-group-"+a.size,n.multiple=a.multiple,n.lang=a.lang,n.options=a.options,void this.activecomboboxOptionGroup.find('[data-els="content"]').html(jQuery(t.tmpl.get.call(this,"options",n,a.columnKeys))))}.bind(this))},m=function(t,e){if(this.activecomboboxQueueIndex==-1)return this;var i,n=[],a=-1,o=this.queue[t].indexedOptions.length-1;if(""!=e){var l=/[\{\}\[\]\/?.,;:|\)*~`!^\-_+<>@\#$%&\\\=\(\'\"]/gi;if(e=e.replace(l,""),this.queue[t].onSearch){f.call(this,t,e);try{return n}finally{n=null,a=null,o=null,i=null}}for(;o-a++;){if(i=this.queue[t].indexedOptions[a],(""+i.text).toLowerCase()==e.toLowerCase()){n=[{"@findex":i["@findex"],optionsSort:0}];break}var s=(""+i.text).toLowerCase().search(e.toLowerCase());if(s>-1&&(n.push({"@findex":i["@findex"],optionsSort:s}),n.length>2))break;s=null}n.sort(function(t,e){return t.optionsSort-e.optionsSort})}n&&n.length>0?x.call(this,t,void 0,n[0]["@findex"]):g.call(this,t);try{return n}finally{n=null,a=null,o=null,i=null}},g=function(t){this.activecomboboxOptionGroup&&this.activecomboboxOptionGroup.find("[data-option-focus-index]").removeClass("hover").removeAttr("data-option-selected"),this.queue[t].optionFocusIndex=-1},x=function(t,e,i){var n,a,o,l,s=this.queue[t];if(this.activecomboboxOptionGroup&&s.options&&s.options.length>0){if("undefined"!=typeof i?n=i:(a=s.optionFocusIndex==-1?s.optionSelectedIndex||-1:s.optionFocusIndex,a==-1?n=0:(n=a+e,n<0?n=0:n>s.optionItemLength-1&&(n=s.optionItemLength-1))),s.optionFocusIndex=n,s.options[n]&&s.options[n].hide){if("undefined"==typeof e)return this;for(;s.options[n].hide;){if(n+=e,n<0){n=0;break}if(n>s.optionItemLength-1){n=s.optionItemLength-1;break}}}if("undefined"!=typeof n&&(this.activecomboboxOptionGroup.find("[data-option-focus-index]").removeClass("hover"),o=this.activecomboboxOptionGroup.find('[data-option-focus-index="'+n+'"]').addClass("hover"),l=this.activecomboboxOptionGroup.find('[data-els="content"]'),o.get(0))){var r=o.outerHeight(),d=l.innerHeight(),c=l.scrollTop(),u=o.position().top+l.scrollTop();d+cu&&l.scrollTop(u),"undefined"!=typeof e&&s.$displayLabelInput.val(s.options[n].text)}}},v=function(){var t=function(t,e){e?this.queue[t].selected.push(jQuery.extend({},e)):this.queue[t].selected=[]};return function(e,a){var o,l,s,r=this.queue[e],d=0;return t.call(this,e,!1),a?(r.options=a,r.indexedOptions=[],o=[],o.push(''),r.options.forEach(function(i,a){i.optgroup?(i["@gindex"]=a,i.options.forEach(function(i,l){i["@index"]=l,i["@findex"]=d,o.push('"),i[r.columnKeys.optionSelected]&&t.call(n,e,i),r.indexedOptions.push({"@gindex":a,"@index":l,"@findex":d,value:i[r.columnKeys.optionValue],text:i[r.columnKeys.optionText]}),d++})):(i["@index"]=a,i["@findex"]=d,o.push('"),i[r.columnKeys.optionSelected]&&t.call(n,e,i),r.indexedOptions.push({"@index":a,"@findex":d,value:i[r.columnKeys.optionValue],text:i[r.columnKeys.optionText]}),d++)}),r.optionItemLength=d,r.$select.html(o.join(""))):(r.$select.get(0).options&&r.$select.get(0).options.length&&(r.$select.get(0).options[0].selected=!1),l=i.toArray(r.$select.get(0).options),s=[],l.forEach(function(i,a){var o={};o[r.columnKeys.optionValue]=i.value,o[r.columnKeys.optionText]=i.text,o[r.columnKeys.optionSelected]=i.selected,o["@index"]=a,o["@findex"]=d,i.selected&&t.call(n,e,o),s.push(o),d++,o=null}),r.options=s,r.indexedOptions=s,r.$select.prepend(''),r.$select.get(0).options[0].selected=!0),o=null,l=null,s=null,r.options}}(),b=function(t){return t instanceof jQuery?t=t.data("data-ax5combobox-id"):i.isString(t)||(t=jQuery(t).data("data-ax5combobox-id")),i.isString(t)?i.search(this.queue,function(){return this.id==t}):void console.log(ax5.info.getError("ax5combobox","402","getQueIdx"))},y=function(t,e,i){return"undefined"==typeof i?!t.multiple||!e:i},w=function(t){this.queue[t].options.forEach(function(t){t.optgroup?t.options.forEach(function(t){t.selected=!1}):t.selected=!1})},_=function(){var t={index:function(t,e,a,o){var l=this.queue[t];i.isString(e.index.gindex)?"undefined"!=typeof l.options[e.index.gindex]&&(l.options[e.index.gindex].options[e.index.index][l.columnKeys.optionSelected]=y(l,l.options[e.index.gindex].options[e.index.index][l.columnKeys.optionSelected],a),n.activecomboboxOptionGroup&&n.activecomboboxOptionGroup.find('[data-option-group-index="'+e.index.gindex+'"][data-option-index="'+e.index.index+'"]').attr("data-option-Selected",l.options[e.index.gindex].options[e.index.index][l.columnKeys.optionSelected].toString())):"undefined"!=typeof l.options[e.index.index]&&(l.options[e.index.index][l.columnKeys.optionSelected]=y(l,l.options[e.index.index][l.columnKeys.optionSelected],a),n.activecomboboxOptionGroup&&n.activecomboboxOptionGroup.find('[data-option-index="'+e.index.index+'"]').attr("data-option-Selected",l.options[e.index.index][l.columnKeys.optionSelected].toString())),"undefined"!=typeof o&&"justSetValue"===o||(v.call(this,t,l.options),s.call(this))},arr:function(e,a,o,l){a.forEach(function(a){if(i.isString(a)||i.isNumber(a))t.text.call(n,e,a,o,"justSetValue");else for(var l in t)if(a[l]){t[l].call(n,e,a,o,"justSetValue");break}}),v.call(this,e,this.queue[e].options),s.call(this)},value:function(t,e,n,a){var o,l=this.queue[t],r=i.search(l.options,function(){return this[l.columnKeys.optionValue]==e[l.columnKeys.optionValue]});r>-1?l.options[r][l.columnKeys.optionSelected]=y(l,l.options[r][l.columnKeys.optionSelected],n):(r=l.options.length,o={"@index":r,hide:!0,addedOption:!0},o[l.columnKeys.optionValue]=e,o[l.columnKeys.optionText]=e,l.options.push(o),l.options[r][l.columnKeys.optionSelected]=y(l,l.options[r][l.columnKeys.optionSelected],n)),"undefined"!=typeof a&&"justSetValue"===a||(v.call(this,t,this.queue[t].options),s.call(this))},text:function(t,e,n,a){var o,l=this.queue[t],r=i.search(l.options,function(){return this[l.columnKeys.optionText]==e});r>-1?l.options[r][l.columnKeys.optionSelected]=y(l,l.options[r][l.columnKeys.optionSelected],n):(r=l.options.length,o={"@index":r,hide:!0,addedOption:!0},o[l.columnKeys.optionValue]=e,o[l.columnKeys.optionText]=e,l.options.push(o),l.options[r][l.columnKeys.optionSelected]=y(l,l.options[r][l.columnKeys.optionSelected],n)),"undefined"!=typeof a&&"justSetValue"===a||(v.call(this,t,this.queue[t].options),s.call(this))},clear:function(t){w.call(this,t),v.call(this,t,this.queue[t].options),g.call(this,t),this.activecomboboxOptionGroup&&this.activecomboboxOptionGroup.find("[data-option-index]").attr("data-option-Selected","false"),this.queue[t].optionSelectedIndex=-1}};return function(e,n,a,l){var s=i.isNumber(e)?e:b.call(this,e);if(s===-1)return void console.log(ax5.info.getError("ax5combobox","402","val"));if("undefined"==typeof n)throw"error not found value";if(i.isArray(n))t.clear.call(this,s),t.arr.call(this,s,this.queue[s].multiple||0==n.length?n:[n[n.length-1]],a);else if(i.isString(n)||i.isNumber(n))"undefined"==typeof n||null===n||this.queue[s].multiple||w.call(this,s),t.text.call(this,s,n,a,"justSetValue");else if(null===n)t.clear.call(this,s);else{this.queue[s].multiple||w.call(this,s);for(var r in t)if(n[r]){t[r].call(this,s,n,a,"justSetValue");break}}return v.call(this,s,this.queue[s].options),c.call(this,s),u.call(this,s),"undefined"!=typeof n&&l&&!l.noStateChange&&o.call(this,this.queue[s],{self:this,item:this.queue[s],state:"changeValue",value:this.queue[s].selected}),e=null,this}}();this.init=function(){this.onStateChanged=e.onStateChanged,this.onChange=e.onChange,jQuery(window).bind("resize.ax5combobox-display-"+this.instanceId,function(){l.call(this)}.bind(this))},this.bind=function(a){var o,r=function(){var e=i.debounce(function(t){return this.activecomboboxQueueIndex==-1?this:void m.call(n,t,this.queue[t].$displayLabelInput.val())},150),o=function(t){h.call(this,t)},r={click:function(t,e){var a,o=i.findParentNode(e.target,function(t){return t.getAttribute("data-ax5combobox-remove")?(a="optionItemRemove",!0):t.getAttribute("data-selected-clear")?(a="clear",!0):void 0});if(o){if("optionItemRemove"===a){var r=o.getAttribute("data-ax5combobox-remove-index"),d=this.queue[t].selected[r];return _.call(this,t,{index:{gindex:d["@gindex"],index:d["@index"]}},!1,!0),l.call(this),s.call(this),u.call(this,t),i.stopEvent(e),this}"clear"===a&&(_.call(this,t,{clear:!0}),l.call(this),s.call(this),u.call(this,t))}else n.activecomboboxQueueIndex==t?this.queue[t].optionFocusIndex==-1&&n.close():(n.open(t),u.call(this,t))},keyUp:function(t,a){if(a.which==ax5.info.eventKeys.ESC&&n.activecomboboxQueueIndex===-1)return i.stopEvent(a),this;n.activecomboboxQueueIndex!=t&&(n.open(t),i.stopEvent(a));var o={40:"KEY_DOWN",38:"KEY_UP"};if(!o[a.which])if(a.which==ax5.info.eventKeys.BACKSPACE&&""==this.queue[t].$displayLabelInput.val()){if(this.queue[t].selected.length>0){var r=this.queue[t].selected[this.queue[t].selected.length-1];_.call(this,t,{index:{gindex:r["@gindex"],index:r["@index"]}},!1,!0)}l.call(this),s.call(this),i.stopEvent(a)}else e.call(this,t)},keyDown:function(t,e){e.which==ax5.info.eventKeys.ESC?(h.call(this,t),this.close(),i.stopEvent(e)):e.which==ax5.info.eventKeys.RETURN?(_.call(this,a.id,{index:{gindex:a.indexedOptions[a.optionFocusIndex]["@gindex"],index:a.indexedOptions[a.optionFocusIndex]["@index"]}},void 0,!0),h.call(this,t),l.call(this),this.close(),i.stopEvent(e)):e.which==ax5.info.eventKeys.DOWN?(x.call(this,t,1),i.stopEvent(e)):e.which==ax5.info.eventKeys.UP&&(x.call(this,t,-1),i.stopEvent(e))},focus:function(t,e){},blur:function(t,e){o.call(this,t),i.stopEvent(e)},selectChange:function(t,e){_.call(this,t,{value:this.queue[t].$select.val()},!0)}};return function(e){var i=this.queue[e],n={};return i.selected=[],i.$display?(i.$displayLabel.html(d.call(this,e)),i.options=v.call(this,e,i.options)):(n.instanceId=this.instanceId,n.id=i.id,n.name=i.name,n.theme=i.theme,n.tabIndex=i.tabIndex,n.multiple=i.multiple,n.reset=i.reset,n.label=d.call(this,e),n.formSize=function(){return i.size?"input-"+i.size:""}(),i.$display=jQuery(t.tmpl.get.call(this,"comboboxDisplay",n,i.columnKeys)),i.$displayTable=i.$display.find('[data-els="display-table"]'),i.$displayLabel=i.$display.find('[data-ax5combobox-display="label"]'),i.$displayLabelInput=i.$display.find('[data-ax5combobox-display="input"]'),i.$target.find("select").get(0)?(i.$select=i.$target.find("select"),i.$select.attr("tabindex","-1").attr("class","form-control "+n.formSize),n.name&&i.$select.attr("name","name"),n.multiple&&i.$select.attr("multiple","multiple")):(i.$select=jQuery(t.tmpl.get.call(this,"formSelect",n,i.columnKeys)),i.$target.append(i.$select)),i.$target.append(i.$display),i.options=v.call(this,e,i.options)),l.call(this),i.$display.unbind("click.ax5combobox").bind("click.ax5combobox",r.click.bind(this,e)),i.$displayLabelInput.unbind("focus.ax5combobox").bind("focus.ax5combobox",r.focus.bind(this,e)).unbind("blur.ax5combobox").bind("blur.ax5combobox",r.blur.bind(this,e)).unbind("keyup.ax5combobox").bind("keyup.ax5combobox",r.keyUp.bind(this,e)).unbind("keydown.ax5combobox").bind("keydown.ax5combobox",r.keyDown.bind(this,e)),i.$select.unbind("change.ax5combobox").bind("change.ax5combobox",r.selectChange.bind(this,e)),n=null,i=null,e=null,this}}(),c={};return a=jQuery.extend(!0,c,e,a),a.target?(a.$target=jQuery(a.target),a.id||(a.id=a.$target.data("data-ax5combobox-id")),a.id||(a.id="ax5combobox-"+ax5.getGuid(),a.$target.data("data-ax5combobox-id",a.id)),a.name=a.$target.attr("data-ax5combobox"),a.options&&(a.options=JSON.parse(JSON.stringify(a.options))),function(t){i.isObject(t)&&!t.error&&(a=jQuery.extend(!0,a,t))}(i.parseJson(a.$target.attr("data-ax5combobox-config"),!0)),o=i.search(this.queue,function(){return this.id==a.id}),o===-1?(this.queue.push(a),r.call(this,this.queue.length-1)):(this.queue[o]=jQuery.extend(!0,{},this.queue[o],a),r.call(this,o)),c=null,o=null,this):(console.log(ax5.info.getError("ax5combobox","401","bind")),this)},this.open=function(){var n=function(e){e.onExpand.call({self:this,item:e},function(e){if(this.waitOptionsCallback){var n={},a=this.queue[this.activecomboboxQueueIndex];!function(t,e){var n={};e.options.forEach(function(e,i){e["@index"]=i,n[e[t.columnKeys.optionValue]]=e}),i.isArray(t.selected)&&t.selected.forEach(function(i){n[i[t.columnKeys.optionValue]]&&(e.options[n[i[t.columnKeys.optionValue]]["@index"]][t.columnKeys.optionSelected]=!0)})}(a,e),a.options=v.call(this,this.activecomboboxQueueIndex,e.options),c.call(this,this.activecomboboxQueueIndex),l.call(this),n.id=a.id,n.theme=a.theme,n.size="ax5combobox-option-group-"+a.size,n.multiple=a.multiple,n.lang=a.lang,n.options=a.options,this.activecomboboxOptionGroup.find('[data-els="content"]').html(jQuery(t.tmpl.get.call(this,"options",n,a.columnKeys)))}}.bind(this))};return function(a,l){this.waitOptionsCallback=null;var d,c,u=i.isNumber(a)?a:b.call(this,a),h=this.queue[u],p={};return h.$display.attr("disabled")?this:(this.openTimer&&clearTimeout(this.openTimer),this.activecomboboxOptionGroup?this.activecomboboxQueueIndex==u?this:l>2?this:(this.close(),this.openTimer=setTimeout(function(){this.open(u,(l||0)+1)}.bind(this),e.animateTime),this):(h.optionFocusIndex=-1,h.selected&&h.selected.length>0&&(h.optionSelectedIndex=h.selected[0]["@findex"]),p.id=h.id,p.theme=h.theme,p.size="ax5combobox-option-group-"+h.size,p.multiple=h.multiple,p.lang=h.lang,h.$display.attr("data-combobox-option-group-opened","true"),h.onExpand&&(p.waitOptions=!0),p.options=i.filter(h.options,function(){return!this.hide}),this.activecomboboxOptionGroup=jQuery(t.tmpl.get.call(this,"optionGroup",p,h.columnKeys)),this.activecomboboxOptionGroup.find('[data-els="content"]').html(jQuery(t.tmpl.get.call(this,"options",p,h.columnKeys))),this.activecomboboxQueueIndex=u,s.call(this,"append"),jQuery(window).bind("resize.ax5combobox-"+this.instanceId,function(){s.call(this)}.bind(this)),h.selected&&h.selected.length>0&&(c=this.activecomboboxOptionGroup.find('[data-option-index="'+h.selected[0]["@index"]+'"]'),c.get(0)&&(d=c.position().top-this.activecomboboxOptionGroup.height()/3,this.activecomboboxOptionGroup.find('[data-els="content"]').stop().animate({scrollTop:d},h.animateTime,"swing",function(){}))),jQuery(window).bind("click.ax5combobox-"+this.instanceId,function(t){t=t||window.event,r.call(this,t),i.stopEvent(t)}.bind(this)),o.call(this,h,{self:this,state:"open",item:h}),h.onExpand&&(this.waitOptionsCallback=!0,n.call(this,h)),p=null,d=null,c=null,this))}}(),this.update=function(t){return this.bind(t),this},this.setValue=function(t,e,n){var a=i.isNumber(t)?t:b.call(this,t);if(a===-1)return void console.log(ax5.info.getError("ax5combobox","402","val"));if(w.call(this,a),i.isArray(e)){var o=i.map(e,function(){return{value:this}});_.call(this,a,o,n||!0,{noStateChange:!0})}else i.isString(e)||i.isNumber(e)?_.call(this,a,{value:e},n||!0,{noStateChange:!0}):c.call(this,a);return p.call(this,a),l.call(this),this},this.setText=function(t,e,n){var a=i.isNumber(t)?t:b.call(this,t);return a===-1?void console.log(ax5.info.getError("ax5combobox","402","val")):(w.call(this,a),_.call(this,a,e,!0,{noStateChange:!0}),p.call(this,a),l.call(this),this)},this.getSelectedOption=function(t){var e=i.isNumber(t)?t:b.call(this,t);return e===-1?void console.log(ax5.info.getError("ax5combobox","402","val")):i.deepCopy(this.queue[e].selected)},this.close=function(t){return this.closeTimer&&clearTimeout(this.closeTimer),this.activecomboboxOptionGroup?(t=this.queue[this.activecomboboxQueueIndex],t.optionFocusIndex=-1,t.$display.removeAttr("data-combobox-option-group-opened").trigger("focus"),t.$displayLabel.attr("contentEditable","false"),this.activecomboboxOptionGroup.addClass("destroy"),jQuery(window).unbind("resize.ax5combobox-"+this.instanceId).unbind("click.ax5combobox-"+this.instanceId).unbind("keyup.ax5combobox-"+this.instanceId),this.closeTimer=setTimeout(function(){this.activecomboboxOptionGroup&&this.activecomboboxOptionGroup.remove(),this.activecomboboxOptionGroup=null,this.activecomboboxQueueIndex=-1,o.call(this,t,{self:this,state:"close"})}.bind(this),e.animateTime),this.waitOptionsCallback=null,this):this},this.blur=function(t){var e=i.isNumber(t)?t:b.call(this,t);return e===-1?void console.log(ax5.info.getError("ax5combobox","402","val")):(p.call(this,e),this)},this.enable=function(t){var e=b.call(this,t);return"undefined"!=typeof e&&(this.queue[e].disabled=!1,this.queue[e].$display[0]&&(this.queue[e].$display.removeAttr("disabled"),this.queue[e].$displayLabelInput.removeAttr("disabled")),this.queue[e].$select[0]&&this.queue[e].$select.removeAttr("disabled"),o.call(this,this.queue[e],{self:this,state:"enable"})),this},this.disable=function(t){var e=b.call(this,t);return"undefined"!=typeof e&&(this.queue[e].disabled=!0,this.queue[e].$display[0]&&(this.queue[e].$display.attr("disabled","disabled"),this.queue[e].$displayLabelInput.attr("disabled","disabled")),this.queue[e].$select[0]&&this.queue[e].$select.attr("disabled","disabled"),o.call(this,this.queue[e],{self:this,state:"disable"})),this},this.align=function(){return l.call(this),this},this.main=function(){arguments&&i.isObject(arguments[0])?this.setConfig(arguments[0]):this.init()}.apply(this,arguments)};return e}()),t=ax5.ui.combobox}(),ax5.ui.combobox_instance=new ax5.ui.combobox,jQuery.fn.ax5combobox=function(){return function(t){if(ax5.util.isString(arguments[0])){var e=arguments[0];switch(e){case"open":return ax5.ui.combobox_instance.open(this);case"close":return ax5.ui.combobox_instance.close(this);case"setValue":return ax5.ui.combobox_instance.setValue(this,arguments[1],arguments[2],arguments[3],arguments[4]||"justSetValue");case"setText":return ax5.ui.combobox_instance.setText(this,arguments[1],arguments[2],arguments[3],arguments[4]||"justSetValue");case"getSelectedOption":return ax5.ui.combobox_instance.getSelectedOption(this);case"enable":return ax5.ui.combobox_instance.enable(this);case"disable":return ax5.ui.combobox_instance.disable(this);case"blur":return ax5.ui.combobox_instance.blur(this);default:return this}}else"undefined"==typeof t&&(t={}),jQuery.each(this,function(){var e={target:this};t=jQuery.extend({},t,e),ax5.ui.combobox_instance.bind(t)});return this}}(),function(){var t=ax5.ui.combobox,e=(ax5.util,function(t){return'\n
\n
\n
\n
\n
\n
\n '}),i=function(t){return'\n
\n
\n
\n \n
\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=function(t){return'\n \n '},a=function(t){return'\n{{#selected}}\n\n{{/selected}}\n"},o=function(t){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 {{'+t.optionText+'}}\n
\n
\n {{/hide}}\n {{/options}}\n
\n {{/optgroup}}\n {{^optgroup}}\n {{^hide}}\n
\n
\n {{#multiple}}\n \n \n \n {{/multiple}}\n {{'+t.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 '; -},l=function(t){return'{{#selected}}
{{{removeIcon}}}
{{text}}
{{/selected}}'};t.tmpl={comboboxDisplay:i,formSelect:n,formSelectOptions:a,optionGroup:e,options:o,label:l,get:function(e,i,n){return ax5.mustache.render(t.tmpl[e].call(this,n),i)}}}(),function(){var t=ax5.ui.combobox,e=(ax5.util,{1:function(t,e,i){var n=this.config,a=e;$(e).find("span").get(0)&&(a=$(e).find("span").get(0));var o,l,s=(a.textContent||a.innerText).replace(/^[\s\r\n\t]*|[\s\r\n\t]*$/g,""),r=this.queue[t];if(r.selected&&r.selected.length>0&&e.getAttribute("data-ax5combobox-selected-text")==s)return o=e.getAttribute("data-ax5combobox-selected-label"),l=r.selected[o],{index:{gindex:l["@gindex"],index:l["@index"],value:l[n.columnKeys.optionValue]}};if(e.getAttribute("data-ax5combobox-selected-text"))return s;if(""!=s){if(i)return s;var d;return r.optionFocusIndex>-1&&(d=this.activecomboboxOptionGroup.find('[data-option-focus-index="'+r.optionFocusIndex+'"]')),r.optionFocusIndex>-1&&d.get(0)&&d.attr("data-option-value")?{index:{gindex:d.attr("data-option-group-index"),index:d.attr("data-option-index")}}:r.editable?s:void 0}},3:function(t,e,i){var n=(this.config,(e.textContent||e.innerText).replace(/^[\s\r\n\t]*|[\s\r\n\t]*$/g,"")),a=this.queue[t];if(""!=n){if(i)return n;var o;return a.optionFocusIndex>-1&&(o=this.activecomboboxOptionGroup.find('[data-option-focus-index="'+a.optionFocusIndex+'"]')),a.optionFocusIndex>-1&&o.get(0)&&o.attr("data-option-value")?{index:{gindex:o.attr("data-option-group-index"),index:o.attr("data-option-index")}}:a.editable?n:void 0}}});t.util={nodeTypeProcessor:e}}(),function(){var t=ax5.ui,e=ax5.util;t.addClass({className:"layout",version:"1.3.58"},function(){var t=function(){var t,i=this,n={mousedown:ax5.info.supportTouch?"touchstart":"mousedown",mousemove:ax5.info.supportTouch?"touchmove":"mousemove",mouseup:ax5.info.supportTouch?"touchend":"mouseup"},a=function(t){var e="changedTouches"in t.originalEvent?t.originalEvent.changedTouches[0]:t;return{clientX:e.clientX,clientY:e.clientY}};this.instanceId=ax5.getGuid(),this.config={theme:"default",animateTime:250,splitter:{size:4},autoResize:!0},this.queue=[],this.openTimer=null,this.closeTimer=null,this.resizer=null,t=this.config;var o=function(){for(var t=this.queue.length;t--;)"undefined"==typeof this.queue[t].parentQueIdx&&this.queue[t].autoResize&&r.call(this,t,null,"windowResize")},l={width:function(t,e){return e?e.__width+(e.split?t.splitter.size:0):0},height:function(t,e){return e?e.__height+(e.split?t.splitter.size:0):0}},s=function(t,i){return"*"==t?void 0:"%"==e.right(t,1)?i*e.number(t)/100:Number(t)},r=function(){var t={split:{horizontal:function(t,e,i){e.splitter?e.__height=t.splitter.size:i==t.splitPanel.length-1&&0==t.splitPanel.asteriskLength?(e.height="*",e.__height=void 0,t.splitPanel.asteriskLength++):"*"==e.height&&t.splitPanel.asteriskLength++},vertical:function(t,e,i){e.splitter?e.__width=t.splitter.size:i==t.splitPanel.length-1&&0==t.splitPanel.asteriskLength?(e.width="*",e.__width=void 0,t.splitPanel.asteriskLength++):"*"==e.width&&t.splitPanel.asteriskLength++}}},i={top:function(t,e){e.$target.css({height:e.__height||0}),e.split&&e.$splitter.css({height:t.splitter.size,top:e.__height||0})},bottom:function(t,e){e.$target.css({height:e.__height||0}),e.split&&e.$splitter.css({height:t.splitter.size,bottom:e.__height||0})},left:function(t,e){var i={width:e.__width||0,height:t.targetDimension.height};t.dockPanel.top&&(i.height-=t.dockPanel.top.__height,i.top=t.dockPanel.top.__height,t.dockPanel.top.split&&(i.height-=t.splitter.size,i.top+=t.splitter.size)),t.dockPanel.bottom&&(i.height-=t.dockPanel.bottom.__height,t.dockPanel.bottom.split&&(i.height-=t.splitter.size)),e.$target.css(i),e.split&&e.$splitter.css({width:t.splitter.size,height:i.height,top:i.top,left:i.width})},right:function(t,e){var i={width:e.__width||0,height:t.targetDimension.height};t.dockPanel.top&&(i.height-=t.dockPanel.top.__height,i.top=t.dockPanel.top.__height,t.dockPanel.top.split&&(i.height-=t.splitter.size,i.top+=t.splitter.size)),t.dockPanel.bottom&&(i.height-=t.dockPanel.bottom.__height,t.dockPanel.bottom.split&&(i.height-=t.splitter.size)),e.$target.css(i),e.split&&e.$splitter.css({width:t.splitter.size,height:i.height,top:i.top,right:i.width})},center:function(t,e){var i={width:t.targetDimension.width,height:t.targetDimension.height};t.dockPanel.top&&(i.height-=t.dockPanel.top.__height||0,i.top=t.dockPanel.top.__height||0,t.dockPanel.top.split&&(i.height-=t.splitter.size,i.top+=t.splitter.size)),t.dockPanel.bottom&&(i.height-=t.dockPanel.bottom.__height||0,t.dockPanel.bottom.split&&(i.height-=t.splitter.size)),t.dockPanel.left&&(i.width-=t.dockPanel.left.__width||0,i.left=t.dockPanel.left.__width||0,t.dockPanel.left.split&&(i.width-=t.splitter.size,i.left+=t.splitter.size)),t.dockPanel.right&&(i.width-=t.dockPanel.right.__width||0,t.dockPanel.right.split&&(i.width-=t.splitter.size));var n=e.minWidth||0,a=e.minHeight||0;i.widtha.offsetEnd-s&&(e.__da=a.offsetEnd-e.offsetEnd-s),{top:e.$target.position().top+e.__da}}e.__da=i.clientX-e.mousePosition.clientX;var n=o.splitPanel[e.panelIndex-1],a=o.splitPanel[e.panelIndex+1],r=n.minWidth||0,d=a.minWidth||0;return e.offsetStart+e.__daa.offsetEnd-d&&(e.__da=a.offsetEnd-e.offsetEnd-d),{left:Number(e.$target.position().left)+Number(e.__da)}}};e.__da=0,jQuery(document.body).bind(n.mousemove+".ax5layout-"+this.instanceId,function(t){i.resizer||(i.resizer=jQuery('
'),i.resizer.css({left:s.left,top:s.top,width:r.width,height:r.height}),o.$target.append(i.resizer)),i.resizer.css(c[e.resizerType](t))}).bind(n.mouseup+".ax5layout-"+this.instanceId,function(n){d.off.call(i,t,e,a)}).bind("mouseleave.ax5layout-"+this.instanceId,function(n){d.off.call(i,t,e,a)}),jQuery(document.body).attr("unselectable","on").css("user-select","none").on("selectstart",!1)},off:function(t,e,a){var o=this.queue[t],l={"dock-panel":{left:function(t,e){e.__width+=e.__da},right:function(){e.__width-=e.__da},top:function(){e.__height+=e.__da},bottom:function(){e.__height-=e.__da}},"split-panel":{split:function(){"horizontal"==o.orientation?(o.splitPanel[e.panelIndex-1].__height+=e.__da,o.splitPanel[e.panelIndex+1].__height-=e.__da):(o.splitPanel[e.panelIndex-1].__width+=e.__da,o.splitPanel[e.panelIndex+1].__width-=e.__da)}},"tab-panel":{}};i.resizer&&(i.resizer.remove(),i.resizer=null,l[this.queue[t].layout][e.resizerType].call(this,t,e),r.call(this,t)),jQuery(document.body).unbind(n.mousemove+".ax5layout-"+this.instanceId).unbind(n.mouseup+".ax5layout-"+this.instanceId).unbind("mouseleave.ax5layout-"+this.instanceId),jQuery(document.body).removeAttr("unselectable").css("user-select","auto").off("selectstart")}},c={open:function(t,e,i){if(e.activePanelIndex!=i&&(e.tabPanel[i].active=!0,e.tabPanel[e.activePanelIndex].active=!1,e.$target.find('[data-tab-panel-label="'+i+'"]').attr("data-tab-active","true"),e.$target.find('[data-tab-panel-label="'+e.activePanelIndex+'"]').removeAttr("data-tab-active"),e.tabPanel[i].$target.attr("data-tab-active","true"),e.tabPanel[e.activePanelIndex].$target.removeAttr("data-tab-active"),e.activePanelIndex=i,e.onOpenTab)){var n={$target:e.$target,name:e.name,id:e.id,layout:e.layout,activePanelIndex:e.activePanelIndex,activePanel:e.tabPanel[e.activePanelIndex],tabPanel:e.tabPanel};e.onOpenTab.call(n)}}},u=function(){return'\n
\n
\n
\n
\n {{#tabPanel}}\n
\n
{{{label}}}
\n
\n {{/tabPanel}}\n
\n
\n
\n'},h=function(){var t={"dock-panel":function(t){var o=this.queue[t];o.dockPanel={},o.$target.find(">[data-dock-panel]").each(function(){var l={};!function(t){e.isObject(t)&&!t.error&&(l=jQuery.extend(!0,l,t))}(e.parseJson(this.getAttribute("data-dock-panel"),!0)),"dock"in l&&(l.$target=jQuery(this),l.$target.addClass("dock-panel-"+l.dock),(l.split=l.split&&"true"==l.split.toString())&&(l.$splitter=jQuery('
'),l.$splitter.bind(n.mousedown,function(e){l.mousePosition=a(e),d.on.call(i,t,l,l.$splitter)}).bind("dragstart",function(t){return e.stopEvent(t),!1}),o.$target.append(l.$splitter)),"top"==l.dock||"bottom"==l.dock?l.__height=s(l.height,o.targetDimension.height):l.__width=s(l.width,o.targetDimension.width),l.resizerType=l.dock,o.dockPanel[l.dock]=l)})},"split-panel":function(t){var o=this.queue[t];o.splitPanel=[],o.$target.find(">[data-split-panel], >[data-splitter]").each(function(l){var r={};!function(t){e.isObject(t)&&!t.error&&(r=jQuery.extend(!0,r,t))}(e.parseJson(this.getAttribute("data-split-panel")||this.getAttribute("data-splitter"),!0)),r.$target=jQuery(this),r.$target.addClass("split-panel-"+o.orientation),r.panelIndex=l,this.getAttribute("data-splitter")?(r.splitter=!0,r.$target.bind(n.mousedown,function(e){r.panelIndex>0&&r.panelIndex[data-tab-panel]").each(function(t){var i={};!function(t){e.isObject(t)&&!t.error&&(i=jQuery.extend(!0,i,t))}(e.parseJson(this.getAttribute("data-tab-panel"),!0)),a&&(i.active=!1),i.$target=jQuery(this),i.active&&"false"!=i.active&&(a=!0,n.activePanelIndex=t,i.$target.attr("data-tab-active","true")),i.panelIndex=t,n.tabPanel.push(i)}),a||(n.tabPanel[0].active=!0,n.tabPanel[0].$target.attr("data-tab-active","true"),n.activePanelIndex=0),n.$target.append(jQuery(ax5.mustache.render(u.call(this,t),n))),n.$target.on("click","[data-tab-panel-label]",function(e){var a=this.getAttribute("data-tab-panel-label");c.open.call(i,t,n,a)})}};return function(e){var i=this.queue[e];i.targetDimension={height:i.$target.innerHeight(),width:i.$target.innerWidth()},i.$target.parents("[data-ax5layout]").get(0)&&f.call(this,i.$target.parents("[data-ax5layout]").get(0),e),i.layout in t&&t[i.layout].call(this,e),r.call(this,e)}}(),p=function(t){return e.isString(t)||(t=jQuery(t).data("data-ax5layout-id")),e.isString(t)?e.search(this.queue,function(){return this.id==t}):-1},f=function(t,i){var n=e.isNumber(t)?t:p.call(this,t);this.queue[n].childQueIdxs||(this.queue[n].childQueIdxs=[]),this.queue[n].childQueIdxs.push(i),this.queue[i].parentQueIdx=n};this.init=function(){this.onStateChanged=t.onStateChanged,this.onClick=t.onClick,jQuery(window).bind("resize.ax5layout-"+this.instanceId,function(){o.call(this)}.bind(this))},this.bind=function(i){var n,a={};return i=jQuery.extend(!0,a,t,i),i.target?(i.$target=jQuery(i.target),i.id||(i.id=i.$target.data("data-ax5layout-id")),i.id||(i.id="ax5layout-"+ax5.getGuid(),i.$target.data("data-ax5layout-id",i.id)),i.name=i.$target.attr("data-ax5layout"),i.options&&(i.options=JSON.parse(JSON.stringify(i.options))),function(t){e.isObject(t)&&!t.error&&(i=jQuery.extend(!0,i,t))}(e.parseJson(i.$target.attr("data-config"),!0)),n=e.search(this.queue,function(){return this.id==i.id}),n===-1?(this.queue.push(i),h.call(this,this.queue.length-1)):(this.queue[n]=jQuery.extend(!0,{},this.queue[n],i),h.call(this,n)),a=null,n=null,this):(console.log(ax5.info.getError("ax5layout","401","bind")),this)},this.align=function(t,i){var n=e.isNumber(t)?t:p.call(this,t);if(n===-1)for(var a=this.queue.length;a--;)r.call(this,a,null,i);else r.call(this,n,null,i);return this},this.onResize=function(t,i){var n=e.isNumber(t)?t:p.call(this,t);return n===-1?void console.log(ax5.info.getError("ax5layout","402","onResize")):(this.queue[n].onResize=i,this)},this.resize=function(){var t={"dock-panel":function(t,i){["top","bottom","left","right"].forEach(function(n){i[n]&&t.dockPanel[n]&&("top"==n||"bottom"==n?t.dockPanel[n].__height=e.isObject(i[n])?i[n].height:i[n]:"left"!=n&&"right"!=n||(t.dockPanel[n].__width=e.isObject(i[n])?i[n].width:i[n]))})},"split-panel":function(){},"tab-panel":function(){}};return function(i,n,a){var o=e.isNumber(i)?i:p.call(this,i);if(o===-1)for(var l=this.queue.length;l--;)t[this.queue[l].layout].call(this,this.queue[l],n),r.call(this,l,a);else this.queue[o]&&(t[this.queue[o].layout].call(this,this.queue[o],n),r.call(this,o,a));return this}}(),this.reset=function(){var t={"dock-panel":function(t){["top","bottom","left","right"].forEach(function(e){t.dockPanel[e]&&("top"==e||"bottom"==e?t.dockPanel[e].__height=t.dockPanel[e].height:"left"!=e&&"right"!=e||(t.dockPanel[e].__width=t.dockPanel[e].width))})},"split-panel":function(t){t.splitPanel.forEach(function(e){"vertical"==t.orientation?e.__width=s(e.width,t.targetDimension.width):"horizontal"==t.orientation&&(e.__height=s(e.height,t.targetDimension.height))})},"tab-panel":function(){}};return function(i,n){var a=e.isNumber(i)?i:p.call(this,i);return a===-1||(t[this.queue[a].layout].call(this,this.queue[a]),r.call(this,a,n)),this}}(),this.hide=function(){},this.tabOpen=function(){return function(t,i){var n=e.isNumber(t)?t:p.call(this,t);return n===-1?void console.log(ax5.info.getError("ax5layout","402","tabOpen")):(c.open.call(this,n,this.queue[n],i),this)}}(),this.main=function(){arguments&&e.isObject(arguments[0])?this.setConfig(arguments[0]):this.init()}.apply(this,arguments)};return t}())}(),ax5.ui.layout_instance=new ax5.ui.layout,jQuery.fn.ax5layout=function(){return function(t){if(ax5.util.isString(arguments[0])){var e=arguments[0];switch(e){case"align":return ax5.ui.layout_instance.align(this,arguments[1]);case"resize":return ax5.ui.layout_instance.resize(this,arguments[1],arguments[2]);case"reset":return ax5.ui.layout_instance.reset(this,arguments[1]);case"hide":return ax5.ui.layout_instance.hide(this,arguments[1]);case"onResize":return ax5.ui.layout_instance.onResize(this,arguments[1]);case"tabOpen":return ax5.ui.layout_instance.tabOpen(this,arguments[1]);default:return this}}else"undefined"==typeof t&&(t={}),jQuery.each(this,function(){var e={target:this};t=jQuery.extend({},t,e),ax5.ui.layout_instance.bind(t)});return this}}(),function(){var t=ax5.ui,e=ax5.util;t.addClass({className:"binder",version:"1.3.58"},function(){var t=function(){var t;this.instanceId=ax5.getGuid(),this.config={},t=this.config,this.model={},this.tmpl={},this.view_target=null,this.change_trigger={},this.click_trigger={},this.update_trigger={},this.onerror=null;var i=Object.prototype.toString,n=function(t){var e;return null!=t&&t==t.window?e="window":t&&1==t.nodeType?e="element":t&&11==t.nodeType?e="fragment":"undefined"==typeof t?e="undefined":"[object Object]"==i.call(t)?e="object":"[object Array]"==i.call(t)?e="array":"[object String]"==i.call(t)?e="string":"[object Number]"==i.call(t)?e="number":"[object NodeList]"==i.call(t)?e="nodelist":"function"==typeof t&&(e="function"),e},a=function(t,e,i){return t+"["+e+"]"+("."==i?"":"."+i)},o=function(t){var e=[],i=[].concat(t.split(/[\.\[\]]/g));return i.forEach(function(t){""!==t&&e.push('["'+t.replace(/['\"]/g,"")+'"]')}),i=null,e.join("")};this.setModel=function(t,e){return this.model=t,!this.view_target&&e?(this.view_target=e,this._binding()):this._binding("update"),this},this.set=function(t,e){var i,a,l,s=this;if(Function("val","this"+o(t)+" = val;").call(this.model,e),i=n(e),"object"==i)for(var r in e)this.set(t+"."+r,e[r]);else if("array"==i)for(this.view_target.find('[data-ax-path="'+t+'"]').each(function(){l=(this.type||"").toLowerCase(),"checkbox"!=l&&"radio"!=l||s.set_els_value(this,this.tagName.toLowerCase(),l,e,t,"change")}),a=e.length;a--;)this.set(t+"["+a+"]",e[a]);else this.view_target.find('[data-ax-path="'+t+'"]').each(function(){s.set_els_value(this,this.tagName.toLowerCase(),(this.type||"").toLowerCase(),e,t,"change")});return this},this.get=function(t){return"undefined"==typeof t?this.model:Function("","return this"+o(t)+";").call(this.model)},this.onChange=function(t,e){return this.change_trigger[t||"*"]=e,this},this.onClick=function(t,e){return this.click_trigger[t]=e,this},this.add=function(t,e){var i=Function("","return this"+o(t)+";").call(this.model),n=this.tmpl[t];e["@i"]=i.length,e["@r"]=i.length,e.__ADDED__=!0,Function("val","this"+o(t)+".push(val);").call(this.model,e);for(var a in n){var l=$(ax5.mustache.render(n[a].content,e));l.attr("data-ax-repeat-path",t),l.attr("data-ax-repeat-i",e["@i"]),this.bind_event_tmpl(l,t),n[a].container.append(l)}this.change("*");var s=this.update_trigger[t];if(s){var r={repeat_path:t,tmpl:n,list:i};s.call(r,r)}return this},this.remove=function(t,e){var i=Function("","return this"+o(t)+";").call(this.model),n=this.tmpl[t];"undefined"==typeof e&&(e=i.length-1);var a=i[e];a.__ADDED__?i.splice(e,1):i[e].__DELETED__=!0;for(var l in n)n[l].container.empty(),this.print_tmpl(t,n[l]);this.change("*");var s=this.update_trigger[t];if(s){var r={repeat_path:t,tmpl:n,list:i};s.call(r,r)}return this},this.update=function(t,e,i){var n=Function("","return this"+o(t)+";").call(this.model),a=this.tmpl[t];"undefined"!=typeof e&&i&&n.splice(e,1,i);for(var l in a)a[l].container.empty(),this.print_tmpl(t,a[l]);this.change("*");var s=this.update_trigger[t];if(s){var r={repeat_path:t,tmpl:a,list:n};s.call(r,r)}return this},this.childAdd=function(t,e,i,n){var a=Function("","return this"+o(t)+";").call(this.model),l=Function("","return this"+o(t)+"["+e+"]."+i+";").call(this.model);n.__ADDED__=!0,l.push(n),this.update(t,e,a[e])},this.childRemove=function(t,e,i,n){var a=Function("","return this"+o(t)+";").call(this.model),l=Function("","return this"+o(t)+"["+e+"]."+i+";").call(this.model),s=l[n];s.__ADDED__?l.splice(n,1):l[n].__DELETED__=!0,this.update(t,e,a[e])},this.childUpdate=function(t,e,i,n,a){var l=Function("","return this"+o(t)+";").call(this.model),s=Function("","return this"+o(t)+"["+e+"]."+i+";").call(this.model);s[n]=a,this.update(t,e,l[e])},this.childSet=function(t,e,i,n){var a=this;return Function("val","this"+o(t)+"["+e+"]."+i+" = val;").call(this.model,n),this.view_target.find('[data-ax-repeat="'+t+'"]').find('[data-ax-repeat-i="'+e+'"]').find('[data-ax-item-path="'+i+'"]').each(function(){a.set_els_value(this,this.tagName.toLowerCase(),(this.type||"").toLowerCase(),n,t+"["+e+"]."+i)}),this},this.onUpdate=function(t,e){return this.update_trigger[t]=e,this},this._binding=function(t){var e=this;this.view_target.find("[data-ax-path]").each(function(){var t,i=$(this),n=i.attr("data-ax-path"),a=(this.type||"").toLowerCase();try{t=Function("","return this"+o(n)+";").call(e.model)}catch(l){e.onerror&&e.onerror("not found target [model."+o(n)+"]")}e.set_els_value(this,this.tagName.toLowerCase(),a,t||"",n)}),"undefined"==typeof t?this.view_target.find("[data-ax-repeat]").each(function(){var t=$(this),i=t.attr("data-ax-repeat"),n=t.attr("data-ax-repeat-idx");"undefined"==typeof e.tmpl[i]&&(e.tmpl[i]={}),"undefined"!=typeof n?e.tmpl[i][n]={container:t,content:t.find("script").html()}:e.tmpl[i][0]={container:t,content:t.find("script").html()},t.empty()}):this.view_target.find("[data-ax-repeat]").each(function(){var t=$(this);t.empty().show()}),this.view_target.find("[data-ax-path]").unbind("change.axbinder").bind("change.axbinder",function(t){var i,a,l=!1,s=[],r=$(t.target),d=r.attr("data-ax-path"),c=Function("","return this"+o(d)+";").call(e.model),u=(this.type||"").toLowerCase(),h=n(c),p=!0;if("object"!=h&&"array"!=h||(p=!1),"checkbox"==u){if(e.view_target.find('[data-ax-path="'+d+'"]').length>1){for("array"!=n(c)&&(c="undefined"==typeof c||""==c?[]:[].concat(c)),i=c.length,l=!1,a=this.checked;i--;)c[i]==this.value&&(l=!0);if(a)l||c.push(this.value);else{for(i=c.length;i--;)c[i]==this.value||s.push(c[i]);c=s}}else c=this.checked?this.value:"";Function("val","this"+o(d)+" = val;").call(e.model,c),e.change(d,{el:this,jquery:r,tagname:this.tagName.toLowerCase(),value:c})}else p&&(Function("val","this"+o(d)+" = val;").call(e.model,this.value),e.change(d,{el:this,jquery:r,tagname:this.tagName.toLowerCase(),value:this.value}));r.data("changedTime",(new Date).getTime())});var i;for(var a in e.tmpl){for(var l in e.tmpl[a])this.print_tmpl(a,e.tmpl[a][l],"isInit");if(i=this.update_trigger[a]){var s={repeat_path:a,tmpl:e.tmpl[a],list:Function("","return this."+a+";").call(this.model)};i.call(s,s)}}},this.set_els_value=function(t,e,i,n,a,l){n="undefined"==typeof n?[]:[].concat(n);var s,r;if("input"==e)if("checkbox"==i||"radio"==i){r=n.length;var d=!1;try{if(r>0)for(;r--;)"undefined"!=typeof n[r]&&t.value===n[r].toString()&&(d=!0)}catch(c){console.log(c)}t.checked=d}else t.value=n.join("");else if("select"==e){s=t.options,r=s.length;for(var u,h=!1;r--;){for(u=n.length;u--;)if("undefined"!=typeof n[u]&&s[r].value===n[u].toString()){s[r].selected=!0,h=!0;break}if(h)break}h||(s[0]?(s[0].selected=!0,Function("val","this"+o(a)+" = val;").call(this.model,s[0].value)):Function("val","this"+o(a)+" = val;").call(this.model,"")),window.AXSelect&&$("undefined"!=typeof n&&t).bindSelectSetValue(n[n.length-1])}else"textarea"==e?t.value=n.join("")||"":t.innerText?t.innerText=n.join(""):t.innerHTML=n.join("");return l&&this.change(a,{el:t,tagname:e,value:n}),this},this.change=function(t,e){var i=this.change_trigger[t];i&&i.call(e,e),"*"!=t&&this.change_trigger["*"]&&this.change_trigger["*"].call(e,e)},this.click=function(t,e){var i=this.click_trigger[t];i&&i.call(e,e)},this.sync_model=function(){},this.print_tmpl=function(t,e,i){var a=Function("","return this"+o(t)+";").call(this.model);if(a&&"array"==n(a))for(var l=0,s=a.length;l1){for("array"!=n(m)&&(m="undefined"==typeof m||""==m?[]:[].concat(m)),s=m.length,d=!1,r=this.checked;s--;)m[s]==this.value&&(d=!0);if(r)d||m.push(this.value);else{for(s=m.length;s--;)m[s]==this.value||c.push(m[s]);m=c}}else m=this.checked?this.value:"";Function("val","this."+f+" = val;").call(i.model,m),i.change(f,{el:this,jquery:h,tagname:this.tagName.toLowerCase(),value:m})}else x&&(Function("val","this."+f+" = val;").call(i.model,this.value),i.change(f,{el:this,jquery:h,tagname:this.tagName.toLowerCase(),value:this.value}));h.data("changedTime",(new Date).getTime())}),t.find("[data-ax-item-path]").unbind("blur.axbinder").bind("blur.axbinder",function(t){var e=$(t.target);("undefined"==typeof e.data("changedTime")||e.data("changedTime")<(new Date).getTime()-10)&&e.trigger("change")})},this.focus=function(t){return this.view_target.find('[data-ax-path="'+t+'"]').focus(),this},this.validate=function(){var t=this,e=[];return this.view_target.find("[data-ax-path]").each(function(){var i=$(this),n=i.attr("data-ax-path"),a=i.attr("data-ax-validate"),l=i.attr("pattern");if(a){var s,r,d;s=Function("","return this"+o(n)+";").call(t.model),"undefined"==typeof s&&(s=""),r=s.toString(),d=!1,"required"==a&&""==r.trim()?d=!0:"pattern"==a?d=!new RegExp(l).test(r):"email"==a?d=!/[a-z0-9._%+-]+@[a-z0-9.-]+\.[a-z]{2,4}$/.test(r):!/\D.?/g.test(a)&&r.trim().length0?{error:e}:{}},this.main=function(){arguments&&e.isObject(arguments[0])&&this.setConfig(arguments[0])}.apply(this,arguments)};return t}())}(),function(){var t,e=ax5.ui,i=ax5.util;e.addClass({className:"autocomplete",version:"1.3.58"},function(){var e=function(){var e,n=this;this.instanceId=ax5.getGuid(),this.config={theme:"default",animateTime:250,removeIcon:"X",lang:{noSelected:"",noOptions:"no options",loading:"Now Processing"},columnKeys:{optionValue:"value",optionText:"text",optionSelected:"selected"}},this.queue=[],this.activeautocompleteOptionGroup=null,this.activeautocompleteQueueIndex=-1,this.openTimer=null,this.closeTimer=null,this.waitOptionsCallback=null,this.keyUpTimer=null,e=this.config;var a=jQuery(window),o={18:"KEY_ALT",17:"KEY_CONTROL",46:"KEY_DELETE",40:"KEY_DOWN",35:"KEY_END",187:"KEY_EQUAL",36:"KEY_HOME",45:"KEY_INSERT",37:"KEY_LEFT",189:"KEY_MINUS",34:"KEY_PAGEDOWN",33:"KEY_PAGEUP",39:"KEY_RIGHT",16:"KEY_SHIFT",9:"KEY_TAB",38:"KEY_UP",91:"KEY_WINDOW"},l=function(t,e){return t&&t.onStateChanged?t.onStateChanged.call(e,e):this.onStateChanged&&this.onStateChanged.call(e,e),"changeValue"==e.state&&(t&&t.onChange?t.onChange.call(e,e):this.onChange&&this.onChange.call(e,e)),t=null,e=null,!0},s=function(){for(var t,e=this.queue.length;e--;){var n=this.queue[e];if(n.$display&&(t=Math.max(n.$select.outerWidth(),i.number(n.minWidth)),n.$display.css({"min-width":t}),n.reset&&n.$display.find(".addon-icon-reset").css({"line-height":this.queue[e].$display.height()+"px"}),n.multiple)){var a=function(){return i.number(n.$display.css("border-top-width"))+i.number(n.$display.css("border-bottom-width"))}.call(this);n.$target.height(""),n.$display.height("");var o=n.$displayTable.outerHeight();Math.abs(o-n.$target.height())>a&&(n.$target.css({height:o+a+4}),n.$display.css({height:o+a+4}))}}return e=null,t=null,this},r=function(t){if(t&&!this.activeautocompleteOptionGroup)return this;var e,i=this.queue[this.activeautocompleteQueueIndex],n={},o=0,l={},s={};return i?(t&&jQuery(document.body).append(this.activeautocompleteOptionGroup),n=i.$target.offset(),l={width:i.$target.outerWidth(),height:i.$target.outerHeight()},s={winWidth:Math.max(a.width(),jQuery(document.body).width()),winHeight:Math.max(a.height(),jQuery(document.body).height()), -width:this.activeautocompleteOptionGroup.outerWidth(),height:this.activeautocompleteOptionGroup.outerHeight()},i.direction&&""!==i.direction&&"auto"!==i.direction?e=i.direction:(e="top",n.top-s.height-o<0?e="top":n.top+l.height+s.height+o>s.winHeight&&(e="bottom")),t&&this.activeautocompleteOptionGroup.addClass("direction-"+e),void this.activeautocompleteOptionGroup.css(function(){if("top"==e){if(n.top+l.height+s.height+o>s.winHeight){var t=n.top+s.height;return t+s.height+o>s.winHeight&&(t=0),t<0&&(t=0),{left:n.left,top:t,width:l.width}}return{left:n.left,top:n.top+l.height+1,width:l.width}}if("bottom"==e)return{left:n.left,top:n.top-s.height-1,width:l.width}}.call(this))):this},d=function(t,e){if(!this.activeautocompleteOptionGroup)return this;var n=this.queue[this.activeautocompleteQueueIndex],a="display";return(e=i.findParentNode(t.target,function(t){return t.getAttribute("data-option-value")?(a="optionItem",!0):n.$target.get(0)==t?(a="display",!0):void 0}))?("optionItem"===a&&(I.call(this,n.id,{optionIndex:{index:e.getAttribute("data-option-index")}},void 0,"optionItemClick"),s.call(this),r.call(this),n.multiple||this.close()),this):(this.close(),this)},c=function(e){var i=this.queue[e],n={};return n.id=i.id,n.theme=i.theme,n.size="ax5autocomplete-option-group-"+i.size,n.multiple=i.multiple,n.lang=i.lang,n.options=i.options,n.selected=i.selected,n.hasSelected=n.selected&&n.selected.length>0,n.removeIcon=i.removeIcon,t.tmpl.get.call(this,"label",n,i.columnKeys)},u=function(e){var i=this.queue[e];!i.multiple&&i.selected&&i.selected.length>0&&(i.selected=[].concat(i.selected[i.selected.length-1])),i.selected.forEach(function(t,e){t["@index"]=e}),i.$select.html(t.tmpl.get.call(this,"formSelectOptions",{selected:i.selected},i.columnKeys))},h=function(t){var e=this.queue[t];e.$displayLabel.find("[data-ax5autocomplete-selected-label]").remove(),e.$displayLabelInput.before(c.call(this,t))},p=function(t){return this.queue[t].disabled?this:(this.queue[t].$displayLabel.trigger("focus"),void this.queue[t].$displayLabelInput.focus())},f=function(t){this.queue[t].$displayLabelInput.val("")},m=function(t){this.queue[t].$displayLabel.trigger("blur")},g=function(e,n){if(this.activeautocompleteQueueIndex==-1)return this;var a=/[\{\}\[\]\/?.,;:|\)*~`!^\-_+<>@\#$%&\\\=\(\'\"]/gi;n=n.replace(a,""),this.queue[e].waitOptions=!0,this.queue[e].onSearch.call({self:this,item:this.queue[e],searchWord:n},function(e){var a={},o=this.queue[this.activeautocompleteQueueIndex];return!!o&&(function(t,e){var n={};e.options.forEach(function(e,i){e["@index"]=i,e["@findex"]=i,n[e[t.columnKeys.optionValue]]=e}),i.isArray(t.selected)&&t.selected.forEach(function(i){n[i[t.columnKeys.optionValue]]&&(e.options[n[i[t.columnKeys.optionValue]]["@index"]][t.columnKeys.optionSelected]=!0)})}(o,e),o.options=e.options,s.call(this),a.id=o.id,a.theme=o.theme,a.size="ax5autocomplete-option-group-"+o.size,a.multiple=o.multiple,a.lang=o.lang,a.options=o.options,this.activeautocompleteOptionGroup.find('[data-els="content"]').html(jQuery(t.tmpl.get.call(this,"options",a,o.columnKeys))),x.call(this,this.activeautocompleteQueueIndex,n),r.call(this),void setTimeout(function(){r.call(this)}.bind(this)))}.bind(this))},x=function(t,e){if(this.activeautocompleteQueueIndex==-1)return this;var i,n=[],a=-1,o=this.queue[t].options.length-1;if(""!=e){for(;o-a++;){if(i=this.queue[t].options[a],(""+i.text).toLowerCase()==e.toLowerCase()){n=[{"@findex":i["@findex"],optionsSort:0}];break}var l=(""+i.text).toLowerCase().search(e.toLowerCase());if(l>-1&&(n.push({"@findex":i["@findex"],optionsSort:l}),n.length>2))break;l=null}n.sort(function(t,e){return t.optionsSort-e.optionsSort})}n&&n.length>0?b.call(this,t,void 0,n[0]["@findex"]):v.call(this,t)},v=function(t){this.activeautocompleteOptionGroup&&this.activeautocompleteOptionGroup.find("[data-option-focus-index]").removeClass("hover").removeAttr("data-option-selected"),this.queue[t].optionFocusIndex=-1},b=function(t,e,i){var n,a,o,l,s=this.queue[t];if(this.activeautocompleteOptionGroup&&s.options&&s.options.length>0){if("undefined"!=typeof i?n=i:(a=s.optionFocusIndex==-1?s.optionSelectedIndex||-1:s.optionFocusIndex,a==-1?n=0:(n=a+e,n<0?n=0:n>s.optionItemLength-1&&(n=s.optionItemLength-1))),s.optionFocusIndex=n,s.options[n]&&s.options[n].hide){if("undefined"==typeof e)return this;for(;s.options[n].hide;){if(n+=e,n<0){n=0;break}if(n>s.optionItemLength-1){n=s.optionItemLength-1;break}}}if("undefined"!=typeof n&&(this.activeautocompleteOptionGroup.find("[data-option-focus-index]").removeClass("hover"),o=this.activeautocompleteOptionGroup.find('[data-option-focus-index="'+n+'"]').addClass("hover"),l=this.activeautocompleteOptionGroup.find('[data-els="content"]'),o.get(0))){var r=o.outerHeight(),d=l.innerHeight(),c=l.scrollTop(),u=o.position().top+l.scrollTop();d+cu&&l.scrollTop(u),"undefined"!=typeof e&&s.$displayLabelInput.val(s.options[n].text)}}},y=function(t){return t instanceof jQuery?t=t.data("data-ax5autocomplete-id"):i.isString(t)||(t=jQuery(t).data("data-ax5autocomplete-id")),i.isString(t)?i.search(this.queue,function(){return this.id==t}):void console.log(ax5.info.getError("ax5autocomplete","402","getQueIdx"))},w=function(t,e,i){return"undefined"==typeof i?!t.multiple||!e:i},_=function(e){this.queue[e].options.forEach(function(t){t.optgroup?t.options.forEach(function(t){t.selected=!1}):t.selected=!1}),this.queue[e].selected=[],this.queue[e].$select.html(t.tmpl.get.call(this,"formSelectOptions",{selected:this.queue[e].selected},this.queue[e].columnKeys))},I=function(){var t={selectedIndex:function(t,e,i,n){},removeSelectedIndex:function(t,e,i,n){for(var a=this.queue[t],o={},l=[],s=0,r=0;r-1)if(s.options[r][s.columnKeys.optionSelected]=w(s,s.options[r][s.columnKeys.optionSelected],a),s.options[r][s.columnKeys.optionSelected]){for(var d=!0,c=0;c-1)if(s.options[r][s.columnKeys.optionSelected]=w(s,s.options[r][s.columnKeys.optionSelected],a),s.options[r][s.columnKeys.optionSelected]){for(var d=!0,c=0;c-1?I.call(this,a.id,{optionIndex:{index:a.optionFocusIndex}},void 0,"optionItemClick"):""!=n&&I.call(this,t,n,!0),f.call(this,t),s.call(this),this.close(),i.stopEvent(e)}else e.which==ax5.info.eventKeys.DOWN?(b.call(this,t,1),i.stopEvent(e)):e.which==ax5.info.eventKeys.UP&&(b.call(this,t,-1),i.stopEvent(e))},focus:function(t,e){},blur:function(t,e){l.call(this,t),i.stopEvent(e)},selectChange:function(t,e){I.call(this,t,{value:this.queue[t].$select.val()},!0)}};return function(e){var i=this.queue[e],n={};return i.$display?h.call(this,e):(n.instanceId=this.instanceId,n.id=i.id,n.name=i.name,n.theme=i.theme,n.tabIndex=i.tabIndex,n.multiple=i.multiple,n.reset=i.reset,n.label=c.call(this,e),n.formSize=function(){return i.size?"input-"+i.size:""}(),i.$display=jQuery(t.tmpl.get.call(this,"autocompleteDisplay",n,i.columnKeys)),i.$displayTable=i.$display.find('[data-els="display-table"]'),i.$displayLabel=i.$display.find('[data-ax5autocomplete-display="label"]'),i.$displayLabelInput=i.$display.find('[data-ax5autocomplete-display="input"]'),i.$target.find("select").get(0)?(i.$select=i.$target.find("select"),i.$select.attr("tabindex","-1").attr("class","form-control "+n.formSize),n.name&&i.$select.attr("name","name"),i.$select.attr("multiple","multiple")):(i.$select=jQuery(t.tmpl.get.call(this,"formSelect",n,i.columnKeys)),i.$target.append(i.$select)),i.$target.append(i.$display)),s.call(this),i.$display.unbind("click.ax5autocomplete").bind("click.ax5autocomplete",d.click.bind(this,e)),i.$displayLabelInput.off("focus.ax5autocomplete").on("focus.ax5autocomplete",d.focus.bind(this,e)).off("blur.ax5autocomplete").on("blur.ax5autocomplete",d.blur.bind(this,e)).off("keydown.ax5autocomplete").on("keydown.ax5autocomplete",d.keyUp.bind(this,e)).off("keyup.ax5autocomplete").on("keyup.ax5autocomplete",d.keyDown.bind(this,e)),i.$select.unbind("change.ax5autocomplete").bind("change.ax5autocomplete",d.selectChange.bind(this,e)),n=null,i=null,e=null,this}}(),m={};return a=jQuery.extend(!0,m,e,a),a.target?(a.$target=jQuery(a.target),a.id||(a.id=a.$target.data("data-ax5autocomplete-id")),a.id||(a.id="ax5autocomplete-"+ax5.getGuid(),a.$target.data("data-ax5autocomplete-id",a.id)),a.name=a.$target.attr("data-ax5autocomplete"),a.options=[],a.selected=[],function(t){i.isObject(t)&&!t.error&&(a=jQuery.extend(!0,a,t))}(i.parseJson(a.$target.attr("data-ax5autocomplete-config"),!0)),l=i.search(this.queue,function(){return this.id==a.id}),l===-1?(this.queue.push(a),d.call(this,this.queue.length-1)):(this.queue[l]=jQuery.extend(!0,{},this.queue[l],a),d.call(this,l)),m=null,l=null,this):(console.log(ax5.info.getError("ax5autocomplete","401","bind")),this)},this.open=function(){return function(n,a){this.waitOptionsCallback=null;var o,s,c=i.isNumber(n)?n:y.call(this,n),u=this.queue[c],h={};return u.$display.attr("disabled")?this:(this.openTimer&&clearTimeout(this.openTimer),this.activeautocompleteOptionGroup?this.activeautocompleteQueueIndex==c?this:a>2?this:(this.close(),this.openTimer=setTimeout(function(){this.open(c,(a||0)+1)}.bind(this),e.animateTime),this):(u.optionFocusIndex=-1,u.selected&&u.selected.length>0&&(u.optionSelectedIndex=u.selected[0]["@findex"]),h.id=u.id,h.theme=u.theme,h.size="ax5autocomplete-option-group-"+u.size,h.multiple=u.multiple,h.lang=u.lang,u.$display.attr("data-autocomplete-option-group-opened","true"),h.waitOptions=!0,h.options=[],this.activeautocompleteOptionGroup=jQuery(t.tmpl.get.call(this,"optionGroup",h,u.columnKeys)),this.activeautocompleteOptionGroup.find('[data-els="content"]').html(jQuery(t.tmpl.get.call(this,"options",h,u.columnKeys))),this.activeautocompleteQueueIndex=c,r.call(this,"append"),jQuery(window).bind("resize.ax5autocomplete-"+this.instanceId,function(){r.call(this)}.bind(this)),u.selected&&u.selected.length>0&&(s=this.activeautocompleteOptionGroup.find('[data-option-index="'+u.selected[0]["@index"]+'"]'),s.get(0)&&(o=s.position().top-this.activeautocompleteOptionGroup.height()/3,this.activeautocompleteOptionGroup.find('[data-els="content"]').stop().animate({scrollTop:o},u.animateTime,"swing",function(){}))),jQuery(window).bind("click.ax5autocomplete-"+this.instanceId,function(t){t=t||window.event,d.call(this,t),i.stopEvent(t)}.bind(this)),l.call(this,u,{self:this,state:"open",item:u}),h=null,o=null,s=null,this))}}(),this.setValue=function(t,e){var n=i.isNumber(t)?t:y.call(this,t);if(n===-1)return void console.log(ax5.info.getError("ax5autocomplete","402","val"));if(_.call(this,n),i.isArray(e)){var a=i.map(e,function(){return{value:this}});I.call(this,n,a,!0,{noStateChange:!0})}else i.isObject(e)?I.call(this,n,{value:e},!0,{noStateChange:!0}):h.call(this,n);return m.call(this,n),s.call(this),this},this.setText=function(t,e){var n=i.isNumber(t)?t:y.call(this,t);return n===-1?void console.log(ax5.info.getError("ax5autocomplete","402","val")):(this.queue[n].selected=[],_.call(this,n),I.call(this,n,e,!0,{noStateChange:!0}),m.call(this,n),s.call(this),this)},this.getSelectedOption=function(t){var e=i.isNumber(t)?t:y.call(this,t);return e===-1?void console.log(ax5.info.getError("ax5autocomplete","402","val")):i.deepCopy(this.queue[e].selected)},this.close=function(t){return this.closeTimer&&clearTimeout(this.closeTimer),this.activeautocompleteOptionGroup?(t=this.queue[this.activeautocompleteQueueIndex],t.optionFocusIndex=-1,t.$display.removeAttr("data-autocomplete-option-group-opened").trigger("focus"),this.activeautocompleteOptionGroup.addClass("destroy"),jQuery(window).unbind("resize.ax5autocomplete-"+this.instanceId).unbind("click.ax5autocomplete-"+this.instanceId).unbind("keyup.ax5autocomplete-"+this.instanceId),this.closeTimer=setTimeout(function(){this.activeautocompleteOptionGroup&&this.activeautocompleteOptionGroup.remove(),this.activeautocompleteOptionGroup=null,this.activeautocompleteQueueIndex=-1,l.call(this,t,{self:this,state:"close"})}.bind(this),e.animateTime),this.waitOptionsCallback=null,this):this},this.blur=function(t){var e=i.isNumber(t)?t:y.call(this,t);return e===-1?void console.log(ax5.info.getError("ax5autocomplete","402","val")):(m.call(this,e),this)},this.enable=function(t){var e=y.call(this,t);return"undefined"!=typeof e&&(this.queue[e].disable=!1,this.queue[e].$display[0]&&(this.queue[e].$display.removeAttr("disabled"),this.queue[e].$displayLabelInput.removeAttr("disabled")),this.queue[e].$select[0]&&this.queue[e].$select.removeAttr("disabled"),l.call(this,this.queue[e],{self:this,state:"enable"})),this},this.disable=function(t){var e=y.call(this,t);return"undefined"!=typeof e&&(this.queue[e].disable=!0,this.queue[e].$display[0]&&(this.queue[e].$display.attr("disabled","disabled"),this.queue[e].$displayLabelInput.attr("disabled","disabled")),this.queue[e].$select[0]&&this.queue[e].$select.attr("disabled","disabled"),l.call(this,this.queue[e],{self:this,state:"disable"})),this},this.align=function(){return s.call(this),this},this.main=function(){arguments&&i.isObject(arguments[0])?this.setConfig(arguments[0]):this.init()}.apply(this,arguments)};return e}()),t=ax5.ui.autocomplete}(),ax5.ui.autocomplete_instance=new ax5.ui.autocomplete,jQuery.fn.ax5autocomplete=function(){return function(t){if(ax5.util.isString(arguments[0])){var e=arguments[0];switch(e){case"open":return ax5.ui.autocomplete_instance.open(this);case"close":return ax5.ui.autocomplete_instance.close(this);case"setValue":return ax5.ui.autocomplete_instance.setValue(this,arguments[1],arguments[2],arguments[3],arguments[4]||"justSetValue");case"setText":return ax5.ui.autocomplete_instance.setText(this,arguments[1],arguments[2],arguments[3],arguments[4]||"justSetValue");case"getSelectedOption":return ax5.ui.autocomplete_instance.getSelectedOption(this);case"enable":return ax5.ui.autocomplete_instance.enable(this);case"disable":return ax5.ui.autocomplete_instance.disable(this);case"blur":return ax5.ui.autocomplete_instance.blur(this);default:return this}}else"undefined"==typeof t&&(t={}),jQuery.each(this,function(){var e={target:this};t=jQuery.extend({},t,e),ax5.ui.autocomplete_instance.bind(t)});return this}}(),function(){var t=ax5.ui.autocomplete,e=(ax5.util,function(t){return'\n
\n
\n
\n
\n
\n
\n'}),i=function(t){return' \n\n
\n
\n
\n \n
\n
\n {{#multiple}}{{#reset}}\n {{{.}}}\n {{/reset}}{{/multiple}}\n
\n
\n\n'},n=function(t){return'\n\n'},a=function(t){return'\n{{#selected}}\n\n{{/selected}}\n"},o=function(t){return'\n{{#waitOptions}}\n
\n
\n \n {{{lang.loading}}}\n \n
\n
\n{{/waitOptions}}\n{{^waitOptions}}\n {{#options}}\n {{^hide}}\n
\n
\n {{'+t.optionText+'}}\n
\n
\n {{/hide}}\n {{/options}}\n {{^options}}\n
\n
\n \n {{{lang.noOptions}}}\n \n
\n
\n {{/options}}\n{{/waitOptions}}\n'},l=function(t){return'{{#selected}}
{{{removeIcon}}}
{{text}}
{{/selected}}'};t.tmpl={autocompleteDisplay:i,formSelect:n,formSelectOptions:a,optionGroup:e,options:o,label:l,get:function(e,i,n){return ax5.mustache.render(t.tmpl[e].call(this,n),i)}}}(); +"use strict";var _typeof="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t};(function(){var t,e,i=this,n=this,a=n?n.document:null,o=(n?n.document.documentElement:null,/^(["'](\\.|[^"\\\n\r])*?["']|[,:{}\[\]0-9.\-+Eaeflnr-u \n\r\t])+?$/),l=/^-ms-/,s=/[\-_]([\da-z])/gi,r=/([A-Z])/g,d=/\./,c=/[-|+]?[\D]/gi,u=/\D/gi,h=new RegExp("([0-9])([0-9][0-9][0-9][,.])"),p=/&/g,f=/=/,m=/[ ]+/g,g={};g.guid=1,g.getGuid=function(){return g.guid++},g.info=t=function(){function i(t,i){return t={href:n.location.href,param:n.location.search,referrer:a.referrer,pathname:n.location.pathname,hostname:n.location.hostname,port:n.location.port},i=t.href.split(/[\?#]/),t.param=t.param.replace("?",""),t.url=i[0],t.href.search("#")>-1&&(t.hashdata=e.last(i)),i=null,t.baseUrl=e.left(t.href,"?").replace(t.pathname,""),t}function o(e,i,n){return t.errorMsg&&t.errorMsg[e]?{className:e,errorCode:i,methodName:n,msg:t.errorMsg[e][i]}:{className:e,errorCode:i,methodName:n}}var l="1.3.66",s="",r=function(){console.error(e.toArray(arguments).join(":"))},d={BACKSPACE:8,TAB:9,RETURN:13,ESC:27,LEFT:37,UP:38,RIGHT:39,DOWN:40,DELETE:46,HOME:36,END:35,PAGEUP:33,PAGEDOWN:34,INSERT:45,SPACE:32},c=[{label:"SUN"},{label:"MON"},{label:"TUE"},{label:"WED"},{label:"THU"},{label:"FRI"},{label:"SAT"}],u=function(t,e,i,a,o,l){return n&&n.navigator?(t=navigator.userAgent.toLowerCase(),e=t.search(/mobile/g)!=-1,l,t.search(/iphone/g)!=-1?{name:"iphone",version:0,mobile:!0}:t.search(/ipad/g)!=-1?{name:"ipad",version:0,mobile:!0}:t.search(/android/g)!=-1?(a=/(android)[ \/]([\w.]+)/.exec(t)||[],l=a[2]||"0",{name:"android",version:l,mobile:e}):(i="",a=/(opr)[ \/]([\w.]+)/.exec(t)||/(chrome)[ \/]([\w.]+)/.exec(t)||/(webkit)[ \/]([\w.]+)/.exec(t)||/(msie) ([\w.]+)/.exec(t)||t.indexOf("compatible")<0&&/(mozilla)(?:.*? rv:([\w.]+)|)/.exec(t)||[],o=a[1]||"",l=a[2]||"0","msie"==o&&(o="ie"),{name:o,version:l,mobile:e})):{}}(),h=!("undefined"==typeof window||"undefined"==typeof navigator||!n.document),p=n&&/Firefox/i.test(navigator.userAgent)?"DOMMouseScroll":"mousewheel",f={},m=!!n&&("ontouchstart"in n||navigator.maxTouchPoints>0||navigator.msMaxTouchPoints>0),g=!!n&&(n.FileReader&&n.File&&n.FileList&&n.Blob);return{errorMsg:f,version:l,baseUrl:s,onerror:r,eventKeys:d,weekNames:c,browser:u,isBrowser:h,supportTouch:m,supportFileApi:g,wheelEnm:p,urlUtil:i,getError:o}}(),g.util=e=function(){function x(t,e){if(Q(t))return[];var i,n=0,a=t.length,o=void 0===a||"function"==typeof t;if(o){for(i in t)if("undefined"!=typeof t[i]&&e.call(t[i],i,t[i])===!1)break}else for(;n0&&("undefined"==typeof t[n]||(a=e.call(i,a,t[--n]))!==!1););return a}function k(t,e){if(Q(t))return[];var i,n,a=0,o=t.length,l=[];if(j(t))for(i in t)"undefined"!=typeof t[i]&&(n=e.call(t[i],i,t[i]))&&l.push(t[i]);else for(;a0&&(e+=","),e+=C(t[i]);e+="]"}else if(g.util.isObject(t)){e+="{";var a=[];x(t,function(t,e){a.push('"'+t+'": '+C(e))}),e+=a.join(", "),e+="}"}else e=g.util.isString(t)?'"'+t+'"':g.util.isNumber(t)?t:g.util.isUndefined(t)?"undefined":g.util.isFunction(t)?'"{Function}"':t;return e}function $(t,e){if(!e&&!o.test(t))return{error:500,msg:"syntax error"};try{return new Function("","return "+t)()}catch(i){return{error:500,msg:"syntax error"}}}function S(t){var e;return null!=t&&t==t.window?e="window":t&&1==t.nodeType?e="element":t&&11==t.nodeType?e="fragment":null===t?e="null":"undefined"==typeof t?e="undefined":"[object Object]"==xt.call(t)?e="object":"[object Array]"==xt.call(t)?e="array":"[object String]"==xt.call(t)?e="string":"[object Number]"==xt.call(t)?e="number":"[object NodeList]"==xt.call(t)?e="nodelist":"function"==typeof t&&(e="function"),e}function T(t){return null!=t&&t==t.window}function E(t){return!(!t||1!=t.nodeType&&11!=t.nodeType)}function j(t){return"[object Object]"==xt.call(t)}function N(t){return"[object Array]"==xt.call(t)}function D(t){return"function"==typeof t}function z(t){return"[object String]"==xt.call(t)}function K(t){return"[object Number]"==xt.call(t)}function P(t){return!!("[object NodeList]"==xt.call(t)||"undefined"!=typeof t&&t&&t[0]&&1==t[0].nodeType)}function R(t){return"undefined"==typeof t}function Q(t){return"undefined"==typeof t||null===t||""===t}function q(t){return t instanceof Date&&!isNaN(t.valueOf())}function A(t){var e=!1;if(t)if(t instanceof Date&&!isNaN(t.valueOf()))e=!0;else{if(t.length>7&&nt(t)instanceof Date)return!0;if(t=t.replace(/\D/g,""),t.length>7){var i=t.substr(4,2),n=t.substr(6,2);t=nt(t),t.getMonth()==i-1&&t.getDate()==n&&(e=!0)}}else;return e}function M(t){if(j(t)){var e=Object.keys(t),i={};return i[e[0]]=t[e[0]],i}return N(t)?t[0]:void console.error("ax5.util.object.first","argument type error")}function O(t){if(j(t)){var e=Object.keys(t),i={};return i[e[e.length-1]]=t[e[e.length-1]],i}return N(t)?t[t.length-1]:void console.error("ax5.util.object.last","argument type error")}function F(t,e,i,n){var o;return"number"==typeof i&&(o=new Date,o.setDate(o.getDate()+i)),n=n||{},a.cookie=[escape(t),"=",escape(e),o?"; expires="+o.toUTCString():"",n.path?"; path="+n.path:"",n.domain?"; domain="+n.domain:"",n.secure?"; secure":""].join("")}function H(t){for(var e=t+"=",i=a.cookie.split(";"),n=0,o=i.length;n-1?t.substr(0,t.indexOf(e)):"":K(e)?t.substr(0,e):""}function B(t,e){return"undefined"==typeof t||"undefined"==typeof e?"":(t=""+t,z(e)?t.lastIndexOf(e)>-1?t.substr(t.lastIndexOf(e)+1):"":K(e)?t.substr(t.length-e):"")}function V(t){return t.replace(l,"ms-").replace(s,function(t,e){return e.toUpperCase()})}function W(t){return V(t).replace(r,function(t,e){return"-"+e.toLowerCase()})}function U(t,e){var i,n=(""+t).split(d),a=Number(n[0])<0||"-0"==n[0],o=0;return n[0]=n[0].replace(c,""),n[1]?(n[1]=n[1].replace(u,""),o=Number(n[0]+"."+n[1])||0):o=Number(n[0])||0,i=a?-o:o,x(e,function(t,e){"round"==t&&(i=K(e)?e<0?+(Math.round(i+"e-"+Math.abs(e))+"e+"+Math.abs(e)):+(Math.round(i+"e+"+e)+"e-"+e):Math.round(i)),"floor"==t&&(i=Math.floor(i)),"ceil"==t?i=Math.ceil(i):"money"==t?i=function(t){var e=""+t;if(isNaN(e)||""==e)return"";var i=e.split(".");i[0]+=".";do i[0]=i[0].replace(h,"$1,$2");while(h.test(i[0]));return i.length>1?i.join(""):i[0].split(".")[0]}(i):"abs"==t?i=Math.abs(Number(i)):"byte"==t&&(i=function(t){t=Number(i);var e="KB",n=t/1024;return n/1024>1&&(e="MB",n/=1024),n/1024>1&&(e="GB",n/=1024),U(n,{round:1})+e}(i))}),i}function Y(t){return"undefined"!=typeof t.length?Array.prototype.slice.call(t):[]}function X(t,e){var i=e.length,n=t.length,a=0;if("number"==typeof i)for(;a15)f.test(e)||p.test(e)?e=new Date(e):(r=e.split(/ /g),u=r[0].split(/\D/g),n=u[0],a=parseFloat(u[1]),o=parseFloat(u[2]),c=r[1]||"09:00",d=c.substring(0,5).split(":"),l=parseFloat(d[0]),s=parseFloat(d[1]),"AM"!==B(c,2)&&"PM"!==B(c,2)||(l+=12),e=it(n,a-1,o,l,s));else if(14==e.length)h=e.replace(/\D/g,""),e=it(h.substr(0,4),h.substr(4,2)-1,U(h.substr(6,2)),U(h.substr(8,2)),U(h.substr(10,2)),U(h.substr(12,2)));else if(e.length>7)h=e.replace(/\D/g,""),e=it(h.substr(0,4),h.substr(4,2)-1,U(h.substr(6,2)));else if(e.length>4)h=e.replace(/\D/g,""),e=it(h.substr(0,4),h.substr(4,2)-1,1);else{if(e.length>2)return h=e.replace(/\D/g,""),it(h.substr(0,4),h.substr(4,2)-1,1);e=new Date}return"undefined"==typeof i?e:("add"in i&&(e=function(t,e){var i,n,a,o,l=864e5;return"undefined"!=typeof e.d?t.setTime(t.getTime()+e.d*l):"undefined"!=typeof e.m?(i=t.getFullYear(),n=t.getMonth(),a=t.getDate(),i+=parseInt(e.m/12),n+=e.m%12,o=lt(i,n),o\&\"]/gm,function(t){switch(t){case"<":return"<";case">":return">";case"&":return"&";case'"':return""";default:return t}}):""}function mt(t){return"[object String]"!=xt.call(t)?t:t?t.replace(/(<)|(>)|(&)|(")/gm,function(t){switch(t){case"<":return"<";case">":return">";case"&":return"&";case""":return'"';default:return t}}):""}function gt(t){function e(t){this.value=t,this.toString=function(){return this.value},this.format=function(){for(var t=[],e=0,i=arguments.length;e>>0;if("function"!=typeof t)throw TypeError();var n,a=arguments[1];for(n=0;ni));n+=1);return t.removeRule(0),l};document.querySelectorAll=function(t){return e(t,1/0)},document.querySelector=function(t){return e(t,1)[0]||null}}}(),String.prototype.trim||!function(){String.prototype.trim=function(){return this.replace(e,"")}}(),window.JSON||(window.JSON={parse:function(t){return new Function("","return "+t)()},stringify:function(){var t,e=/["]/g;return t=function(i){var n,a,o;switch(n="undefined"==typeof i?"undefined":_typeof(i)){case"string":return'"'+i.replace(e,'\\"')+'"';case"number":case"boolean":return i.toString();case"undefined":return"undefined";case"function":return'""';case"object":if(!i)return"null";if(n="",i.splice){for(a=0,o=i.length;a=9)return!1;var t=Array.prototype.splice;Array.prototype.splice=function(){var e=Array.prototype.slice.call(arguments);return"undefined"==typeof e[1]&&(e[1]=this.length-e[0]),t.apply(this,e)}}(),function(){var t=Array.prototype.slice;try{t.call(document.documentElement)}catch(e){Array.prototype.slice=function(e,i){if(i="undefined"!=typeof i?i:this.length,"[object Array]"===Object.prototype.toString.call(this))return t.call(this,e,i);var n,a,o=[],l=this.length,s=e||0;s=s>=0?s:Math.max(0,l+s);var r="number"==typeof i?Math.min(i,l):l;if(i<0&&(r=l+i),a=r-s,a>0)if(o=new Array(a),this.charAt)for(n=0;n"'\/]/g,function(t){return v[t]})}function r(e,i){function a(){if(x&&!v)for(;g.length;)delete f[g.pop()];else g=[];x=!1,v=!1}function o(t){if("string"==typeof t&&(t=t.split(y,2)),!m(t)||2!==t.length)throw new Error("Invalid tags: "+t);s=new RegExp(n(t[0])+"\\s*"),r=new RegExp("\\s*"+n(t[1])),h=new RegExp("\\s*"+n("}"+t[1]))}if(!e)return[];var s,r,h,p=[],f=[],g=[],x=!1,v=!1;o(i||t.tags);for(var k,C,$,S,T,E,j=new u(e);!j.eos();){if(k=j.pos,$=j.scanUntil(s))for(var N=0,D=$.length;N0?o[o.length-1][4]:n;break;default:a.push(e)}return n}function u(t){this.string=t,this.tail=t,this.pos=0}function h(t,e){this.view=t,this.cache={".":this.view,"@each":function(){var t=[];for(var e in this)t.push({"@key":e,"@value":this[e]});return t}},this.parent=e}function p(){this.cache={}}var f=Object.prototype.toString,m=Array.isArray||function(t){return"[object Array]"===f.call(t)},g=RegExp.prototype.test,x=/\S/,v={"&":"&","<":"<",">":">",'"':""","'":"'","/":"/"},b=/\s*/,y=/\s+/,w=/\s*=/,_=/\s*\}/,I=/#|\^|\/|>|\{|&|=|!/;u.prototype.eos=function(){return""===this.tail},u.prototype.scan=function(t){var e=this.tail.match(t);if(!e||0!==e.index)return"";var i=e[0];return this.tail=this.tail.substring(i.length),this.pos+=i.length,i},u.prototype.scanUntil=function(t){var e,i=this.tail.search(t);switch(i){case-1:e=this.tail,this.tail="";break;case 0:e="";break;default:e=this.tail.substring(0,i),this.tail=this.tail.substring(i)}return this.pos+=e.length,e},h.prototype.push=function(t){return new h(t,this)},h.prototype.lookup=function(t){var i,n=this.cache;if(n.hasOwnProperty(t))i=n[t];else{for(var o,l,s=this,r=!1;s;){if(t.indexOf(".")>0)for(i=s.view,o=t.split("."),l=0;null!=i&&l"===o?l=this.renderPartial(a,e,i,n):"&"===o?l=this.unescapedValue(a,e):"name"===o?l=this.escapedValue(a,e):"text"===o&&(l=this.rawValue(a)),void 0!==l&&(s+=l);return s},p.prototype.renderSection=function(t,i,n,a){function o(t){return l.render(t,i,n)}var l=this,s="",r=i.lookup(t[1]);if(r){if(m(r))for(var d=0,c=r.length;d"),input:i.input,btns:i.btns,_crlf:function(){return this.replace(/\n/g,"
")}};try{return t.tmpl.get.call(this,"dialogDisplay",a)}finally{a=null}},s=function(t,e){var i,a={};t.id=t.id||n.id,i={width:t.width},jQuery(document.body).append(l.call(this,t.id,t)),this.activeDialog=jQuery("#"+t.id),this.activeDialog.css({width:i.width}),t.height=i.height=this.activeDialog.height(),"undefined"==typeof t.position||"center"===t.position?(a.top=jQuery(window).height()/2-i.height/2,a.left=jQuery(window).width()/2-i.width/2):(a.left=t.position.left||0,a.top=t.position.top||0),n.zIndex&&(a["z-index"]=n.zIndex),this.activeDialog.css(a),"prompt"===t.dialogType?this.activeDialog.find("[data-dialog-prompt]").get(0).focus():this.activeDialog.find("[data-dialog-btn]").get(0).focus(),this.activeDialog.find("[data-dialog-btn]").on(n.clickEventName,function(i){d.call(this,i||window.event,t,e)}.bind(this)),jQuery(window).bind("keydown.ax5dialog",function(i){c.call(this,i||window.event,t,e)}.bind(this)),jQuery(window).bind("resize.ax5dialog",function(t){r.call(this,t||window.event)}.bind(this)),o.call(this,t,{self:this,state:"open"}),a=null,i=null},r=function(t){if(!this.activeDialog)return this; +var e=a.dialogConfig,i={width:e.width,height:e.height};return"undefined"==typeof e.position||"center"===e.position?(i.top=window.innerHeight/2-i.height/2,i.left=window.innerWidth/2-i.width/2):(i.left=e.position.left||0,i.top=e.position.top||0),i.left<0&&(i.left=0),i.top<0&&(i.top=0),this.activeDialog.css(i),e=null,i=null,this},d=function(t,e,n,a,o){var l;if(t.srcElement&&(t.target=t.srcElement),a=i.findParentNode(t.target,function(t){if(t.getAttribute("data-dialog-btn"))return!0})){if(o=a.getAttribute("data-dialog-btn"),l={self:this,key:o,value:e.btns[o],dialogId:e.id,btnTarget:a},"prompt"===e.dialogType){var s=null;for(var r in e.input)if(l[r]=this.activeDialog.find("[data-dialog-prompt="+r+"]").val(),""==l[r]||null==l[r]){s=r;break}}if(e.btns[o].onClick)e.btns[o].onClick.call(l,o);else if("alert"===e.dialogType)n&&n.call(l,o),this.close({doNotCallback:!0});else if("confirm"===e.dialogType)n&&n.call(l,o),this.close({doNotCallback:!0});else if("prompt"===e.dialogType){if("ok"===o&&s)return this.activeDialog.find('[data-dialog-prompt="'+s+'"]').get(0).focus(),!1;n&&n.call(l,o),this.close({doNotCallback:!0})}}l=null,e=null,n=null,a=null,o=null},c=function(t,e,i,n,a){var o,l=null;if(t.keyCode==ax5.info.eventKeys.ESC&&this.close(),"prompt"===e.dialogType&&t.keyCode==ax5.info.eventKeys.RETURN){o={self:this,key:a,value:e.btns[a],dialogId:e.id,btnTarget:n};for(var s in e.input)if(o[s]=this.activeDialog.find("[data-dialog-prompt="+s+"]").val(),""==o[s]||null==o[s]){l=s;break}if(l)return o=null,l=null,!1;i&&i.call(o,a),this.close({doNotCallback:!0})}o=null,l=null,e=null,i=null,n=null,a=null};this.init=function(){this.onStateChanged=n.onStateChanged},this.alert=function(t,e,o){return i.isString(t)&&(t={title:n.title,msg:t}),this.activeDialog?(o?console.log(ax5.info.getError("ax5dialog","501","alert")):setTimeout(function(){this.alert(t,e,1)}.bind(this),Number(n.animateTime)+100),this):(a.dialogConfig={},jQuery.extend(!0,a.dialogConfig,n,t),t=a.dialogConfig,t.dialogType="alert",t.theme=t.theme||n.theme||"",t.callback=e,"undefined"==typeof t.btns&&(t.btns={ok:{label:n.lang.ok,theme:t.theme}}),s.call(this,t,e),this)},this.confirm=function(t,e,o){return i.isString(t)&&(t={title:n.title,msg:t}),this.activeDialog?(o?console.log(ax5.info.getError("ax5dialog","501","confirm")):setTimeout(function(){this.confirm(t,e,1)}.bind(this),Number(n.animateTime)+100),this):(a.dialogConfig={},jQuery.extend(!0,a.dialogConfig,n,t),t=a.dialogConfig,t.dialogType="confirm",t.theme=t.theme||n.theme||"",t.callback=e,"undefined"==typeof t.btns&&(t.btns={ok:{label:n.lang.ok,theme:t.theme},cancel:{label:n.lang.cancel}}),s.call(this,t,e),this)},this.prompt=function(t,e,o){return i.isString(t)&&(t={title:n.title,msg:t}),this.activeDialog?(o?console.log(ax5.info.getError("ax5dialog","501","prompt")):setTimeout(function(){this.prompt(t,e,1)}.bind(this),Number(n.animateTime)+100),this):(a.dialogConfig={},jQuery.extend(!0,a.dialogConfig,n,t),t=a.dialogConfig,t.dialogType="prompt",t.theme=t.theme||n.theme||"",t.callback=e,"undefined"==typeof t.input&&(t.input={value:{label:""}}),"undefined"==typeof t.btns&&(t.btns={ok:{label:n.lang.ok,theme:t.theme},cancel:{label:n.lang.cancel}}),s.call(this,t,e),this)},this.close=function(t){var e,i;return this.activeDialog&&(e=a.dialogConfig,this.activeDialog.addClass("destroy"),jQuery(window).unbind("keydown.ax5dialog"),jQuery(window).unbind("resize.ax5dialog"),setTimeout(function(){this.activeDialog&&(this.activeDialog.remove(),this.activeDialog=null),i={self:this,state:"close",dialogId:e.id},!e.callback||t&&t.doNotCallback||e.callback.call(i),e&&e.onStateChanged?e.onStateChanged.call(i,i):this.onStateChanged&&this.onStateChanged.call(i,i),e=null,i=null}.bind(this),n.animateTime)),this},this.main=function(){e.dialog_instance=e.dialog_instance||[],e.dialog_instance.push(this),arguments&&i.isObject(arguments[0])&&this.setConfig(arguments[0])}.apply(this,arguments)};return n}()),t=ax5.ui.dialog}(),function(){var t=ax5.ui.dialog,e=function(t){return' \n
\n
\n {{{title}}}\n
\n
\n
{{{msg}}}
\n \n {{#input}}\n
\n {{#@each}}\n
\n {{#@value.label}}\n \n {{/@value.label}}\n \n {{#@value.help}}\n

{{#_crlf}}{{.}}{{/_crlf}}

\n {{/@value.help}}\n
\n {{/@each}}\n
\n {{/input}}\n \n
\n
\n {{#btns}}\n {{#@each}}\n \n {{/@each}}\n {{/btns}}\n
\n
\n
\n
\n '};t.tmpl={dialogDisplay:e,get:function(e,i,n){return ax5.mustache.render(t.tmpl[e].call(this,n),i)}}}(),function(){var t,e=ax5.ui,i=ax5.util;e.addClass({className:"mask",version:"1.3.66"},function(){var n=function(){var n,a=this;this.instanceId=ax5.getGuid(),this.config={theme:"",target:jQuery(document.body).get(0),animateTime:250},this.maskContent="",this.status="off",n=this.config;var o=function(t,e){return t&&t.onStateChanged?t.onStateChanged.call(e,e):this.onStateChanged&&this.onStateChanged.call(e,e),t=null,e=null,!0},l=function(e){return"undefined"==typeof e.templateName&&(e.templateName="defaultMask"),t.tmpl.get.call(this,e.templateName,e)},s=function(t){this.maskContent=t};this.init=function(){this.onStateChanged=n.onStateChanged,this.onClick=n.onClick,this.config.content&&s.call(this,this.config.content)},this.open=function(t){"on"===this.status&&this.close(),t&&t.content&&s.call(this,t.content),t&&"undefined"==typeof t.templateName&&(t.templateName="defaultMask"),a.maskConfig={},jQuery.extend(!0,a.maskConfig,this.config,t);var e,i=a.maskConfig,n=i.target,r=jQuery(n),d="ax-mask-"+ax5.getGuid(),c={},u={},h=i.templateName,p=l({theme:i.theme,maskId:d,body:this.maskContent,templateName:h});return jQuery(document.body).append(p),n&&n!==jQuery(document.body).get(0)&&(c={position:i.position||"absolute",left:r.offset().left,top:r.offset().top,width:r.outerWidth(),height:r.outerHeight()},"undefined"!=typeof a.maskConfig.zIndex&&(c["z-index"]=a.maskConfig.zIndex),r.addClass("ax-masking"),jQuery(window).bind("resize.ax5mask-"+this.instanceId,function(t){this.align()}.bind(this))),this.$mask=e=jQuery("#"+d),this.$target=r,this.status="on",e.css(c),i.onClick&&e.on("click",function(t){u={self:a,state:"open",type:"click"},a.maskConfig.onClick.call(u,u)}),o.call(this,null,{self:this,state:"open"}),t=null,i=null,n=null,r=null,d=null,e=null,c=null,u=null,h=null,p=null,this},this.close=function(t){var e=this;return this.$mask&&!function(){var i=function(){this.status="off",this.$mask.remove(),this.$target.removeClass("ax-masking"),o.call(this,null,{self:this,state:"close"}),jQuery(window).unbind("resize.ax5mask-"+this.instanceId)};t?setTimeout(function(){i.call(this)}.bind(e),t):i.call(e)}(),this},this.fadeOut=function(){var t=this;return this.$mask&&!function(){var e=function(){this.status="off",this.$mask.remove(),this.$target.removeClass("ax-masking"),o.call(this,null,{self:this,state:"close"}),jQuery(window).unbind("resize.ax5mask-"+this.instanceId)};t.$mask.addClass("fade-out"),setTimeout(function(){e.call(this)}.bind(t),n.animateTime)}(),this},this.align=function(){if(this.maskConfig&&this.maskConfig.target&&this.maskConfig.target!==jQuery(document.body).get(0))try{var t={position:this.maskConfig.position||"absolute",left:this.$target.offset().left,top:this.$target.offset().top,width:this.$target.outerWidth(),height:this.$target.outerHeight()};this.$mask.css(t)}catch(e){}return this},this.pullRequest=function(){console.log("test pullRequest01"),console.log("test pullRequest02")},this.main=function(){e.mask_instance=e.mask_instance||[],e.mask_instance.push(this),arguments&&i.isObject(arguments[0])&&this.setConfig(arguments[0])}.apply(this,arguments)};return n}()),t=ax5.ui.mask}(),function(){var t=ax5.ui.mask,e=function(t){return'\n
\n
\n
\n
\n {{{body}}}\n
\n
\n
\n '};t.tmpl={defaultMask:e,get:function(e,i,n){return ax5.mustache.render(t.tmpl[e].call(this,n),i)}}}(),function(){var t,e=ax5.ui,i=ax5.util;e.addClass({className:"toast",version:"1.3.66"},function(){var n=function(){var n,a=this,o=0,l=null;this.instanceId=ax5.getGuid(),this.config={clickEventName:"click",theme:"default",width:300,icon:"",closeIcon:"",msg:"",lang:{ok:"ok",cancel:"cancel"},displayTime:3e3,animateTime:250,containerPosition:"bottom-left"},this.toastContainer=null,this.queue=[],n=this.config;var s=function(t,e){return t&&t.onStateChanged?t.onStateChanged.call(e,e):this.onStateChanged&&this.onStateChanged.call(e,e),t=null,e=null,!0},r=function(e,i){var n={toastId:e,theme:i.theme,icon:i.icon,msg:(i.msg||"").replace(/\n/g,"
"),btns:i.btns,closeIcon:i.closeIcon};try{return t.tmpl.get.call(this,"toastDisplay",n)}finally{e=null,n=null}},d=function(t,e){l&&clearTimeout(l);var d,u={width:t.width};return t.id="ax5-toast-"+a.containerId+"-"+ ++o,jQuery("#"+t.id).get(0)?this:("bottom"==i.left(n.containerPosition,"-")?this.toastContainer.append(r(t.id,t)):this.toastContainer.prepend(r(t.id,t)),d=jQuery("#"+t.id),d.css({width:u.width}),t.toastBox=d,this.queue.push(t),s.call(this,t,{self:this,state:"open",toastId:t.id}),"push"===t.toastType?(setTimeout(function(){this.close(t,e)}.bind(this),n.displayTime),d.find("[data-ax-toast-btn]").on(n.clickEventName,function(i){c.call(this,i||window.event,t,d,e)}.bind(this))):"confirm"===t.toastType&&d.find("[data-ax-toast-btn]").on(n.clickEventName,function(i){c.call(this,i||window.event,t,d,e)}.bind(this)),void(u=null))},c=function(t,e,n,a,o,l){if(o=i.findParentNode(t.target,function(t){if(t.getAttribute("data-ax-toast-btn"))return!0})){l=o.getAttribute("data-ax-toast-btn");var s={key:l,value:e.btns?e.btns[l]:l,toastId:e.id,btn_target:o};e.btns&&e.btns[l].onClick?e.btns[l].onClick.call(s,l):"push"===e.toastType?(a&&a.call(s,l),this.close(e,a)):"confirm"===e.toastType&&(a&&a.call(s,l),this.close(e,a))}t=null,e=null,n=null,a=null,o=null,l=null};this.init=function(){this.onStateChanged=n.onStateChanged,a.containerId=ax5.getGuid();var t=[];n.zIndex&&t.push("z-index:"+n.zIndex),jQuery(document.body).append('
'),this.toastContainer=jQuery('[data-toast-container="'+a.containerId+'"]')},this.push=function(t,e){return a.containerId||this.init(),i.isString(t)&&(t={title:n.title,msg:t}),t.toastType="push",a.dialogConfig={},jQuery.extend(!0,a.dialogConfig,n,t),t=a.dialogConfig,d.call(this,t,e),t=null,e=null,this},this.confirm=function(t,e){return a.containerId||this.init(),i.isString(t)&&(t={title:n.title,msg:t}),t.toastType="confirm",a.dialogConfig={},jQuery.extend(!0,a.dialogConfig,n,t),t=a.dialogConfig,"undefined"==typeof t.btns&&(t.btns={ok:{label:n.lang.ok,theme:t.theme}}),d.call(this,t,e),t=null,e=null,this},this.close=function(t,e){"undefined"==typeof t&&(t=i.last(this.queue));var a=t.toastBox;return a.addClass("push"==t.toastType?"removed":"destroy"),this.queue=i.filter(this.queue,function(){return t.id!=this.id}),setTimeout(function(){var i={toastId:t.id};a.remove(),e&&e.call(i),i={self:this,state:"close",toastId:t.id},s.call(this,t,i),0===this.queue.length&&(l&&clearTimeout(l),l=setTimeout(function(){0===this.queue.length&&(o=0)}.bind(this),3e3)),i=null,t=null,e=null,a=null}.bind(this),n.animateTime),this},this.main=function(){e.toast_instance=e.toast_instance||[],e.toast_instance.push(this),arguments&&i.isObject(arguments[0])&&this.setConfig(arguments[0])}.apply(this,arguments)};return n}()),t=ax5.ui.toast}(),function(){var t=ax5.ui.toast,e=function(t){return'\n
\n {{#icon}}\n
{{{.}}}
\n {{/icon}}\n
{{{msg}}}
\n {{#btns}}\n
\n
\n {{#@each}}\n \n {{/@each}}\n
\n
\n {{/btns}}\n {{^btns}}\n {{{closeIcon}}}\n {{/btns}}\n
\n
'};t.tmpl={toastDisplay:e,get:function(e,i,n){return ax5.mustache.render(t.tmpl[e].call(this,n),i)}}}(),function(){var t,e=ax5.ui,i=ax5.util;e.addClass({className:"modal",version:"1.3.66"},function(){var n=function(){var n=this,a=void 0,o={mousedown:ax5.info.supportTouch?"touchstart":"mousedown",mousemove:ax5.info.supportTouch?"touchmove":"mousemove",mouseup:ax5.info.supportTouch?"touchend":"mouseup"},l=function(t){var e=t;return"changedTouches"in t&&(e=t.changedTouches[0]),{clientX:e.clientX,clientY:e.clientY}};this.instanceId=ax5.getGuid(),this.config={id:"ax5-modal-"+this.instanceId,position:{left:"center",top:"middle",margin:10},minimizePosition:"bottom-right",clickEventName:"click",theme:"default",width:300,height:400,closeToEsc:!0,disableDrag:!1,animateTime:250},this.activeModal=null,this.watingModal=!1,this.$={},a=this.config;var s=function(t,e){return t&&t.onStateChanged?t.onStateChanged.call(e,e):this.onStateChanged&&this.onStateChanged.call(e,e),!0},r=function(e,i){var n={modalId:e,theme:i.theme,header:i.header,fullScreen:i.fullScreen?"fullscreen":"",styles:"",iframe:i.iframe,iframeLoadingMsg:i.iframeLoadingMsg};return i.zIndex&&(n.styles+="z-index:"+i.zIndex+";"),i.absolute&&(n.styles+="position:absolute;"),n.iframe&&"string"==typeof n.iframe.param&&(n.iframe.param=ax5.util.param(n.iframe.param)),t.tmpl.get.call(this,"content",n,{})},d=function(t,e){var d=void 0;jQuery(document.body).append(r.call(this,t.id,t)),this.activeModal=jQuery("#"+t.id),this.$={root:this.activeModal,header:this.activeModal.find('[data-modal-els="header"]'),body:this.activeModal.find('[data-modal-els="body"]')},t.iframe&&(this.$["iframe-wrap"]=this.activeModal.find('[data-modal-els="iframe-wrap"]'),this.$.iframe=this.activeModal.find('[data-modal-els="iframe"]'),this.$["iframe-form"]=this.activeModal.find('[data-modal-els="iframe-form"]'),this.$["iframe-loading"]=this.activeModal.find('[data-modal-els="iframe-loading"]')),this.align(),d={self:this,id:t.id,theme:t.theme,width:t.width,height:t.height,state:"open",$:this.$},t.iframe&&(this.$["iframe-wrap"].css({height:t.height}),this.$.iframe.css({height:t.height}),this.$["iframe-form"].attr({method:t.iframe.method}),this.$["iframe-form"].attr({target:t.id+"-frame"}),this.$["iframe-form"].attr({action:t.iframe.url}),this.$.iframe.on("load",function(){d.state="load",t.iframeLoadingMsg&&this.$["iframe-loading"].hide(),s.call(this,t,d)}.bind(this)),t.iframeLoadingMsg||this.$.iframe.show(),this.$["iframe-form"].submit()),e&&e.call(d),this.watingModal||s.call(this,t,d),t.closeToEsc&&jQuery(window).bind("keydown.ax-modal",function(t){u.call(this,t||window.event)}.bind(this)),jQuery(window).bind("resize.ax-modal",function(t){this.align(null,t||window.event)}.bind(this)),this.activeModal.find("[data-modal-header-btn]").on(a.clickEventName,function(e){c.call(this,e||window.event,t)}.bind(this)),this.$.header.bind(o.mousedown,function(e){if(t.isFullScreen)return!1;var a=i.findParentNode(e.target,function(t){if(t.getAttribute("data-modal-header-btn"))return!0});a||1==t.disableDrag||(n.mousePosition=l(e),p.on.call(n))}).bind("dragstart",function(t){return i.stopEvent(t),!1})},c=function(t,e,n,a,o){var l=void 0;t.srcElement&&(t.target=t.srcElement),a=i.findParentNode(t.target,function(t){if(t.getAttribute("data-modal-header-btn"))return!0}),a&&(o=a.getAttribute("data-modal-header-btn"),l={self:this,key:o,value:e.header.btns[o],dialogId:e.id,btnTarget:a},e.header.btns[o].onClick&&e.header.btns[o].onClick.call(l,o)),l=null,e=null,n=null,a=null,o=null},u=function(t){t.keyCode==ax5.info.eventKeys.ESC&&this.close()},h={"top-left":function(){this.align({left:"left",top:"top"})},"top-right":function(){this.align({left:"right",top:"top"})},"bottom-left":function(){this.align({left:"left",top:"bottom"})},"bottom-right":function(){this.align({left:"right",top:"bottom"})},"center-middle":function(){this.align({left:"center",top:"middle"})}},p={on:function(){var t=this.activeModal.css("z-index"),e=this.activeModal.position(),i={width:this.activeModal.outerWidth(),height:this.activeModal.outerHeight()},l={width:jQuery(window).width(),height:jQuery(window).height()},s=function(t){n.__dx=t.clientX-n.mousePosition.clientX,n.__dy=t.clientY-n.mousePosition.clientY;var a=0,o=l.width-i.width,s=0,r=l.height-i.height;return a>e.left+n.__dx?n.__dx=-e.left:oe.top+n.__dy?n.__dy=-e.top:r
'),n.resizer=jQuery('
'),n.resizerBg.css({zIndex:t}),n.resizer.css({left:e.left,top:e.top,width:i.width,height:i.height,zIndex:t+1}),jQuery(document.body).append(n.resizerBg).append(n.resizer),n.activeModal.addClass("draged")),jQuery(document.body).bind(o.mousemove+".ax5modal-"+a.id,function(t){n.resizer.css(s(t))}).bind(o.mouseup+".ax5layout-"+this.instanceId,function(t){p.off.call(n)}).bind("mouseleave.ax5layout-"+this.instanceId,function(t){p.off.call(n)}),jQuery(document.body).attr("unselectable","on").css("user-select","none").on("selectstart",!1)},off:function(){var t=function(){var t=this.activeModal.offset();t.left+=this.__dx-$(document).scrollLeft(),t.top+=this.__dy-$(document).scrollTop(),this.activeModal.css(t)};this.resizer&&(this.activeModal.removeClass("draged"),this.resizer.remove(),this.resizer=null,this.resizerBg.remove(),this.resizerBg=null,t.call(this)),jQuery(document.body).unbind(o.mousemove+".ax5modal-"+a.id).unbind(o.mouseup+".ax5modal-"+a.id).unbind("mouseleave.ax5modal-"+a.id),jQuery(document.body).removeAttr("unselectable").css("user-select","auto").off("selectstart")}};this.init=function(){this.onStateChanged=a.onStateChanged},this.open=function(t,e,i){return"undefined"==typeof i&&(i=0),this.activeModal?i<3&&(this.watingModal=!0,setTimeout(function(){this.open(t,e,i+1)}.bind(this),a.animateTime)):(t=n.modalConfig=jQuery.extend(!0,{},a,t),d.call(this,t,e),this.watingModal=!1),this},this.close=function(t){return this.activeModal&&(t=n.modalConfig,this.activeModal.addClass("destroy"),jQuery(window).unbind("keydown.ax-modal"),jQuery(window).unbind("resize.ax-modal"),setTimeout(function(){if(this.activeModal){if(t.iframe){var e=this.$.iframe;if(e){var i=e.get(0),n=i.contentDocument?i.contentDocument:i.contentWindow.document;try{$(n.body).children().each(function(){$(this).remove()})}catch(a){}n.innerHTML="",e.attr("src","about:blank").remove(),window.CollectGarbage&&window.CollectGarbage()}}this.activeModal.remove(),this.activeModal=null}this.watingModal||s.call(this,t,{self:this,state:"close"})}.bind(this),a.animateTime)),this.minimized=!1,this},this.minimize=function(){return function(t){if(this.minimized!==!0){var e=n.modalConfig;"undefined"==typeof t&&(t=a.minimizePosition),this.minimized=!0,this.$.body.hide(),n.modalConfig.originalHeight=e.height,n.modalConfig.height=0,h[t].call(this),s.call(this,e,{self:this,state:"minimize"})}return this}}(),this.maximize=function(){var t=n.modalConfig;return this.minimized&&(this.minimized=!1,this.$.body.show(),n.modalConfig.height=n.modalConfig.originalHeight,n.modalConfig.originalHeight=void 0,this.align({left:"center",top:"middle"}),s.call(this,t,{self:this,state:"restore"})),this},this.css=function(t){return this.activeModal&&!n.fullScreen&&(this.activeModal.css(t),t.width&&(n.modalConfig.width=this.activeModal.width()),t.height&&(n.modalConfig.height=this.activeModal.height(),this.$.iframe&&(this.$["iframe-wrap"].css({height:n.modalConfig.height}),this.$.iframe.css({height:n.modalConfig.height})))),this},this.setModalConfig=function(t){return n.modalConfig=jQuery.extend({},n.modalConfig,t),this.align(),this},this.align=function(){return function(t,e){if(!this.activeModal)return this;var a=n.modalConfig,o={width:a.width,height:a.height},l=a.isFullScreen=function(t){return"undefined"!=typeof t&&(i.isFunction(t)?t():void 0)}(a.fullScreen);return l?(a.header&&this.$.header.show(),o.width=jQuery(window).width(),o.height=a.height,o.left=0,o.top=0):(a.header&&this.$.header.show(),t&&jQuery.extend(!0,a.position,t),a.header?(a.headerHeight=this.$.header.outerHeight(),o.height+=a.headerHeight):a.headerHeight=0,"left"==a.position.left?o.left=a.position.margin||0:"right"==a.position.left?o.left=jQuery(window).width()-o.width-(a.position.margin||0):"center"==a.position.left?o.left=jQuery(window).width()/2-o.width/2:o.left=a.position.left||0,"top"==a.position.top?o.top=a.position.margin||0:"bottom"==a.position.top?o.top=jQuery(window).height()-o.height-(a.position.margin||0):"middle"==a.position.top?o.top=jQuery(window).height()/2-o.height/2:o.top=a.position.top||0,o.left<0&&(o.left=0),o.top<0&&(o.top=0)),this.activeModal.css(o),a.iframe&&(this.$["iframe-wrap"].css({height:o.height-a.headerHeight}),this.$.iframe.css({height:o.height-a.headerHeight})),this}}(),this.main=function(){e.modal_instance=e.modal_instance||[],e.modal_instance.push(this),arguments&&i.isObject(arguments[0])&&this.setConfig(arguments[0])}.apply(this,arguments)};return n}()),t=ax5.ui.modal}(),function(){var t=ax5.ui.modal,e=function(){return' \n
\n {{#header}}\n
\n {{{title}}}\n {{#btns}}\n
\n {{#@each}}\n \n {{/@each}}\n
\n {{/btns}}\n
\n {{/header}}\n
\n {{#iframe}}\n \n
\n
{{{iframeLoadingMsg}}}
\n \n
\n
\n \n {{#param}}\n {{#@each}}\n \n {{/@each}}\n {{/param}}\n
\n {{/iframe}}\n
\n
\n
\n '};t.tmpl={content:e,get:function(e,i,n){return ax5.mustache.render(t.tmpl[e].call(this,n),i)}}}(),function(){var t,e=ax5.ui,i=ax5.util;e.addClass({className:"calendar",version:"1.3.66"},function(){var n=function(){var n,a=this,o=1;this.instanceId=ax5.getGuid(),this.target=null,this.selection=[],this.selectionMap={},this.selectableMap={},this.markerMap={},this.printedDay={start:"",end:""},this.config={clickEventName:"click",theme:"default",startOfWeek:0,mode:"day",dateFormat:"yyyy-MM-dd",displayDate:new Date,animateTime:100,dimensions:{controlHeight:"40",controlButtonWidth:"40",colHeadHeight:"30",itemPadding:2},lang:{yearHeading:"Choose the year",monthHeading:"Choose the month",yearTmpl:"%s",months:ax5.info.months||["JAN","FEB","MAR","APR","MAY","JUN","JUL","AUG","SEP","OCT","NOV","DEC"],dayTmpl:"%s"},multipleSelect:!1,selectMode:"day",defaultMarkerTheme:"holiday",defaultPeriodTheme:"period"},n=this.config;var l=function(t,e){t&&t.onStateChanged?t.onStateChanged.call(e,e):this.onStateChanged&&this.onStateChanged.call(e,e),e=null},s=function(){var e=jQuery.extend(!0,{},n,{controlCSS:{},controlButtonCSS:{}});e.controlButtonCSS.height=e.controlCSS.height=i.cssNumber(n.dimensions.controlHeight),e.controlButtonCSS["line-height"]=e.controlCSS["line-height"]=i.cssNumber(n.dimensions.controlHeight),e.controlButtonCSS.width=i.cssNumber(n.dimensions.controlHeight),e.controlCSS=i.css(e.controlCSS),e.controlButtonCSS=i.css(e.controlButtonCSS);try{return t.tmpl.get.call(this,"frameTmpl",e)}finally{e=null}},r=function(){var t,e,a=i.date(n.displayDate),o="",l="";return n.control&&("day"==n.mode||"d"==n.mode?(o=n.control.yearTmpl?n.control.yearTmpl.replace("%s",a.getFullYear()):a.getFullYear(),l=n.control.monthTmpl?n.control.monthTmpl.replace("%s",n.lang.months[a.getMonth()]):n.lang.months[a.getMonth()],this.$["control-display"].html(function(){return n.control.yearFirst?''+o+''+l+"":''+l+''+o+""}())):"month"==n.mode||"m"==n.mode?(o=n.control.yearTmpl?n.control.yearTmpl.replace("%s",a.getFullYear()):a.getFullYear(),this.$["control-display"].html(''+o+"")):"year"!=n.mode&&"y"!=n.mode||(t=n.control.yearTmpl?n.control.yearTmpl.replace("%s",a.getFullYear()-10):a.getFullYear()-10,e=n.control.yearTmpl?n.control.yearTmpl.replace("%s",Number(a.getFullYear())+9):Number(a.getFullYear())+9,this.$["control-display"].html(t+" ~ "+e)),this.$["control-display"].find("[data-calendar-display]").on(n.clickEventName,function(t){var e,n=i.findParentNode(t.target,function(t){if(t.getAttribute("data-calendar-display"))return!0});n&&(e=n.getAttribute("data-calendar-display"),this.changeMode(e)),n=null,e=null}.bind(this))),a=null,o=null,l=null,t=null,e=null,this},d=function(e){var o,s,d,c,u,p,f=i.date(e),m=new Date(f.getFullYear(),f.getMonth(),1,12),g=n.displayDate,x=function(){var t=m.getDay();0==t&&(t=7),t-=n.startOfWeek;try{return i.date(m,{add:{d:-t}})}finally{t=null}}(),v=f.getMonth(),b={},y=this.$.body.width(),w=Math.floor(y*(6/7));for(n.dimensions.height&&(w=i.number(n.dimensions.height)-i.number(n.dimensions.colHeadHeight)),b.height=Math.floor(w/6)-2*i.number(n.dimensions.itemPadding)+"px",b["line-height"]=b.height,b.padding=i.cssNumber(n.dimensions.itemPadding),u={weekNames:[].concat(ax5.info.weekNames),list:[]},n.startOfWeek&&(u.weekNames=u.weekNames.concat(u.weekNames.slice(0,n.startOfWeek)).splice(n.startOfWeek)),u.weekNames.forEach(function(t){t.colHeadHeight=i.cssNumber(n.dimensions.colHeadHeight)}),o=x,s=0;s<6;){for(d=0;d<7;){c=(7+(d-n.startOfWeek))%7;var _=""+i.date(o,{"return":n.dateFormat}),I={row:s,col:d,isStartOfWeek:0==d,thisDate:""+_,thisDataLabel:n.lang.dayTmpl.replace("%s",o.getDate()),itemStyles:i.css(b),addClass:function(){var t="";return n.selectable?t+=a.selectableMap[_]?o.getMonth()==v?" live":"":" disable":o.getMonth()==v&&(t+=_==i.date(g,{"return":"yyyyMMdd"})?" focus":" live",0==o.getDay()&&(t+=" sunday"),6==o.getDay()&&(t+=" saturday")),t}()+" "+function(){return a.markerMap[_]?a.markerMap[_].theme||n.defaultMarkerTheme:""}()+" "+function(){return a.selectionMap[_]?"selected-day":""}()};u.list.push(I),d++,o=i.date(o,{add:{d:1}}),_=null,I=null}s++}p=t.tmpl.get.call(this,"dayTmpl",u),this.$.body.html(p),this.$.body.find("[data-calendar-item-date]").on(n.clickEventName,function(t){t=t||window.event,h.call(a,t,"date"),i.stopEvent(t)}),this.printedDay={start:x,end:o},l.call(this,null,{self:this,action:"printDay",printedDay:this.printedDay}),r.call(this),f=null,m=null,g=null,x=null,o=null,v=null,b=null,s=null,d=null,y=null,w=null,u=null,p=null},c=function(e){var o,s,d,c,u,p,f=i.date(e),m=f.getMonth(),g={},x=this.$.body.width(),v=Math.floor(x*(6/7));for(n.dimensions.height&&(v=i.number(n.dimensions.height)-i.number(n.dimensions.colHeadHeight)),g.height=Math.floor(v/4)-2*i.number(n.dimensions.itemPadding)+"px",g["line-height"]=g.height,g.padding=i.cssNumber(n.dimensions.itemPadding),u={colHeadHeight:i.cssNumber(n.dimensions.colHeadHeight),colHeadLabel:n.lang.monthHeading,list:[]},c=0,d=0,o=0;o<4;){for(s=0;s<3;){var b={row:o,col:s,isStartOfRow:0==s,thisMonth:f.getFullYear()+"-"+i.setDigit(d+1,2)+"-"+i.setDigit(f.getDate(),2),thisMonthLabel:n.lang.months[d],itemStyles:i.css(g),addClass:function(){return n.selectable?a.selectableMap[d]?"live":"disable":"live"}()+" "+function(){return d==m?"focus":""}()+" "+function(){return a.markerMap[d]?a.markerMap[d].theme||n.defaultMarkerTheme:""}()};u.list.push(b),d++,s++,b=null}o++}p=t.tmpl.get.call(this,"monthTmpl",u),this.$.body.html(p),this.$.body.find("[data-calendar-item-month]").on(n.clickEventName,function(t){t=t||window.event,h.call(a,t,"month"),i.stopEvent(t)}),this.printedDay={start:f.getFullYear()+"-"+i.setDigit(c+1,2),end:f.getFullYear()+"-"+i.setDigit(d,2)},l.call(this,null,{self:this,action:"printMonth",printedDay:this.printedDay}),r.call(this),f=null,m=null,g=null,o=null,s=null,d=null,c=null,x=null,v=null,u=null,p=null},u=function(e){var o,s,d,c,u,p,f=i.date(e),m=f.getFullYear(),g={},x=this.$.body.width(),v=Math.floor(x*(6/7));for(n.dimensions.height&&(v=i.number(n.dimensions.height)-i.number(n.dimensions.colHeadHeight)),g.height=Math.floor(v/5)-2*i.number(n.dimensions.itemPadding)+"px",g["line-height"]=g.height,g.padding=i.cssNumber(n.dimensions.itemPadding),u={colHeadHeight:i.cssNumber(n.dimensions.colHeadHeight),colHeadLabel:n.lang.yearHeading,list:[]},c=m-10,d=m-10,o=0;o<5;){for(s=0;s<4;){var b={row:o,col:s,isStartOfRow:0==s,thisYear:d+"-"+i.setDigit(f.getMonth()+1,2)+"-"+i.setDigit(f.getDate(),2),thisYearLabel:n.lang.yearTmpl.replace("%s",d),itemStyles:i.css(g),addClass:function(){return n.selectable?a.selectableMap[d]?"live":"disable":"live"}()+" "+function(){return d==m?"focus":""}()+" "+function(){return a.selectableMap[d]?a.selectableMap[d].theme||n.defaultMarkerTheme:""}()};u.list.push(b),d++,s++,b=null}o++}p=t.tmpl.get.call(this,"yearTmpl",u),this.$.body.html(p),this.$.body.find("[data-calendar-item-year]").on(n.clickEventName,function(t){t=t||window.event,h.call(this,t,"year"),i.stopEvent(t)}),this.printedDay={start:c,end:d-1},l.call(this,null,{self:this,action:"printYear",printedDay:this.printedDay}),r.call(this),f=null,m=null,g=null,o=null,s=null,d=null,c=null, +x=null,v=null,u=null,p=null},h=function(t,e,l,s){var r,d,c;e=e||"date",l=i.findParentNode(t.target,function(t){if(t.getAttribute("data-calendar-item-"+e))return!0}),l&&(s=l.getAttribute("data-calendar-item-"+e),d=i.date(s,{"return":n.dateFormat}),c=!0,o=n.multipleSelect?i.isNumber(n.multipleSelect)?n.multipleSelect:2:1,n.selectable&&(a.selectableMap[d]||(c=!1)),"date"==e?c&&(a.selection.length>=o&&(r=a.selection.splice(0,a.selection.length-(o-1)),r.forEach(function(t){a.$.body.find('[data-calendar-item-date="'+i.date(t,{"return":n.dateFormat})+'"]').removeClass("selected-day")})),jQuery(l).addClass("selected-day"),a.selection.push(s),a.onClick&&a.onClick.call({self:this,date:s,target:this.target,dateElement:l})):"month"==e?"month"==n.selectMode?c&&(a.selection.length>=o&&(r=a.selection.splice(0,a.selection.length-(o-1)),r.forEach(function(t){a.$.body.find('[data-calendar-item-month="'+i.date(t,{"return":"yyyy-MM-dd"})+'"]').removeClass("selected-month")})),jQuery(l).addClass("selected-month"),a.selection.push(s),a.onClick&&a.onClick.call({self:this,date:s,target:this.target,dateElement:l})):a.changeMode("day",s):"year"==e&&("year"==n.selectMode?c&&(a.selection.length>=o&&(r=a.selection.splice(0,a.selection.length-(o-1)),r.forEach(function(t){a.$.body.find('[data-calendar-item-year="'+i.date(t,{"return":"yyyy-MM-dd"})+'"]').removeClass("selected-year")})),jQuery(l).addClass("selected-year"),a.selection.push(s),a.onClick&&a.onClick.call({self:this,date:s,target:this.target,dateElement:l})):a.changeMode("month",s))),e=null,l=null,s=null,r=null,d=null,c=null},p=function(t,e,a){e=i.findParentNode(t.target,function(t){if(t.getAttribute("data-calendar-move"))return!0}),e&&(a=e.getAttribute("data-calendar-move"),"day"==n.mode||"d"==n.mode?("left"==a?n.displayDate=i.date(n.displayDate,{add:{m:-1}}):n.displayDate=i.date(n.displayDate,{add:{m:1}}),d.call(this,n.displayDate)):"month"==n.mode||"m"==n.mode?("left"==a?n.displayDate=i.date(n.displayDate,{add:{y:-1}}):n.displayDate=i.date(n.displayDate,{add:{y:1}}),c.call(this,n.displayDate)):"year"!=n.mode&&"y"!=n.mode||("left"==a?n.displayDate=i.date(n.displayDate,{add:{y:-10}}):n.displayDate=i.date(n.displayDate,{add:{y:10}}),u.call(this,n.displayDate))),e=null,a=null},f=function(){setTimeout(function(){if("day"===n.mode||"d"===n.mode)for(var t in this.markerMap)this.$.body.find('[data-calendar-item-date="'+t+'"]').addClass(this.markerMap[t].theme||n.defaultMarkerTheme)}.bind(this))},m=function(){setTimeout(function(){for(var t in this.selectionMap)this.$.body.find('[data-calendar-item-date="'+t+'"]').addClass("selected-day")}.bind(this))},g=function(){setTimeout(function(){if("day"===n.mode||"d"===n.mode)for(var t in this.periodMap)this.periodMap[t].label&&this.$.body.find('[data-calendar-item-date="'+t+'"]').find(".addon-footer").html(this.periodMap[t].label),this.$.body.find('[data-calendar-item-date="'+t+'"]').addClass(this.periodMap[t].theme)}.bind(this))},x=function(){if("day"===n.mode||"d"===n.mode)for(var t in this.periodMap)this.$.body.find('[data-calendar-item-date="'+t+'"]').find(".addon-footer").empty(),this.$.body.find('[data-calendar-item-date="'+t+'"]').removeClass(this.periodMap[t].theme)};this.init=function(){this.onStateChanged=n.onStateChanged,this.onClick=n.onClick,n.target||console.log(ax5.info.getError("ax5calendar","401","setConfig")),this.target=jQuery(n.target),n.displayDate=i.date(n.displayDate),this.target.html(s.call(this)),this.$={root:this.target.find('[data-calendar-els="root"]'),control:this.target.find('[data-calendar-els="control"]'),"control-display":this.target.find('[data-calendar-els="control-display"]'),body:this.target.find('[data-calendar-els="body"]')},n.control&&this.$.root.on(n.clickEventName,"[data-calendar-move]",function(t){p.call(this,t||window.event)}.bind(this)),n.selection&&this.setSelection(n.selection,!1),n.selectable&&this.setSelectable(n.selectable,!1),n.marker&&this.setMarker(n.marker,!1),setTimeout(function(){"day"===n.mode||"d"===n.mode?d.call(this,n.displayDate):"month"===n.mode||"m"===n.mode?c.call(this,n.displayDate):"year"!==n.mode&&"y"!==n.mode||u.call(this,n.displayDate)}.bind(this))},this.changeMode=function(t,e){return"undefined"!=typeof e&&(n.displayDate=e),t&&(n.mode=t),this.$.body.removeClass("fadein").addClass("fadeout"),setTimeout(function(){"day"==n.mode||"d"==n.mode?d.call(this,n.displayDate):"month"==n.mode||"m"==n.mode?c.call(this,n.displayDate):"year"!=n.mode&&"y"!=n.mode||u.call(this,n.displayDate),this.$.body.removeClass("fadeout").addClass("fadein")}.bind(this),n.animateTime),this},this.setSelection=function(){a.selectionMap={};var t={arr:function(t,e,o){return e={},i.isArray(t)?(a.selection=t=t.splice(0,o),t.forEach(function(t){i.isDate(t)&&(t=i.date(t,{"return":n.dateFormat})),e[t]=!0}),e):e}};return function(e,a){var l={};if(o=n.multipleSelect?i.isNumber(n.multipleSelect)?n.multipleSelect:2:1,n.selection=e){if(!i.isArray(e))return this;l=t.arr(e,{},o)}return this.selectionMap=jQuery.extend({},l),a!==!1&&m.call(this),l=null,this}}(),this.getSelection=function(){return this.selection},this.setSelectable=function(){a.selectableMap={};var t={arr:function(t,e){return e={},i.isArray(t)?(t.forEach(function(t){i.isDate(t)&&(t=i.date(t,{"return":n.dateFormat})),e[t]=!0}),e):e},obj:function(t,e){if(e={},i.isArray(t))return e;if(t.range)return e;for(var n in t)e[n]=t[n];return e},range:function(t,e){return e={},i.isArray(t)?e:t.range?(t.range.forEach(function(t){if(i.isDateFormat(t.from)&&i.isDateFormat(t.to))for(var a=i.date(t.from);a<=i.date(t.to);a.setDate(a.getDate()+1))e[i.date(a,{"return":n.dateFormat})]=!0;else for(var o=t.from;o<=t.to;o++)e[o]=!0}),e):e}};return function(e,a){var o,l={};if(n.selectable=e)if(i.isArray(e))l=t.arr(e);else{for(o in t)if(e[o]){l=t[o](e);break}0===Object.keys(l).length&&(l=t.obj(e))}return this.selectableMap=l,a!==!1&&this.changeMode(),this}}(),this.setMarker=function(){a.markerMap={};var t={obj:function(t,e){if(e={},i.isArray(t))return e;if(t.range)return e;for(var n in t)e[n]=t[n];return t=null,e},range:function(t,e){return e={},i.isArray(t)?e:t.range?(t.range.forEach(function(t){if(i.isDateFormat(t.from)&&i.isDateFormat(t.to))for(var a=i.date(t.from);a<=i.date(t.to);a.setDate(a.getDate()+1))e[i.date(a,{"return":n.dateFormat})]={theme:t.theme,label:t.label};else for(var o=t.from;o<=t.to;o++)e[o]={theme:t.theme,label:t.label}}),t=null,e):e}};return function(e,i){var a,o={};if(n.marker=e){for(a in t)if(e[a]){o=t[a](e);break}0===Object.keys(o).length&&(o=t.obj(e))}return this.markerMap=o,i!==!1&&f.call(this),this}}(),this.setPeriod=function(){a.periodMap={};var t={range:function(t,e){return e={},i.isArray(t)?e:t.range?(t.range.forEach(function(t){if(i.isDateFormat(t.from)&&i.isDateFormat(t.to))for(var a=new Date(i.date(t.from));a<=i.date(t.to);a.setDate(a.getDate()+1))a.getTime()==i.date(t.from).getTime()?e[i.date(a,{"return":n.dateFormat})]={theme:t.theme||n.defaultPeriodTheme,label:t.fromLabel}:a.getTime()==i.date(t.to).getTime()?e[i.date(a,{"return":n.dateFormat})]={theme:t.theme||n.defaultPeriodTheme,label:t.toLabel}:e[i.date(a,{"return":n.dateFormat})]={theme:t.theme||n.defaultPeriodTheme}}),t=null,e):e}};return function(e,i){var a={};return i!==!1&&x.call(this),(n.period=e)&&(a=t.range(e)),this.periodMap=a,i!==!1&&g.call(this),this}}(),this.main=function(){e.calendar_instance=e.calendar_instance||[],e.calendar_instance.push(this),arguments&&i.isObject(arguments[0])&&this.setConfig(arguments[0])}.apply(this,arguments)};return n}()),t=ax5.ui.calendar}(),function(){var t=ax5.ui.calendar,e=function(t){return'\n
\n {{#control}}\n \n {{/control}}\n
\n
\n '},i=function(t){return'\n \n \n \n {{#weekNames}}\n \n {{/weekNames}}\n \n \n \n \n {{#list}} \n {{#isStartOfWeek}}\n {{^@first}}\n \n \n {{/@first}}\n {{/isStartOfWeek}}\n \n {{/list}}\n \n \n
\n {{label}}\n
\n \n \n {{thisDataLabel}}\n \n \n
\n '},n=function(t){return'\n \n \n \n \n \n \n \n \n {{#list}} \n {{#isStartOfRow}}\n {{^@first}}\n \n \n {{/@first}}\n {{/isStartOfRow}}\n \n {{/list}}\n \n \n
\n {{colHeadLabel}}\n
\n \n \n {{thisMonthLabel}}\n \n \n
\n '},a=function(t){return'\n \n \n \n \n \n \n \n \n {{#list}} \n {{#isStartOfRow}}\n {{^@first}}\n \n \n {{/@first}}\n {{/isStartOfRow}}\n \n {{/list}}\n \n \n
\n {{colHeadLabel}}\n
\n \n \n {{thisYearLabel}}\n \n \n
\n '};t.tmpl={frameTmpl:e,dayTmpl:i,monthTmpl:n,yearTmpl:a,get:function(e,i,n){return ax5.mustache.render(t.tmpl[e].call(this,n),i)}}}(),function(){var t,e=ax5.ui,i=ax5.util;e.addClass({className:"picker",version:"1.3.66"},function(){var e=function(){var e=this,n=void 0;this.instanceId=ax5.getGuid(),this.config={clickEventName:"click",theme:"default",title:"",lang:{ok:"ok",cancel:"cancel"},animateTime:100,calendar:{multipleSelect:!1,control:{left:ax5.def.picker.date_leftArrow||"←",yearTmpl:ax5.def.picker.date_yearTmpl||"%s",monthTmpl:ax5.def.picker.date_monthTmpl||"%s",right:ax5.def.picker.date_rightArrow||"→",yearFirst:!0}}},this.queue=[],this.activePicker=null,this.activePickerQueueIndex=-1,this.openTimer=null,this.closeTimer=null,n=this.config;var a=function(t,e){return t&&t.onStateChanged?t.onStateChanged.call(e,e):this.onStateChanged&&this.onStateChanged.call(e,e),!0},o=function(){var t={focus:function(t,e){this.open(t)},click:function(t,e){this.open(t)}},e={"@fn":function(t,e){var i=this.queue[t],a=e.length,o={inputLength:a||1};a>1&&(o.btns={ok:{label:n.lang.ok,theme:n.theme}}),this.queue[t]=jQuery.extend(!0,o,i),o=null,a=null},date:function(t,e){var i=this.queue[t],a=i.content?i.content.width||270:270,o=i.content?i.content.margin||5:5,l=e.length,s={contentWidth:a*l+(l-1)*o,content:{width:a,margin:o},inputLength:l||1};l>1&&!i.btns&&(s.btns={ok:{label:n.lang.ok,theme:n.theme}}),this.queue[t]=jQuery.extend(!0,s,i),a=null,o=null,s=null,l=null},"secure-num":function(t,e){var i=this.queue[t],n=e.length,a={inputLength:n||1};this.queue[t]=jQuery.extend(!0,a,i),a=null,n=null},keyboard:function(t,e){var i=this.queue[t],n=e.length,a={inputLength:n||1};this.queue[t]=jQuery.extend(!0,a,i),a=null,n=null},numpad:function(t,e){var i=this.queue[t],n=e.length,a={inputLength:n||1};this.queue[t]=jQuery.extend(!0,a,i),a=null,n=null}};return function(n){var a,o=this.queue[n];if(!o.content)return console.log(ax5.info.getError("ax5picker","501","bind")),this;if(a="INPUT"==o.$target.get(0).tagName.toUpperCase()?o.$target:o.$target.find("input[type]"),i.isFunction(o.content))e["@fn"].call(this,n,a);else for(var l in e)if(o.content.type==l){e[l].call(this,n,a);break}return a.unbind("focus.ax5picker").unbind("click.ax5picker").bind("focus.ax5picker",t.focus.bind(this,n)).bind("click.ax5picker",t.click.bind(this,n)),o.$target.find(".input-group-addon").unbind("click.ax5picker").bind("click.ax5picker",t.click.bind(this,n)),o.content.formatter&&ax5.ui.formatter&&a.ax5formatter(o.content.formatter),a=null,o=null,n=null,this}}(),l=function(t){if(!this.activePicker)return this;var e=function(e){var i,n=jQuery(window),a=jQuery(document.body),o={},l=12,s={},r={};o=e.$target.offset(),s={width:e.$target.outerWidth(),height:e.$target.outerHeight()},r={winWidth:Math.max(n.width(),a.width()),winHeight:Math.max(n.height(),a.height()),width:this.activePicker.outerWidth(),height:this.activePicker.outerHeight()},e.direction&&""!==e.direction&&"auto"!==e.direction?i=e.direction:(i="top",o.top-r.height-l<0?i="top":o.top+s.height+r.height+l>r.winHeight&&(i="bottom")),t&&this.activePicker.addClass("direction-"+i);var d=function(){var t={left:0,top:0};switch(i){case"top":t.left=o.left+s.width/2-r.width/2,t.top=o.top+s.height+l;break;case"bottom":t.left=o.left+s.width/2-r.width/2,t.top=o.top-r.height-l;break;case"left":t.left=o.left+s.width+l,t.top=o.top-r.height/2+s.height/2;break;case"right":t.left=o.left-r.width-l,t.top=o.top-r.height/2+s.height/2}return t}();(function(){"top"!=i&&"bottom"!=i||(d.left<0?(d.left=l,this.activePickerArrow.css({left:o.left+s.width/2-d.left})):d.left+r.width>r.winWidth&&(d.left=r.winWidth-r.width-l,this.activePickerArrow.css({left:o.left+s.width/2-d.left})))}).call(this),this.activePicker.css(d)},i=this.queue[this.activePickerQueueIndex];this.activePicker.css({top:-999}),t&&jQuery(document.body).append(this.activePicker),setTimeout(function(){e.call(this,i)}.bind(this))},s=function(t,e){if(!this.activePicker)return this;var n=this.queue[this.activePickerQueueIndex];return e=i.findParentNode(t.target,function(t){return!!t.getAttribute("data-picker-els")||(n.$target.get(0)==t||void 0)}),e?this:(this.close(),this)},r=function(t,e){if(t.srcElement&&(t.target=t.srcElement),e=i.findParentNode(t.target,function(t){if(t.getAttribute("data-picker-btn"))return!0})){var n=this.queue[this.activePickerQueueIndex],a=e.getAttribute("data-picker-btn");if(n.btns&&n.btns[a].onClick){var o={key:a,value:n.btns[a],self:this,item:n};n.btns[a].onClick.call(o,a)}else this.close()}},d=function(t){t.keyCode==ax5.info.eventKeys.ESC&&this.close()},c=function(t){return i.isString(t)||(t=jQuery(t).data("data-axpicker-id")),i.isString(t)?i.search(this.queue,function(){return this.id==t}):void console.log(ax5.info.getError("ax5picker","402","getQueIdx"))};this.init=function(){this.onStateChanged=n.onStateChanged},this.bind=function(t){var e={},a=void 0;return t=jQuery.extend(!0,e,n,t),t.target?(t.$target=jQuery(t.target),t.$target.get(0)?(t.id||(t.id=t.$target.data("data-axpicker-id")),t.id||(t.id="ax5-picker-"+ax5.getGuid(),t.$target.data("data-axpicker-id",t.id)),a=i.search(this.queue,function(){return this.id==t.id}),a===-1?(this.queue.push(t),o.call(this,this.queue.length-1)):(this.queue[a]=jQuery.extend(!0,{},this.queue[a],t),o.call(this,a)),e=null,a=null,this):(console.log(ax5.info.getError("ax5picker","401","bind")),this)):(console.log(ax5.info.getError("ax5picker","401","bind")),this)},this.setContentValue=function(){var t={date:function(t,e,i){var n,a,o,l=[];return"INPUT"!==t.$target.get(0).tagName.toUpperCase()&&t.$target.find("input[type]").each(function(){l.push(this.value)}),0==e?(l.length>1&&""!==l[1]?(n=ax5.util.dday(l[1],{today:l[0]}),n<0&&(o=i)):o=i,o&&(t.pickerCalendar[1].ax5uiInstance.setSelection([o],!1).changeMode("d",o),this.setContentValue(t.id,1,o)),i):1==e?(l.length>1&&(n=ax5.util.dday(l[1],{today:l[0]}),n<0&&(a=l[1])),a&&(t.pickerCalendar[0].ax5uiInstance.setSelection([a],!1).changeMode("d",a),this.setContentValue(t.id,0,a)),i):void 0}};return function(n,o,l){var s,r=i.isNumber(n)?n:c.call(this,n),d=this.queue[r];if(d){s="INPUT"==d.$target.get(0).tagName.toUpperCase()?d.$target:jQuery(d.$target.find("input[type]").get(o)),s.val(l),d.disableChangeTrigger||s.trigger("change"),d.inputLength>1&&t[d.content.type]&&(l=t[d.content.type].call(this,d,o,l));var u={self:e,state:"changeValue",item:d,inputIndex:o,value:l,values:[l]};"INPUT"!==d.$target.get(0).tagName.toUpperCase()&&(u.values=[],d.$target.find("input[type]").each(function(){u.values.push(this.value)})),a.call(this,d,u),1==d.inputLength&&this.close()}return d=null,n=null,o=null,l=null,this}}(),this.open=function(){var o={"@fn":function(t,e){var i=this.queue[t];return i.content.call(i,function(t){e(t)}),!0},date:function(t){for(var a=this.queue[t],o=[],l=0;l'),l');o.push('
'),a.pickerContent.html(o.join(""));var s=jQuery.extend({},n.calendar,{displayDate:new Date}),r="INPUT"==a.$target.get(0).tagName.toUpperCase()?a.$target:a.$target.find("input[type]");a.pickerCalendar=[],a.pickerContent.find("[data-calendar-target]").each(function(){var t=this.getAttribute("data-calendar-target"),i=r.get(t).value,n=ax5.util.date(i);s.displayDate=n,i&&(s.selection=[n]),s=jQuery.extend(!0,s,a.content.config||{}),s.target=this,s.onClick=function(){e.setContentValue(a.id,t,this.date)},a.pickerCalendar.push({itemId:a.id,inputIndex:t,ax5uiInstance:new ax5.ui.calendar(s)})})},"secure-num":function(t){for(var n=this.queue[t],o=[],l=0;l'),l');o.push('
'),n.pickerContent.html(o.join("")),n.pickerContent.find("[data-secure-num-target]").each(function(){var t=this.getAttribute("data-secure-num-target"),i=[],o=function(t){var e,i,n;for(n=t.length;n;n-=1)e=Math.floor(Math.random()*n),i=t[n-1],t[n-1]=t[e],t[e]=i;return t}([0,1,2,3,4,5,6,7,8,9]),l=[{label:"←",fn:"back"},{label:"C",fn:"clear"}];o.forEach(function(t){i.push('
'),i.push('"),i.push("
")}),l.forEach(function(t){i.push('
'),i.push('"),i.push("
")}),i.push('
'),$(this).html(i.join("")).on("click","[data-secure-num-value]",function(){var i=this.getAttribute("data-secure-num-value"),o="INPUT"==n.$target.get(0).tagName.toUpperCase()?n.$target:jQuery(n.$target.find("input[type]").get(t)),l=o.val();"back"==i?o.val(l.substring(0,l.length-1)):"clear"==i?o.val(""):o.val(l+i),a.call(this,n,{self:e,state:"changeValue",item:n,value:o.val()})})})},keyboard:function(t){for(var n=this.queue[t],o=[],l=0;l'),l');o.push('
'),n.pickerContent.html(o.join(""));var s=[[{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"}]],r=function(t){var e=[];return s.forEach(function(i){e.push('
'),i.forEach(function(i){var a,o,l,s,r;i.fn?(a=i.fn,o=i.label,l=n.content.config.specialBtnWrapStyle,s=n.content.config.specialBtnTheme,r=n.content.config.specialBtnStyle):(o=a=t?i.shiftValue:i.value,l=n.content.config.btnWrapStyle,s=n.content.config.btnTheme,r=n.content.config.btnStyle),e.push('
'),e.push('"),e.push("
")}),e.push("
")}),e.join("")};n.pickerContent.find("[data-keyboard-target]").each(function(){var t=this.getAttribute("data-keyboard-target"),i=$(this),o=!1,l=function(){o=!o,i.html(r(o))};i.html(r(o)).on("mousedown","[data-keyboard-value]",function(){var i=this.getAttribute("data-keyboard-value"),o="INPUT"==n.$target.get(0).tagName.toUpperCase()?n.$target:jQuery(n.$target.find("input[type]").get(t)),s=o.val();switch(i){case"back":o.val(s.substring(0,s.length-1));break;case"clear":o.val("");break;case"shift":return l(),!1;case"close":return e.close(),!1;default:o.val(s+i)}a.call(this,n,{self:e,state:"changeValue",item:n,value:o.val()})})})},numpad:function(t){for(var n=this.queue[t],o=[],l=0;l'),l');o.push('
'),n.pickerContent.html(o.join("")),n.pickerContent.find("[data-numpad-target]").each(function(){var t=this.getAttribute("data-numpad-target"),i=[],o=n.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"}];o.forEach(function(t){var e,a,o,l,s;t.fn?(e=t.fn,a=t.label,l=n.content.config.specialBtnTheme,o=n.content.config.specialBtnWrapStyle,s=n.content.config.specialBtnStyle):(a=e=t.value,l=e?n.content.config.btnTheme:"",o=n.content.config.btnWrapStyle,s=n.content.config.btnStyle),i.push('
'),i.push('"),i.push("
")}),i.push('
'),$(this).html(i.join("")).on("mousedown","[data-numpad-value]",function(){var i=this.getAttribute("data-numpad-value"),o="INPUT"==n.$target.get(0).tagName.toUpperCase()?n.$target:jQuery(n.$target.find("input[type]").get(t)),l=o.val(),s="";switch(i){case"back":s="changeValue",o.val(l.substring(0,l.length-1));break;case"clear":s="changeValue",o.val("");break;case"enter":return e.close(n,"enter"),!1;case"close":return e.close(),!1;default:s="changeValue",o.val(l+i)}a.call(this,n,{self:e,state:s,item:n,value:o.val()})})})}};return function(e,u){var h=i.isNumber(e)?e:c.call(this,e),p=this.queue[h];return this.openTimer&&clearTimeout(this.openTimer),this.activePicker?this.activePickerQueueIndex==h?this:u>2?this:(this.close(),this.openTimer=setTimeout(function(){this.open(h,(u||0)+1)}.bind(this),n.animateTime),this):(this.activePicker=jQuery(t.tmpl.get.call(this,"pickerTmpl",p)),this.activePickerArrow=this.activePicker.find(".ax-picker-arrow"),this.activePickerQueueIndex=h,p.pickerContent=this.activePicker.find('[data-picker-els="content"]'),i.isFunction(p.content)?(p.pickerContent.html("Loading.."),o["@fn"].call(this,h,function(t){p.pickerContent.html(t)})):p.content.type in o&&o[p.content.type].call(this,h),this.activePicker.find("[data-picker-btn]").on(n.clickEventName,function(t){r.call(this,t||window.event,h)}.bind(this)),l.call(this,"append"),jQuery(window).bind("resize.ax5picker",function(){l.call(this)}.bind(this)),jQuery(window).bind("keyup.ax5picker",function(t){t=t||window.event,d.call(this,t),i.stopEvent(t)}.bind(this)),jQuery(window).bind("click.ax5picker",function(t){t=t||window.event,s.call(this,t),i.stopEvent(t)}.bind(this)),a.call(this,p,{self:this,state:"open",item:p}),this)}}(),this.close=function(t,e){return this.closeTimer&&clearTimeout(this.closeTimer),this.activePicker?(t=this.queue[this.activePickerQueueIndex],this.activePicker.addClass("destroy"),jQuery(window).unbind("resize.ax5picker"),jQuery(window).unbind("click.ax5picker"),jQuery(window).unbind("keyup.ax5picker"),this.closeTimer=setTimeout(function(){this.activePicker&&this.activePicker.remove(),this.activePicker=null,this.activePickerQueueIndex=-1,a.call(this,t,{self:this,state:e||"close"})}.bind(this),n.animateTime),this):this},this.main=function(){arguments&&i.isObject(arguments[0])&&this.setConfig(arguments[0])}.apply(this,arguments)};return e}()),t=ax5.ui.picker}(),ax5.ui.picker_instance=new ax5.ui.picker,jQuery.fn.ax5picker=function(){return function(t){if(ax5.util.isString(arguments[0])){var e=arguments[0];switch(e){case"open":return ax5.ui.picker_instance.open(this);case"close":return ax5.ui.picker_instance.close(this);case"setValue":return ax5.ui.picker_instance.setContentValue(this,arguments[1],arguments[2]);default:return this}}else"undefined"==typeof t&&(t={}),jQuery.each(this,function(){var e={target:this};t=jQuery.extend(!0,t,e),ax5.ui.picker_instance.bind(t)});return this}}(),function(){var t=ax5.ui.picker,e=(ax5.util,function(){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'});t.tmpl={pickerTmpl:e,get:function(e,i,n){return ax5.mustache.render(t.tmpl[e].call(this,n),i)}}}(),function(){var t,e=ax5.ui,i=ax5.util;e.addClass({className:"formatter",version:"1.3.66"},function(){var e=(new Date,function(t,e){if("undefined"==typeof e&&(e=t.value.length),t.setSelectionRange)t.focus(),t.setSelectionRange(e,e);else if(t.createTextRange){var i=t.createTextRange();i.collapse(!0),i.moveEnd("character",e),i.moveStart("character",e),i.select()}else t.selectionStart&&(t.focus(),t.selectionStart=e,t.selectionEnd=e)}),n=function(){var n,a=this;this.instanceId=ax5.getGuid(),this.config={animateTime:250},this.queue=[],this.openTimer=null,this.closeTimer=null,n=this.config;var o={focus:function(t,e,i){t.$input.data("__originValue__")||t.$input.data("__originValue__",t.$input.val())},keydown:function(t,e,i){var n=!1;t.enterableKeyCodes&&(i.which&&t.enterableKeyCodes[i.which]||i.metaKey||i.ctrlKey||i.shiftKey||(n=!0)),n&&ax5.util.stopEvent(i)},keyup:function(i,n,a){var o,l,s,r,d,c=i.$input.get(0);"selectionStart"in c?o=c.selectionStart:document.selection&&(r=document.selection.createRange(),d=document.selection.createRange().text.length,r.moveStart("character",-c.value.length),o=r.text.length-d),l=c.value,s=i.pattern in t.formatter?t.formatter[i.pattern].getPatternValue.call(this,i,n,a,c.value):l,s!=l&&(i.$input.val(s).trigger("change"),e(c,o+s.length-l.length))},blur:function(e,i,n,a){var o,l,s=e.$input.get(0);e.$input.removeData("__originValue__"),o=s.value,l=e.pattern in t.formatter?t.formatter[e.pattern].getPatternValue.call(this,e,i,n,s.value,"blur"):o,a?e.$input.val(l):l!=o&&e.$input.val(l).trigger("change")}},l=function(e,i){if(!e.pattern&&("INPUT"==e.$target.get(0).tagName?e.pattern=e.$target.attr("data-ax5formatter"):e.pattern=e.$target.find('input[type="text"]').attr("data-ax5formatter"),!e.pattern))return console.log(ax5.info.getError("ax5formatter","501","bind")),console.log(e.target),this;var n=/[^\(^\))]+/gi,a=e.pattern.match(n);return e.pattern=a[0], +e.patternArgument=a[1]||"",e.pattern in t.formatter&&(e.enterableKeyCodes=t.formatter[e.pattern].getEnterableKeyCodes.call(this,e,i)),e.$input.unbind("focus.ax5formatter").bind("focus.ax5formatter",o.focus.bind(this,this.queue[i],i)),e.$input.unbind("keydown.ax5formatter").bind("keydown.ax5formatter",o.keydown.bind(this,this.queue[i],i)),e.$input.unbind("keyup.ax5formatter").bind("keyup.ax5formatter",o.keyup.bind(this,this.queue[i],i)),e.$input.unbind("blur.ax5formatter").bind("blur.ax5formatter",o.blur.bind(this,this.queue[i],i)),o.blur.call(this,this.queue[i],i),this},s=function(t){return i.isString(t)||(t=jQuery(t).data("data-formatter")),i.search(this.queue,function(){return this.id==t})};this.init=function(){},this.bind=function(t){var e,o={};if(jQuery.extend(!0,o,n),t&&jQuery.extend(!0,o,t),t=o,!t.target)return console.log(ax5.info.getError("ax5formatter","401","bind")),this;if(t.$target=jQuery(t.target),"INPUT"==t.$target.get(0).tagName)t.$input=t.$target;else if(t.$input=t.$target.find('input[type="text"]'),t.$input.length>1)return t.$input.each(function(){t.target=this,a.bind(t)}),this;return t.$input="INPUT"==t.$target.get(0).tagName?t.$target:t.$target.find('input[type="text"]'),t.id||(t.id=t.$input.data("ax5-formatter")),t.id||(t.id="ax5-formatter-"+ax5.getGuid(),t.$input.data("ax5-formatter",t.id)),e=i.search(this.queue,function(){return this.id==t.id}),e===-1?(this.queue.push(t),l.call(this,this.queue[this.queue.length-1],this.queue.length-1)):(this.queue[e]=t,l.call(this,this.queue[e],e)),this},this.formatting=function(t){var e=i.isNumber(t)?t:s.call(this,t);if(e===-1)for(var n=this.queue.length;n--;)o.blur.call(this,this.queue[n],n,null,!0);else o.blur.call(this,this.queue[e],e,null,!0);return this},this.unbind=function(){},this.main=function(){arguments&&i.isObject(arguments[0])&&this.setConfig(arguments[0])}.apply(this,arguments)};return n}()),t=ax5.ui.formatter}(),ax5.ui.formatter_instance=new ax5.ui.formatter,jQuery.fn.ax5formatter=function(){return function(t){if(ax5.util.isString(arguments[0])){var e=arguments[0];switch(e){case"formatting":return ax5.ui.formatter_instance.formatting(this);case"unbind":return ax5.ui.formatter_instance.unbind(this);default:return this}}else"undefined"==typeof t&&(t={}),jQuery.each(this,function(){var e={target:this};t=jQuery.extend({},t,e),ax5.ui.formatter_instance.bind(t)});return this}}(),function(){var t=ax5.ui.formatter,e=ax5.util,i={18:"KEY_ALT",8:"KEY_BACKSPACE",17:"KEY_CONTROL",46:"KEY_DELETE",40:"KEY_DOWN",35:"KEY_END",187:"KEY_EQUAL",27:"KEY_ESC",36:"KEY_HOME",45:"KEY_INSERT",37:"KEY_LEFT",189:"KEY_MINUS",34:"KEY_PAGEDOWN",33:"KEY_PAGEUP",13:"KEY_RETURN",39:"KEY_RIGHT",16:"KEY_SHIFT",9:"KEY_TAB",38:"KEY_UP",91:"KEY_WINDOW"},n={48:1,49:1,50:1,51:1,52:1,53:1,54:1,55:1,56:1,57:1,96:1,97:1,98:1,99:1,100:1,101:1,102:1,103:1,104:1,105:1},a={getEnterableKeyCodes:function(e){var i={188:","};return"int"==e.patternArgument||(i[190]="."),jQuery.extend(i,t.formatter.ctrlKeys,t.formatter.numKeys)},getPatternValue:function(t,i,n,a,o){a=a.replace(/[^0-9^\.^\-]/g,"");var l,s=new RegExp("([0-9])([0-9][0-9][0-9][,.])"),r=a.split(".");r[0]+=".";do r[0]=r[0].replace(s,"$1,$2");while(s.test(r[0]));return l=r.length>1?e.isNumber(t.maxRound)?r[0]+e.left(r[1],t.maxRound):r.join(""):r[0].split(".")[0]}},o={getEnterableKeyCodes:function(e){var i={190:"."};return jQuery.extend(i,t.formatter.ctrlKeys,t.formatter.numKeys)},getPatternValue:function(t,i,n,a,o){a=a.replace(/[^0-9^\.^\-]/g,"");var l,s=a.split(".");return l=s.length>1?e.isNumber(t.maxRound)?s[0]+e.left(s[1],t.maxRound):s.join(""):s[0].split(".")[0]}},l={getEnterableKeyCodes:function(e){var i={189:"-",191:"/"};return jQuery.extend(i,t.formatter.ctrlKeys,t.formatter.numKeys)},getPatternValue:function(t,i,n,a,o){if(a=a.replace(/\D/g,""),""==a)return a;var l=/^([0-9]{4})\-?([0-9]{1,2})?\-?([0-9]{1,2})?.*$/;"time"==t.patternArgument&&(l=/^([0-9]{4})\-?([0-9]{1,2})?\-?([0-9]{1,2})? ?([0-9]{1,2})?:?([0-9]{1,2})?:?([0-9]{1,2})?.*$/);var s=a.match(l),r="",d=function(t,i,n,a){var o={Y:function(t){return"undefined"==typeof t&&(t=TODAY.getFullYear()),""!=t&&"0000"!=t||(t=TODAY.getFullYear()),t.length<4?e.setDigit(t,4):t},M:function(t){return"undefined"==typeof t&&(t=TODAY.getMonth()+1),t>12?12:0==t?"01":e.setDigit(t,2)},D:function(t){"undefined"==typeof t&&(t=TODAY.getDate()+1);var i=e.daysOfMonth(a[1],a[2]-1);return t>i?i:0==t?"01":e.setDigit(t,2)},h:function(t){return t||(t=0),t>23?23:e.setDigit(t,2)},m:function(t){return t||(t=0),t>59?59:e.setDigit(t,2)},s:function(t){return t||(t=0),t>59?59:e.setDigit(t,2)}};return n?o[i](t):t};return r=a.replace(l,function(e,i){var n=[d(arguments[1],"Y",o)];return(arguments[2]||o)&&n.push("-"+d(arguments[2],"M",o)),(arguments[3]||o)&&n.push("-"+d(arguments[3],"D",o,arguments)),"time"==t.patternArgument&&((arguments[4]||o)&&n.push(" "+d(arguments[4],"h",o)),(arguments[5]||o)&&n.push(":"+d(arguments[5],"m",o)),(arguments[6]||o)&&n.push(":"+d(arguments[6],"s",o))),n.join("")}),"blur"!=o||s?s||(r=r.length>4?e.left(r,4):r):r=function(){var e=[d(r,"Y",o)];return e.push("-"+d(0,"M",o)),e.push("-"+d(0,"D",o,arguments)),"time"==t.patternArgument&&(e.push(" "+d(0,"h",o)),e.push(":"+d(0,"m",o)),e.push(":"+d(0,"s",o))),e.join("")}(),r}},s={getEnterableKeyCodes:function(e){var i={186:":"};return jQuery.extend(i,t.formatter.ctrlKeys,t.formatter.numKeys)},getPatternValue:function(t,i,n,a,o){a=a.replace(/\D/g,"");var l=/^([0-9]{1,2})?:?([0-9]{1,2})?:?([0-9]{1,2})?.*$/,s=a.match(l),r=a.replace(l,function(t,e){var i=[arguments[1]];return arguments[2]&&i.push(":"+arguments[2]),arguments[3]&&i.push(":"+arguments[3]),i.join("")});return s||(r=r.length>2?e.left(r,2):r),r}},r={getEnterableKeyCodes:function(e){var i={189:"-"};return jQuery.extend(i,t.formatter.ctrlKeys,t.formatter.numKeys)},getPatternValue:function(t,e,i,n,a){n=n.replace(/\D/g,"");var o=/^([0-9]{3})\-?([0-9]{1,2})?\-?([0-9]{1,5})?.*$/,l=n.replace(o,function(t,e){var i=[arguments[1]];return arguments[2]&&i.push(arguments[2]),arguments[3]&&i.push(arguments[3]),i.join("-")});return l}},d={getEnterableKeyCodes:function(e){var i={189:"-",188:","};return jQuery.extend(i,t.formatter.ctrlKeys,t.formatter.numKeys)},getPatternValue:function(t,e,i,n,a){n=n.replace(/\D/g,"");var o=/^([0-9]{3})\-?([0-9]{1,4})?\-?([0-9]{1,4})?\-?([0-9]{1,4})?\-?([0-9]{1,4})?/;"02"==n.substr(0,2)&&(o=/^([0-9]{2})\-?([0-9]{1,4})?\-?([0-9]{1,4})?\-?([0-9]{1,4})?\-?([0-9]{1,4})?/);var l=n.replace(o,function(t,e){var i=[arguments[1]];return arguments[2]&&i.push(arguments[2]),arguments[3]&&i.push(arguments[3]),arguments[4]&&i.push(arguments[4]),arguments[5]&&i.push(arguments[5]),i.join("-")});return l}},c={getEnterableKeyCodes:function(e){var i={189:"-"};return jQuery.extend(i,t.formatter.ctrlKeys,t.formatter.numKeys)},getPatternValue:function(t,e,i,n,a){n=n.replace(/\D/g,"").substring(0,16);var o=/^([0-9]{4})\-?([0-9]{4})?\-?([0-9]{4})?\-?([0-9]{4})?/,l=n.replace(o,function(t,e){var i=[arguments[1]];return arguments[2]&&i.push(arguments[2]),arguments[3]&&i.push(arguments[3]),arguments[4]&&i.push(arguments[4]),i.join("-")});return l}},u={getEnterableKeyCodes:function(t){return t.getEnterableKeyCodes?t.getEnterableKeyCodes.call(t,{$input:t.$input}):null},getPatternValue:function(t,e,i,n,a){if(t.getPatternValue)return t.getPatternValue.call(t,{event:i,$input:t.$input,value:n})}};t.formatter={ctrlKeys:i,numKeys:n,money:a,number:o,date:l,time:s,bizno:r,phone:d,credit:c,custom:u}}(),function(){var t,e=ax5.ui,i=ax5.util;e.addClass({className:"menu",version:"1.3.66"},function(){var n=function(){var n,a=this;this.instanceId=ax5.getGuid(),this.config={theme:"default",iconWidth:22,acceleratorWidth:100,menuBodyPadding:5,offset:{left:0,top:0},position:"fixed",animateTime:250,items:[],itemClickAndClose:!0,columnKeys:{label:"label",items:"items"}},this.openTimer=null,this.closeTimer=null,this.queue=[],this.menuBar={},this.state=void 0,n=this.config;var o=function(t){t?(jQuery(document).unbind("click.ax5menu-"+this.menuId).bind("click.ax5menu-"+this.menuId,d.bind(this)),jQuery(window).unbind("keydown.ax5menu-"+this.menuId).bind("keydown.ax5menu-"+this.menuId,function(t){t.which==ax5.info.eventKeys.ESC&&a.close()}),jQuery(window).unbind("resize.ax5menu-"+this.menuId).bind("resize.ax5menu-"+this.menuId,function(t){a.close()})):(jQuery(document).unbind("click.ax5menu-"+this.menuId),jQuery(window).unbind("keydown.ax5menu-"+this.menuId),jQuery(window).unbind("resize.ax5menu-"+this.menuId))},l=function(t,e){return t&&t.onStateChanged?t.onStateChanged.call(e,e):this.onStateChanged&&this.onStateChanged.call(e,e),a.state=e.state,t=null,e=null,!0},s=function(t){return this.onLoad&&this.onLoad.call(t,t),t=null,!0},r=function u(e,i,o,r){var d,h,p=e;return p.theme=e.theme||n.theme,p.cfg={icons:jQuery.extend({},n.icons),iconWidth:e.iconWidth||n.iconWidth,acceleratorWidth:e.acceleratorWidth||n.acceleratorWidth},i.forEach(function(t){t.html||t.divide?(t["@isMenu"]=!1,t.html&&(t["@html"]=t.html.call({item:t,config:n,opt:e}))):t["@isMenu"]=!0}),p[n.columnKeys.items]=i,p["@depth"]=o,p["@path"]=r||"root",p["@hasChild"]=function(){return this[n.columnKeys.items]&&this[n.columnKeys.items].length>0},d=jQuery(t.tmpl.get.call(this,"tmpl",p,n.columnKeys)),jQuery(document.body).append(d),h=this.queue.splice(o),h.forEach(function(t){t.$target.remove()}),this.queue.push({$target:d,data:jQuery.extend({},p)}),d.find("[data-menu-item-index]").bind("mouseover",function(){var t,i,o,l,s,r,d=this.getAttribute("data-menu-item-depth"),c=this.getAttribute("data-menu-item-index"),h=this.getAttribute("data-menu-item-path");null!=d&&"undefined"!=typeof d&&(s=a.queue[d].data[n.columnKeys.items][c][n.columnKeys.items],r=a.queue[d].$target,r.find("[data-menu-item-index]").removeClass("hover"),jQuery(this).addClass("hover"),r.attr("data-selected-menu-item-index")!=c&&(r.attr("data-selected-menu-item-index",c),s&&s.length>0?(t=jQuery(this),i=t.offset(),o="fixed"==n.position?jQuery(document).scrollTop():0,l={"@parent":{left:i.left,top:i.top,width:t.outerWidth(),height:t.outerHeight()},left:i.left+t.outerWidth()-n.menuBodyPadding,top:i.top-n.menuBodyPadding-1-o},l=jQuery.extend(!0,e,l),u.call(a,l,s,Number(d)+1,h)):a.queue.splice(Number(d)+1).forEach(function(t){t.$target.remove()}))),d=null,c=null,h=null,t=null,i=null,o=null,l=null,s=null,r=null}),d.find("[data-menu-item-index]").bind("mouseout",function(){var t,e=this.getAttribute("data-menu-item-depth"),i=this.getAttribute("data-menu-item-index");this.getAttribute("data-menu-item-path");t=a.queue[e].data[n.columnKeys.items][i][n.columnKeys.items],t&&t.length>0||jQuery(this).removeClass("hover")}),0==o&&(p.direction&&d.addClass("direction-"+p.direction),l.call(this,null,{self:this,items:i,parent:function(t){if(!t)return!1;var e=null;try{e=Function("","return this.config.items["+t.substring(5).replace(/\./g,"].items[")+"];").call(a)}catch(i){}return e}(p["@path"]),state:"popup"})),c.call(this,d,p),s.call(this,{self:this,items:i,element:d.get(0)}),p=null,d=null,h=null,e=null,i=null,o=null,r=null,this},d=function(t,e,o){if(e=i.findParentNode(t.target,function(t){if(t.getAttribute("data-menu-item-index"))return!0})){if(o=function(t){if(!t)return!1;var e;try{e=Function("","return this.config.items["+t.substring(5).replace(/\./g,"]."+n.columnKeys.items+"[")+"];").call(a)}catch(i){console.log(ax5.info.getError("ax5menu","501","menuItemClick"))}try{return e}finally{e=null}}(e.getAttribute("data-menu-item-path")),!o)return this;o.check&&(function(t){var e={checkbox:function(t){this.checked=!t},radio:function(e){var i=this.name;t.forEach(function(t){t.check&&"radio"===t.check.type&&t.check.name==i&&(t.check.checked=!1)}),this.checked=!e}};e[this.type]&&e[this.type].call(this,this.checked),e=null}.call(o.check,n.items),n.itemClickAndClose||a.queue.forEach(function(t){t.$target.find("[data-menu-item-index]").each(function(){var e=t.data[n.columnKeys.items][this.getAttribute("data-menu-item-index")];e.check&&jQuery(this).find(".item-checkbox-wrap").attr("data-item-checked",e.check.checked)})})),a.onClick&&a.onClick.call(o,o),o[n.columnKeys.items]&&0!=o[n.columnKeys.items].length||!n.itemClickAndClose||a.close()}else a.close();return e=null,o=null,this},c=function(t,e){var i=jQuery(window),a=jQuery(document),o="fixed"==n.position?i.height():a.height(),l=i.width(),s=t.outerHeight(),r=t.outerWidth(),d=e.left,c=e.top,u=n.position||"fixed";return d+r>l&&(d=e["@parent"]?e["@parent"].left-r+n.menuBodyPadding:l-r),c+s>o&&(c=o-s),t.css({left:d,top:c,position:u}),t=null,e=null,i=null,a=null,o=null,l=null,s=null,r=null,d=null,c=null,u=null,this};this.init=function(){a.menuId=ax5.getGuid(),this.onStateChanged=n.onStateChanged,this.onClick=n.onClick,this.onLoad=n.onLoad,l.call(this,null,{self:this,state:"init"})},this.popup=function(){var t={event:function(t,e){t={left:t.clientX,top:"fixed"==n.position?t.clientY:t.pageY,width:n.width,theme:n.theme},n.offset&&(n.offset.left&&(t.left+=n.offset.left),n.offset.top&&(t.top+=n.offset.top)),e=jQuery.extend(!0,t,e);try{return e}finally{t=null}},object:function(t,e){t={left:t.left,top:t.top,width:t.width||n.width,theme:t.theme||n.theme},n.offset&&(n.offset.left&&(t.left+=n.offset.left),n.offset.top&&(t.top+=n.offset.top)),e=jQuery.extend(!0,t,e);try{return e}finally{t=null}}},e=function(t){t&&(n.theme=t)};return function(i,a){if(!i)return this;a=t["undefined"==typeof i.clientX?"object":"event"].call(this,i,a),e(a.theme);var l=[].concat(n.items);if(a.filter){var s=function d(t){var e=[];return t.forEach(function(t){t.items&&t.items.length>0&&(t.items=d(t.items)),a.filter.call(t)&&e.push(t)}),e};l=s(l)}return l.length&&(r.call(this,a,l,0),o.call(this,!0)),i=null,this}}(),this.attach=function(){var e={object:function(t,e){t={left:t.left,top:t.top,width:t.width||n.width,theme:t.theme||n.theme,direction:t.direction||n.direction},e=jQuery.extend(!0,e,t);try{return e}finally{t=null,e=null}}},l=function(t,i,l){var s=jQuery(t),d=s.offset(),c=s.outerHeight(),u=Number(t.getAttribute("data-menu-item-index")),h="fixed"==n.position?jQuery(document).scrollTop():0;if(n.items&&n.items[u][n.columnKeys.items]&&n.items[u][n.columnKeys.items].length){if(a.menuBar.openedIndex==u)return"click"==l&&a.close(),!1;a.menuBar.target.find("[data-menu-item-index]").removeClass("hover"),a.menuBar.opened=!0,a.menuBar.openedIndex=u,s.attr("data-menu-item-opened","true"),s.addClass("hover"),n.offset&&(n.offset.left&&(d.left+=n.offset.left),n.offset.top&&(d.top+=n.offset.top)),i=e.object.call(this,{left:d.left,top:d.top+c-h},i),r.call(a,i,n.items[u][n.columnKeys.items],0,"root."+t.getAttribute("data-menu-item-index")),o.call(a,!0)}t=null,i=null,s=null,d=null,c=null,u=null,h=null},s=function(t,e,i){var o=jQuery(t),l=(o.offset(),o.outerHeight(),Number(t.getAttribute("data-menu-item-index")));"fixed"==n.position?jQuery(document).scrollTop():0;!n.items||n.items[l][n.columnKeys.items]&&0!=n.items[l][n.columnKeys.items].length||a.onClick&&a.onClick.call(n.items[l],n.items[l])};return function(e,o){var r,d={},c=n.items;return"undefined"==typeof o&&(o={}),d.theme=o.theme||n.theme,d.cfg={icons:jQuery.extend({},n.icons),iconWidth:o.iconWidth||n.iconWidth,acceleratorWidth:o.acceleratorWidth||n.acceleratorWidth},c.forEach(function(t){t.html||t.divide?(t["@isMenu"]=!1,t.html&&(t["@html"]=t.html.call({item:t,config:n,opt:o}))):t["@isMenu"]=!0}),d[n.columnKeys.items]=c,r=jQuery(t.tmpl.get.call(this,"tmplMenubar",d,n.columnKeys)),a.menuBar={target:jQuery(e),opened:!1},a.menuBar.target.html(r),a.menuBar.target.bind("click",function(t){if(!t)return this;var e=i.findParentNode(t.target,function(t){if(t.getAttribute("data-menu-item-index"))return!0});e&&(s(e,o,"click"),l(e,o,"click")),e=null}),a.menuBar.target.bind("mouseover",function(t){if(!a.menuBar.opened)return!1;var e=i.findParentNode(t.target,function(t){if(t.getAttribute("data-menu-item-index"))return!0});e&&l(e,o,"mouseover"),e=null}),e=null,o=null,d=null,c=null,r=null,this}}(),this.close=function(){return a.menuBar&&a.menuBar.target&&(a.menuBar.target.find("[data-menu-item-index]").removeClass("hover"),a.menuBar.opened=!1,a.menuBar.openedIndex=null),o.call(this,!1),this.queue.forEach(function(t){t.$target.remove()}),this.queue=[],l.call(this,null,{self:this,state:"close"}),this},this.getCheckValue=function(){var t={},e=function(n){for(var a=n.length;a--;)n[a].check&&n[a].check.checked&&(t[n[a].check.name]?(i.isString(t[n[a].check.name])&&(t[n[a].check.name]=[t[n[a].check.name]]),t[n[a].check.name].push(n[a].check.value)):t[n[a].check.name]=n[a].check.value),n[a].items&&n[a].items.length>0&&e(n[a].items)};e(n.items);try{return t}finally{t=null,e=null}},this.main=function(){e.menu_instance=e.menu_instance||[],e.menu_instance.push(this),arguments&&i.isObject(arguments[0])&&this.setConfig(arguments[0])}.apply(this,arguments)};return n}()),t=ax5.ui.menu}(),function(){var t=ax5.ui.menu,e=function(t){return'\n
\n
\n {{#'+t.items+'}}\n {{^@isMenu}}\n {{#divide}}\n
\n {{/divide}}\n {{#html}}\n
{{{@html}}}
\n {{/html}}\n {{/@isMenu}}\n {{#@isMenu}}\n
\n \n {{#check}}\n \n {{/check}}\n {{^check}}\n \n {{/check}}\n \n {{#icon}}\n {{{.}}}\n {{/icon}}\n {{{'+t.label+'}}}\n {{#accelerator}}\n {{.}}\n {{/accelerator}}\n {{#@hasChild}}\n {{{cfg.icons.arrow}}}\n {{/@hasChild}}\n
\n {{/@isMenu}}\n\n {{/'+t.items+'}}\n
\n
\n
\n '},i=function(t){return'\n
\n
\n {{#'+t.items+'}}\n {{^@isMenu}}\n {{#divide}}\n
\n {{/divide}}\n {{#html}}\n
{{{@html}}}
\n {{/html}}\n {{/@isMenu}}\n {{#@isMenu}}\n
\n {{#icon}}\n {{{.}}}\n {{/icon}}\n {{{'+t.label+"}}}\n
\n {{/@isMenu}}\n {{/"+t.items+"}}\n
\n
\n "};t.tmpl={tmpl:e,tmplMenubar:i,get:function(e,i,n){return ax5.mustache.render(t.tmpl[e].call(this,n),i)}}}(),function(){var t,e=ax5.ui,i=ax5.util;e.addClass({className:"select",version:"1.3.66"},function(){var e=function(){var e,n=this;this.instanceId=ax5.getGuid(),this.config={theme:"default",animateTime:100,lang:{noSelected:"",noOptions:"no options",loading:"now loading..",multipleLabel:'"{{label}}"외 {{length}}건'},columnKeys:{optionValue:"value",optionText:"text",optionSelected:"selected"}},this.queue=[],this.activeSelectOptionGroup=null,this.activeSelectQueueIndex=-1,this.openTimer=null,this.closeTimer=null,this.waitOptionsCallback=null,this.keyUpTimer=null,this.xvar={},e=this.config;var a=jQuery(window),o={18:"KEY_ALT",8:"KEY_BACKSPACE",17:"KEY_CONTROL",46:"KEY_DELETE",40:"KEY_DOWN",35:"KEY_END",187:"KEY_EQUAL",27:"KEY_ESC",36:"KEY_HOME",45:"KEY_INSERT",37:"KEY_LEFT",189:"KEY_MINUS",34:"KEY_PAGEDOWN",33:"KEY_PAGEUP",13:"KEY_RETURN",39:"KEY_RIGHT",16:"KEY_SHIFT",9:"KEY_TAB",38:"KEY_UP",91:"KEY_WINDOW"},l=function(t,e){return t&&t.onStateChanged?t.onStateChanged.call(e,e):this.onStateChanged&&this.onStateChanged.call(e,e),"changeValue"==e.state&&(t&&t.onChange?t.onChange.call(e,e):this.onChange&&this.onChange.call(e,e)),t=null,e=null,!0},s=function(){for(var t,e=this.queue.length;e--;)this.queue[e].$display&&(t=Math.max(this.queue[e].$select.outerWidth(),i.number(this.queue[e].minWidth)),this.queue[e].$display.css({"min-width":t}),this.queue[e].reset&&this.queue[e].$display.find(".addon-icon-reset").css({"line-height":this.queue[e].$display.height()+"px"}));return e=null,t=null,this},r=function(t){if(!this.activeSelectOptionGroup)return this;var e,i=this.queue[this.activeSelectQueueIndex],n={},o=0,l={},s={};t&&jQuery(document.body).append(this.activeSelectOptionGroup),n=i.$target.offset(),l={width:i.$target.outerWidth(),height:i.$target.outerHeight()},s={winWidth:Math.max(a.width(),jQuery(document.body).width()),winHeight:Math.max(a.height(),jQuery(document.body).height()),width:this.activeSelectOptionGroup.outerWidth(),height:this.activeSelectOptionGroup.outerHeight()},i.direction&&""!==i.direction&&"auto"!==i.direction?e=i.direction:(e="top",n.top-s.height-o<0?e="top":n.top+l.height+s.height+o>s.winHeight&&(e="bottom")),t&&this.activeSelectOptionGroup.addClass("direction-"+e),this.activeSelectOptionGroup.css(function(){if("top"==e){if(n.top+l.height+s.height+o>s.winHeight){var t=n.top+l.height/2-s.height/2;return t+s.height+o>s.winHeight&&(t=0),t<0&&(t=0),{left:n.left,top:t,width:l.width}}return{left:n.left,top:n.top+l.height+1,width:l.width}}if("bottom"==e)return{left:n.left,top:n.top-s.height-1,width:l.width}}.call(this))},d=function(t,e){if(!this.activeSelectOptionGroup)return this;var n=this.queue[this.activeSelectQueueIndex],a="display";return(e=i.findParentNode(t.target,function(t){return t.getAttribute("data-option-value")?(a="optionItem",!0):n.$target.get(0)==t?(a="display",!0):void 0}))?("optionItem"===a&&(this.val(n.id,{index:{gindex:e.getAttribute("data-option-group-index"),index:e.getAttribute("data-option-index")}},void 0,"internal"),n.$select.trigger("change"),n.$display.focus(),n.multiple||this.close()),this):(this.close(),this)},c=function(t){if(t.keyCode==ax5.info.eventKeys.ESC)this.close();else if(t.which==ax5.info.eventKeys.RETURN)if(this.queue[this.activeSelectQueueIndex].optionFocusIndex>-1){var e=this.activeSelectOptionGroup.find('[data-option-focus-index="'+this.queue[this.activeSelectQueueIndex].optionFocusIndex+'"]');this.val(this.queue[this.activeSelectQueueIndex].id,{index:{gindex:e.attr("data-option-group-index"),index:e.attr("data-option-index")}},void 0,"internal"),this.queue[this.activeSelectQueueIndex].$select.trigger("change"),this.queue[this.activeSelectQueueIndex].multiple||this.close()}else this.close()},u=function(t){var e=this.queue[t],n=[];return i.isArray(e.selected)&&e.selected.length>0?e.selected.forEach(function(t){t.selected&&n.push(t[e.columnKeys.optionText])}):!e.multiple&&e.options&&e.options[0]?e.options[0].optgroup?n[0]=e.options[0].options[0][e.columnKeys.optionText]:n[0]=e.options[0][e.columnKeys.optionText]:n[0]=e.lang.noSelected,function(){if(e.multiple&&n.length>1){var t={label:n[0],length:n.length-1};return ax5.mustache.render(e.lang.multipleLabel,t)}return n[0]}()},h=function(t){this.queue[t].$displayLabel.html(u.call(this,t))},p=function(t,e){var i,n=[],a=-1,o=this.queue[t].indexedOptions.length-1;if(e){for(;o-a++;){if(i=this.queue[t].indexedOptions[a],(""+i.value).toLowerCase()==e.toLowerCase()){n=[{"@findex":i["@findex"],optionsSort:0}];break}var l=(""+i.value).toLowerCase().search(e.toLowerCase());if(l>-1&&(n.push({"@findex":i["@findex"],optionsSort:l}),n.length>2))break;l=null}n.sort(function(t,e){return t.optionsSort-e.optionsSort})}n&&n.length>0&&f.call(this,t,void 0,n[0]["@findex"]);try{return n}finally{n=null,a=null,o=null,i=null}},f=function(t,e,i){var n,a,o,l;if(this.activeSelectOptionGroup&&this.queue[t].options&&this.queue[t].options.length>0){"undefined"!=typeof i?n=i:(a=this.queue[t].optionFocusIndex==-1?this.queue[t].optionSelectedIndex||-1:this.queue[t].optionFocusIndex,a==-1?n=e>0?0:this.queue[t].optionItemLength-1:(n=a+e,n<0?n=0:n>this.queue[t].optionItemLength-1&&(n=this.queue[t].optionItemLength-1))),this.queue[t].optionFocusIndex=n,this.activeSelectOptionGroup.find("[data-option-focus-index]").removeClass("hover"),o=this.activeSelectOptionGroup.find('[data-option-focus-index="'+n+'"]').addClass("hover"),l=this.activeSelectOptionGroup.find('[data-els="content"]');var s=o.outerHeight(),r=l.innerHeight(),d=l.scrollTop(),c=o.position().top+l.scrollTop();r+dc&&l.scrollTop(c)}},m=function(){var e=i.debounce(function(t,e){p.call(n,e,t),n.queue[e].$displayInput.val("")},300),a={click:function(t,e){var a=i.findParentNode(e.target,function(t){if(t.getAttribute("data-selected-clear"))return!0});a?this.val(t,{clear:!0}):n.activeSelectQueueIndex==t?this.queue[t].optionFocusIndex==-1&&n.close():(n.open(t),i.stopEvent(e))},keyUp:function(t,i){i.which==ax5.info.eventKeys.SPACE?a.click.call(this,t,i):o[i.which]||e(this.queue[t].$displayInput.val(),t)},keyDown:function(t,e){e.which==ax5.info.eventKeys.DOWN?(f.call(this,t,1),i.stopEvent(e)):e.which==ax5.info.eventKeys.UP&&(f.call(this,t,-1),i.stopEvent(e))},blur:function(t,e){},selectChange:function(t,e){this.val(t,this.queue[t].$select.val(),!0)}};return function(e){var i=this.queue[e],n={};return i.selected=[],i.$display?(i.$displayLabel.html(u.call(this,e)),i.options=g.call(this,e,i.options),s.call(this)):(n.instanceId=this.instanceId,n.id=i.id,n.name=i.name,n.theme=i.theme,n.tabIndex=i.tabIndex,n.multiple=i.multiple,n.reset=i.reset,n.label=u.call(this,e),n.formSize=function(){return i.size?"input-"+i.size:""}(),i.$display=t.tmpl.get.call(this,"tmpl",n),i.$displayLabel=i.$display.find('[data-ax5select-display="label"]'),i.$target.find("select").get(0)?(i.$select=i.$target.find("select"),i.$select.attr("tabindex","-1").attr("class","form-control "+n.formSize),n.name&&i.$select.attr("name","name"),n.multiple&&i.$select.attr("multiple","multiple")):(i.$select=t.tmpl.get.call(this,"selectTmpl",n),i.$target.append(i.$select)),i.$target.append(i.$display),i.$displayInput=i.$display.find('[data-ax5select-display="input"]'),i.options=g.call(this,e,i.options),s.call(this),i.$displayInput.unbind("blur.ax5select").bind("blur.ax5select",a.blur.bind(this,e)).unbind("keyup.ax5select").bind("keyup.ax5select",a.keyUp.bind(this,e)).unbind("keydown.ax5select").bind("keydown.ax5select",a.keyDown.bind(this,e))),i.$display.unbind("click.ax5select").bind("click.ax5select",a.click.bind(this,e)).unbind("keyup.ax5select").bind("keyup.ax5select",a.keyUp.bind(this,e)),i.$select.unbind("change.ax5select").bind("change.ax5select",a.selectChange.bind(this,e)),n=null,i=null,e=null,this}}(),g=function(){var t=function(t,e){e?this.queue[t].multiple?this.queue[t].selected.push(jQuery.extend({},e)):this.queue[t].selected[0]=jQuery.extend({},e):this.queue[t].selected=[]};return function(e,a){var o,l,s,r=this.queue[e],d=0;return t.call(this,e,!1),a?(r.options=a,r.indexedOptions=[],o=[],r.options.forEach(function(i,a){i.optgroup?(i["@gindex"]=a,i.options.forEach(function(i,a){i["@index"]=a,i["@findex"]=d,o.push('"),i[r.columnKeys.optionSelected]&&t.call(n,e,i),r.indexedOptions.push({"@findex":d,value:i[r.columnKeys.optionValue],text:i[r.columnKeys.optionText]}),d++})):(i["@index"]=a,i["@findex"]=d,o.push('"),i[r.columnKeys.optionSelected]&&t.call(n,e,i),r.indexedOptions.push({"@findex":d,value:i[r.columnKeys.optionValue],text:i[r.columnKeys.optionText]}),d++)}),r.optionItemLength=d,r.$select.html(o.join(""))):(l=i.toArray(r.$select.get(0).options),s=[],l.forEach(function(i,a){var o={};o[r.columnKeys.optionValue]=i.value,o[r.columnKeys.optionText]=i.text,o[r.columnKeys.optionSelected]=i.selected,o["@index"]=a,o["@findex"]=a,i.selected&&t.call(n,e,o),s.push(o),o=null}),r.options=s,r.indexedOptions=s),!r.multiple&&0==r.selected.length&&r.options&&r.options[0]&&(r.options[0].optgroup?(r.options[0].options[0][r.columnKeys.optionSelected]=!0,r.selected.push(jQuery.extend({},r.options[0].options[0]))):(r.options[0][r.columnKeys.optionSelected]=!0,r.selected.push(jQuery.extend({},r.options[0])))),o=null,l=null,s=null,r.options}}(),x=function(t){return i.isString(t)||(t=jQuery(t).data("data-ax5select-id")),i.isString(t)?i.search(this.queue,function(){return this.id==t}):void console.log(ax5.info.getError("ax5select","402","getQueIdx"))};this.init=function(){this.onStateChanged=e.onStateChanged,this.onChange=e.onChange,jQuery(window).bind("resize.ax5select-display-"+this.instanceId,function(){s.call(this)}.bind(this))},this.bind=function(t){var n,a={};return t=jQuery.extend(!0,a,e,t),t.target?(t.$target=jQuery(t.target),t.id||(t.id=t.$target.data("data-ax5select-id")),t.id||(t.id="ax5select-"+ax5.getGuid(),t.$target.data("data-ax5select-id",t.id)),t.name=t.$target.attr("data-ax5select"),t.options&&(t.options=JSON.parse(JSON.stringify(t.options))),function(e){i.isObject(e)&&!e.error&&(t=jQuery.extend(!0,t,e))}(i.parseJson(t.$target.attr("data-ax5select-config"),!0)),n=i.search(this.queue,function(){return this.id==t.id}),n===-1?(this.queue.push(t),m.call(this,this.queue.length-1)):(this.queue[n].selected=[],this.queue[n].options=t.options,this.queue[n]=jQuery.extend(!0,{},this.queue[n],t),m.call(this,n)),a=null,n=null,this):(console.log(ax5.info.getError("ax5select","401","bind")),this)},this.open=function(){var n=function(e){e.onExpand.call({self:this,item:e},function(e){if(this.waitOptionsCallback){var n={},a=this.queue[this.activeSelectQueueIndex];!function(t,e){var n={};e.options.forEach(function(e,i){e["@index"]=i,n[e[t.columnKeys.optionValue]]=e}),i.isArray(t.selected)&&t.selected.forEach(function(i){n[i[t.columnKeys.optionValue]]&&(e.options[n[i[t.columnKeys.optionValue]]["@index"]][t.columnKeys.optionSelected]=!0)})}(a,e),a.$displayLabel.html(u.call(this,this.activeSelectQueueIndex)),a.options=g.call(this,this.activeSelectQueueIndex,e.options),s.call(this),n.id=a.id,n.theme=a.theme,n.size="ax5select-option-group-"+a.size,n.multiple=a.multiple,n.lang=a.lang,n.options=a.options,this.activeSelectOptionGroup.find('[data-els="content"]').html(t.tmpl.get.call(this,"optionsTmpl",n,a.columnKeys))}}.bind(this))};return function(a,o){this.waitOptionsCallback=null;var s,u,h=i.isNumber(a)?a:x.call(this,a),p=this.queue[h],f={};return p.$display.attr("disabled")?this:(this.openTimer&&clearTimeout(this.openTimer),this.activeSelectOptionGroup?this.activeSelectQueueIndex==h?this:o>2?this:(this.close(), +this.openTimer=setTimeout(function(){this.open(h,(o||0)+1)}.bind(this),e.animateTime),this):(p.optionFocusIndex=-1,p.selected&&p.selected.length>0&&(p.optionSelectedIndex=p.selected[0]["@findex"]),f.id=p.id,f.theme=p.theme,f.size="ax5select-option-group-"+p.size,f.multiple=p.multiple,f.lang=p.lang,p.$display.attr("data-select-option-group-opened","true"),p.onExpand&&(f.waitOptions=!0),f.options=p.options,this.activeSelectOptionGroup=t.tmpl.get.call(this,"optionGroupTmpl",f),this.activeSelectOptionGroup.find('[data-els="content"]').html(t.tmpl.get.call(this,"optionsTmpl",f,p.columnKeys)),this.activeSelectQueueIndex=h,r.call(this,"append"),jQuery(window).bind("resize.ax5select-"+this.instanceId,function(){r.call(this)}.bind(this)),p.selected&&p.selected.length>0&&(u=this.activeSelectOptionGroup.find('[data-option-index="'+p.selected[0]["@index"]+'"]'),u.get(0)&&(s=u.position().top-this.activeSelectOptionGroup.height()/3,this.activeSelectOptionGroup.find('[data-els="content"]').stop().animate({scrollTop:s},p.animateTime,"swing",function(){}))),p.$displayInput.val(""),setTimeout(function(){p.$displayInput.trigger("focus"),jQuery(window).bind("keyup.ax5select-"+this.instanceId,function(t){t=t||window.event,c.call(this,t),i.stopEvent(t)}.bind(this)),jQuery(window).bind("click.ax5select-"+this.instanceId,function(t){t=t||window.event,d.call(this,t),i.stopEvent(t)}.bind(this))}.bind(this),300),l.call(this,p,{self:this,state:"open",item:p}),p.onExpand&&(this.waitOptionsCallback=!0,n.call(this,p)),f=null,s=null,u=null,this))}}(),this.update=function(t){return this.bind(t),this},this.val=function(){var t=function(t,e,i){return"undefined"==typeof i?!t.multiple||!e:i},e=function(t){this.queue[t].options.forEach(function(t){t.optgroup?t.options.forEach(function(t){t.selected=!1}):t.selected=!1})},a={index:function(e,a,o){var l=this.queue[e];i.isString(a.index.gindex)?(l.options[a.index.gindex].options[a.index.index][l.columnKeys.optionSelected]=t(l,l.options[a.index.gindex].options[a.index.index][l.columnKeys.optionSelected],o),n.activeSelectOptionGroup.find('[data-option-group-index="'+a.index.gindex+'"][data-option-index="'+a.index.index+'"]').attr("data-option-selected",l.options[a.index.gindex].options[a.index.index][l.columnKeys.optionSelected].toString())):(l.options[a.index.index][l.columnKeys.optionSelected]=t(l,l.options[a.index.index][l.columnKeys.optionSelected],o),n.activeSelectOptionGroup.find('[data-option-index="'+a.index.index+'"]').attr("data-option-selected",l.options[a.index.index][l.columnKeys.optionSelected].toString())),g.call(this,e,l.options),h.call(this,e),r.call(this)},arr:function(t,e,o){e.forEach(function(e){if(i.isString(e)||i.isNumber(e))a.value.call(n,t,e,o);else for(var l in a)if(e[l]){a[l].call(n,t,e,o);break}})},value:function(e,n,a){var o=this.queue[e],l=i.search(o.options,function(){return this[o.columnKeys.optionValue]==n});return l>-1?(o.options[l][o.columnKeys.optionSelected]=t(o,o.options[l][o.columnKeys.optionSelected],a),g.call(this,e,o.options),void h.call(this,e)):void console.log(ax5.info.getError("ax5select","501","val"))},text:function(e,n,a){var o=this.queue[e],l=i.search(o.options,function(){return this[o.columnKeys.optionText]==n});return l>-1?(o.options[l][o.columnKeys.optionSelected]=t(o,o.options[l][o.columnKeys.optionSelected],a),g.call(this,e,o.options),void h.call(this,e)):void console.log(ax5.info.getError("ax5select","501","val"))},clear:function(t){e.call(this,t),g.call(this,t,this.queue[t].options),h.call(this,t),this.activeSelectOptionGroup&&this.activeSelectOptionGroup.find("[data-option-index]").attr("data-option-selected","false")}};return function(t,n,o,s){var r=i.isNumber(t)?t:x.call(this,t);if(r===-1)return void console.log(ax5.info.getError("ax5select","402","val"));if("undefined"==typeof n||this.queue[r].multiple||e.call(this,r),"undefined"==typeof n)return this.queue[r].selected;if(i.isArray(n))a.arr.call(this,r,n,o);else if(i.isString(n)||i.isNumber(n))a.value.call(this,r,n,o);else if(null===n)a.clear.call(this,r);else for(var d in a)if(n[d]){a[d].call(this,r,n,o);break}return"undefined"!=typeof n&&l.call(this,this.queue[r],{self:this,item:this.queue[r],state:s?"changeValue":"setValue",value:this.queue[r].selected,internal:s}),t=null,this}}(),this.close=function(t){return this.closeTimer&&clearTimeout(this.closeTimer),this.activeSelectOptionGroup?(t=this.queue[this.activeSelectQueueIndex],t.optionFocusIndex=-1,t.$displayInput.val("").trigger("blur"),t.$display.removeAttr("data-select-option-group-opened").trigger("focus"),this.activeSelectOptionGroup.addClass("destroy"),jQuery(window).unbind("resize.ax5select-"+this.instanceId).unbind("click.ax5select-"+this.instanceId).unbind("keyup.ax5select-"+this.instanceId),this.closeTimer=setTimeout(function(){this.activeSelectOptionGroup&&this.activeSelectOptionGroup.remove(),this.activeSelectOptionGroup=null,this.activeSelectQueueIndex=-1;var e={self:this,item:t,value:t.selected,state:"close"};l.call(this,t,e),t.onClose&&t.onClose.call(e)}.bind(this),e.animateTime),this.waitOptionsCallback=null,this):this},this.enable=function(t){var e=x.call(this,t);return this.queue[e].$display.removeAttr("disabled"),this.queue[e].$select.removeAttr("disabled"),l.call(this,this.queue[e],{self:this,state:"enable"}),this},this.disable=function(t){var e=x.call(this,t);return this.queue[e].$display.attr("disabled","disabled"),this.queue[e].$select.attr("disabled","disabled"),l.call(this,this.queue[e],{self:this,state:"disable"}),this},this.main=function(){arguments&&i.isObject(arguments[0])?this.setConfig(arguments[0]):this.init()}.apply(this,arguments)};return e}()),t=ax5.ui.select}(),ax5.ui.select_instance=new ax5.ui.select,jQuery.fn.ax5select=function(){return function(t){if(ax5.util.isString(arguments[0])){var e=arguments[0];switch(e){case"open":return ax5.ui.select_instance.open(this);case"close":return ax5.ui.select_instance.close(this);case"setValue":return ax5.ui.select_instance.val(this,arguments[1],arguments[2]);case"getValue":return ax5.ui.select_instance.val(this);case"enable":return ax5.ui.select_instance.enable(this);case"disable":return ax5.ui.select_instance.disable(this);default:return this}}else"undefined"==typeof t&&(t={}),jQuery.each(this,function(){var e={target:this};t=jQuery.extend({},t,e),ax5.ui.select_instance.bind(t)});return this}}(),function(){var t=ax5.ui.select,e=function(t){return'\n
\n
\n
\n
\n
\n
\n'},i=function(t){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=function(t){return'\n\n'},a=function(t){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 {{'+t.optionText+'}}\n
\n
\n {{/options}}\n
\n {{/optgroup}}\n {{^optgroup}}\n
\n
\n {{#multiple}}\n \n \n \n {{/multiple}}\n {{'+t.optionText+'}}\n
\n
\n {{/optgroup}}\n {{/options}}\n {{^options}}\n
\n
\n \n {{{lang.noOptions}}}\n \n
\n
\n {{/options}}\n{{/waitOptions}}\n'};t.tmpl={optionGroupTmpl:e,tmpl:i,selectTmpl:n,optionsTmpl:a,get:function(e,i,n){return jQuery(ax5.mustache.render(t.tmpl[e].call(this,n),i))}}}(),function(){var t,e=ax5.ui,i=ax5.util;e.addClass({className:"grid",version:"1.3.66"},function(){var n=function(){var n,a=this;this.instanceId=ax5.getGuid(),this.config={theme:"default",animateTime:250,frozenColumnIndex:0,frozenRowIndex:0,showLineNumber:!1,showRowSelector:!1,multipleSelect:!0,height:0,columnMinWidth:100,lineNumberColumnWidth:30,rowSelectorColumnWidth:26,sortable:void 0,remoteSort:!1,header:{align:!1,columnHeight:26,columnPadding:3,columnBorderWidth:1},body:{align:!1,columnHeight:26,columnPadding:3,columnBorderWidth:1,grouping:!1},rightSum:!1,footSum:!1,page:{height:25,display:!0,navigationItemCount:5},scroller:{size:15,barMinSize:15,trackPadding:4},columnKeys:{selected:"__selected__",modified:"__modified__",deleted:"__deleted__",disableSelection:"__disable_selection__"}},this.xvar={bodyTrHeight:0,scrollContentWidth:0,scrollContentHeight:0},this.columns=[],this.colGroup=[],this.footSumColumns=[],this.bodyGrouping={},this.list=[],this.page={},this.selectedDataIndexs=[],this.deletedList=[],this.sortInfo={},this.focusedColumn={},this.selectedColumn={},this.isInlineEditing=!1,this.inlineEditing={},this.headerTable={},this.leftHeaderData={},this.headerData={},this.rightHeaderData={},this.bodyRowTable={},this.leftBodyRowData={},this.bodyRowData={},this.rightBodyRowData={},this.bodyRowMap={},this.bodyGroupingTable={},this.leftBodyGroupingData={},this.bodyGroupingData={},this.rightBodyGroupingData={},this.footSumTable={},this.leftFootSumData={},this.footSumData={},this.needToPaintSum=!0,n=this.config;var o=function(){var e={instanceId:this.id};return this.$target.html(t.tmpl.get("main",e)),this.$={container:{hidden:this.$target.find('[data-ax5grid-container="hidden"]'),root:this.$target.find('[data-ax5grid-container="root"]'),header:this.$target.find('[data-ax5grid-container="header"]'),body:this.$target.find('[data-ax5grid-container="body"]'),page:this.$target.find('[data-ax5grid-container="page"]'),scroller:this.$target.find('[data-ax5grid-container="scroller"]')},panel:{"aside-header":this.$target.find('[data-ax5grid-panel="aside-header"]'),"left-header":this.$target.find('[data-ax5grid-panel="left-header"]'),header:this.$target.find('[data-ax5grid-panel="header"]'),"header-scroll":this.$target.find('[data-ax5grid-panel-scroll="header"]'),"right-header":this.$target.find('[data-ax5grid-panel="right-header"]'),"top-aside-body":this.$target.find('[data-ax5grid-panel="top-aside-body"]'),"top-left-body":this.$target.find('[data-ax5grid-panel="top-left-body"]'),"top-body":this.$target.find('[data-ax5grid-panel="top-body"]'),"top-body-scroll":this.$target.find('[data-ax5grid-panel-scroll="top-body"]'),"top-right-body":this.$target.find('[data-ax5grid-panel="top-right-body"]'),"aside-body":this.$target.find('[data-ax5grid-panel="aside-body"]'),"aside-body-scroll":this.$target.find('[data-ax5grid-panel-scroll="aside-body"]'),"left-body":this.$target.find('[data-ax5grid-panel="left-body"]'),"left-body-scroll":this.$target.find('[data-ax5grid-panel-scroll="left-body"]'),body:this.$target.find('[data-ax5grid-panel="body"]'),"body-scroll":this.$target.find('[data-ax5grid-panel-scroll="body"]'),"right-body":this.$target.find('[data-ax5grid-panel="right-body"]'),"right-body-scroll":this.$target.find('[data-ax5grid-panel-scroll="right-body"]'),"bottom-aside-body":this.$target.find('[data-ax5grid-panel="bottom-aside-body"]'),"bottom-left-body":this.$target.find('[data-ax5grid-panel="bottom-left-body"]'),"bottom-body":this.$target.find('[data-ax5grid-panel="bottom-body"]'),"bottom-body-scroll":this.$target.find('[data-ax5grid-panel-scroll="bottom-body"]'),"bottom-right-body":this.$target.find('[data-ax5grid-panel="bottom-right-body"]')},livePanelKeys:[],scroller:{vertical:this.$target.find('[data-ax5grid-scroller="vertical"]'),"vertical-bar":this.$target.find('[data-ax5grid-scroller="vertical-bar"]'),horizontal:this.$target.find('[data-ax5grid-scroller="horizontal"]'),"horizontal-bar":this.$target.find('[data-ax5grid-scroller="horizontal-bar"]'),corner:this.$target.find('[data-ax5grid-scroller="corner"]')},page:{navigation:this.$target.find('[data-ax5grid-page="navigation"]'),status:this.$target.find('[data-ax5grid-page="status"]')},form:{clipboard:this.$target.find('[data-ax5grid-form="clipboard"]')},resizer:{vertical:this.$target.find('[data-ax5grid-resizer="vertical"]'),horizontal:this.$target.find('[data-ax5grid-resizer="horizontal"]')}},this.$.container.root.css({height:this.config.height}),this},l=function(e){this.columns=i.deepCopy(e),this.headerTable=t.util.makeHeaderTable.call(this,this.columns),this.xvar.frozenColumnIndex=n.frozenColumnIndex>this.columns.length?this.columns.length:n.frozenColumnIndex,this.bodyRowTable=t.util.makeBodyRowTable.call(this,this.columns),this.bodyRowMap=t.util.makeBodyRowMap.call(this,this.bodyRowTable),this.xvar.bodyTrHeight=this.bodyRowTable.rows.length*this.config.body.columnHeight;for(var a={},o=0,l=this.headerTable.rows.length;o0)for(t=(o-l)/s.length,e=0,a=s.length;ei?this.config.scroller.size:0}.call(this),i>0&&(e=o-p-f-h-i0?(a.width=e,a.height=s,a.bottom=i+f):o=!0;break;case"horizontal":i>0?(a.width=l,a.height=i,a.right=e,a.bottom=f):o=!0;break;case"corner":e>0&&i>0?(a.width=e,a.height=i,a.bottom=f):o=!0}return o?(t.hide(),this):void t.show().css(a)};this.$.container.header.css({height:p}),this.$.container.body.css({height:m}),g.call(this,this.$.panel["aside-header"],"","aside","header"),g.call(this,this.$.panel["left-header"],"","left","header"),g.call(this,this.$.panel.header,"","","header"),g.call(this,this.$.panel["right-header"],"","right","header"),g.call(this,this.$.panel["top-aside-body"],"top","aside","body"),g.call(this,this.$.panel["top-left-body"],"top","left","body"),g.call(this,this.$.panel["top-body"],"top","","body"),g.call(this,this.$.panel["top-right-body"],"top","right","body"),g.call(this,this.$.panel["aside-body"],"","aside","body"),g.call(this,this.$.panel["left-body"],"","left","body"),g.call(this,this.$.panel.body,"","","body"),g.call(this,this.$.panel["right-body"],"","right","body"),g.call(this,this.$.panel["bottom-aside-body"],"bottom","aside","body"),g.call(this,this.$.panel["bottom-left-body"],"bottom","left","body"),g.call(this,this.$.panel["bottom-body"],"bottom","","body"),g.call(this,this.$.panel["bottom-right-body"],"bottom","right","body"),x.call(this,this.$.scroller.vertical,e,i,"vertical"),x.call(this,this.$.scroller.horizontal,e,i,"horizontal"),x.call(this,this.$.scroller.corner,e,i,"corner"),g.call(this,this.$.container.page,"","","page")},h=function(e){if(t.header.repaint.call(this),i.isFunction(this.config.remoteSort)){var n={sortInfo:[]};for(var a in e)n.sortInfo.push({key:a,orderBy:e[a].orderBy,seq:e[a].seq});n.sortInfo.sort(function(t,e){return t.seq>e.seq}),this.config.remoteSort.call(n,n)}else this.config.body.grouping?this.list=t.data.initData.call(this,t.data.sort.call(this,e,t.data.clearGroupingData.call(this,this.list))):this.list=t.data.sort.call(this,e,t.data.clearGroupingData.call(this,this.list)),t.body.repaint.call(this,!0),t.scroller.resize.call(this)};this.init=function(e){if(n=jQuery.extend(!0,{},n,e),!n.target)return console.log(ax5.info.getError("ax5grid","401","init")),this;this.onStateChanged=n.onStateChanged,this.onClick=n.onClick,this.onLoad=n.onLoad,this.onDataChanged=n.body.onDataChanged,this.$target=jQuery(n.target),function(t){i.isObject(t)&&!t.error&&(n=jQuery.extend(!0,n,t))}.call(this,i.parseJson(this.$target.attr("data-ax5grid-config"),!0));var s=this.config=n;this.config.height||(this.config.height=this.$target.height()),this.id||(this.id=this.$target.data("data-ax5grid-id")),this.id||(this.id="ax5grid-"+this.instanceId,this.$target.data("data-ax5grid-id",s.id)),o.call(this),l.call(this,s.columns),r.call(this),s.footSum&&d.call(this,s.footSum),s.body.grouping&&c.call(this,s.body.grouping),u.call(this,!0),t.header.init.call(this),t.header.repaint.call(this),t.body.init.call(this),t.body.repaint.call(this),t.scroller.init.call(this),t.scroller.resize.call(this),jQuery(window).bind("resize.ax5grid-"+this.id,function(){u.call(this),t.scroller.resize.call(this)}.bind(this)),jQuery(document.body).on("click.ax5grid-"+this.id,function(e){var n=!1,o=i.findParentNode(e.target,function(t){return!!(n=t.getAttribute("data-ax5grid-inline-edit-picker"))||"root"===t.getAttribute("data-ax5grid-container")});o&&o.getAttribute("data-ax5grid-instance")===this.id?a.focused=!0:(a.focused=!1,t.body.blur.call(this))}.bind(this));var h={33:"KEY_PAGEUP",34:"KEY_PAGEDOWN",35:"KEY_END",36:"KEY_HOME",37:"KEY_LEFT",38:"KEY_UP",39:"KEY_RIGHT",40:"KEY_DOWN"};return jQuery(window).on("keydown.ax5grid-"+this.instanceId,function(e){a.focused&&(a.isInlineEditing?e.which==ax5.info.eventKeys.ESC?a.keyDown("ESC",e.originalEvent):e.which==ax5.info.eventKeys.RETURN?a.keyDown("RETURN",e.originalEvent):e.which==ax5.info.eventKeys.TAB?(a.keyDown("TAB",e.originalEvent),i.stopEvent(e)):e.which==ax5.info.eventKeys.UP?a.keyDown("RETURN",{shiftKey:!0}):e.which==ax5.info.eventKeys.DOWN&&a.keyDown("RETURN",{}):e.metaKey||e.ctrlKey?67==e.which&&a.copySelect():h[e.which]?(a.keyDown(h[e.which],e.originalEvent),i.stopEvent(e)):e.which==ax5.info.eventKeys.ESC?a.focused&&t.body.blur.call(a):e.which==ax5.info.eventKeys.RETURN?a.keyDown("RETURN",e.originalEvent):e.which==ax5.info.eventKeys.TAB?i.stopEvent(e):e.which!=ax5.info.eventKeys.SPACE&&Object.keys(a.focusedColumn).length&&a.keyDown("INLINE_EDIT",e.originalEvent))}),setTimeout(function(){this.onLoad&&this.onLoad.call({self:this})}.bind(this)),this},this.align=function(){return u.call(this),t.scroller.resize.call(this),this},this.keyDown=function(){var e={KEY_UP:function(){t.body.moveFocus.call(this,"UP")},KEY_DOWN:function(){t.body.moveFocus.call(this,"DOWN")},KEY_LEFT:function(){t.body.moveFocus.call(this,"LEFT")},KEY_RIGHT:function(){t.body.moveFocus.call(this,"RIGHT")},KEY_HOME:function(){t.body.moveFocus.call(this,"HOME")},KEY_END:function(){t.body.moveFocus.call(this,"END")},INLINE_EDIT:function(e){t.body.inlineEdit.active.call(this,this.focusedColumn,e),/[0-9a-zA-Z]/.test(e.key)||i.stopEvent(e)},ESC:function(e){t.body.inlineEdit.keydown.call(this,"ESC")},RETURN:function(e){var i=0;for(var n in this.inlineEditing)i++,t.body.inlineEdit.keydown.call(this,"RETURN",n),1==i&&t.body.moveFocus.call(this,e.shiftKey?"UP":"DOWN")&&t.body.inlineEdit.keydown.call(this,"RETURN");0==i&&t.body.inlineEdit.keydown.call(this,"RETURN")},TAB:function(e){var i=0;for(var n in this.inlineEditing)i++,t.body.inlineEdit.keydown.call(this,"RETURN",n,{moveFocus:!0}),1==i&&t.body.moveFocus.call(this,e.shiftKey?"LEFT":"RIGHT")&&t.body.inlineEdit.keydown.call(this,"RETURN",void 0,{moveFocus:!0})}};return function(t,i){return t in e&&e[t].call(this,i),this}}(),this.copySelect=function(){var t,e,i,n,a=this.$.form.clipboard,o=[],l="",s=0;for(var r in this.selectedColumn){var d=this.selectedColumn[r];if(d){"undefined"==typeof n&&(n=d.dindex,e=d.rowIndex,i=d.rowIndex),n==d.dindex&&e==d.rowIndex||s++,o[s]||(o[s]=[]);var c=this.bodyRowMap[d.rowIndex+"_"+d.colIndex];c?this.list[d.dindex].__isGrouping?o[s].push(this.list[d.dindex][d.colIndex]):o[s].push(this.list[d.dindex][c.key]):o[s].push(""),n=d.dindex,e=d.rowIndex}}o.forEach(function(t){l+=t.join("\t")+"\n"}),a.get(0).innerText=l,a.select();try{t=document.execCommand("copy")}catch(u){t=!1}return t},this.setData=function(e){return t.data.set.call(this,e),u.call(this),t.body.repaint.call(this),t.scroller.resize.call(this),t.page.navigationUpdate.call(this),t.body.scrollTo.call(this,{top:0}),this},this.getList=function(e){return t.data.getList.call(this,e)},this.setHeight=function(e){return"100%"==e&&(e=this.$target.offsetParent().innerHeight()),this.$target.css({height:e}),this.$.container.root.css({height:e}),u.call(this),t.body.repaint.call(this,"reset"),t.scroller.resize.call(this),this},this.addRow=function(e,i,n){return t.data.add.call(this,e,i,n),u.call(this),t.body.repaint.call(this,"reset"),t.body.moveFocus.call(this,this.config.body.grouping?"START":"END"),t.scroller.resize.call(this),this},this.removeRow=function(e){return t.data.remove.call(this,e),u.call(this),t.body.repaint.call(this,"reset"),t.body.moveFocus.call(this,this.config.body.grouping?"START":"END"),t.scroller.resize.call(this),this},this.updateRow=function(e,i){return t.data.update.call(this,e,i),t.body.repaintRow.call(this,i),this},this.deleteRow=function(e){return t.data.deleteRow.call(this,e),u.call(this),t.body.repaint.call(this,"reset"),t.scroller.resize.call(this),this},this.setValue=function(e,i,n){if(t.data.setValue.call(this,e,i,n)){var a=function(e,i,n,a,o){for(var l=0,s=i.length;ln?t.body.repaintCell.call(this,"top-"+e,n,l,r,o):t.body.repaintCell.call(this,e+"-scroll",n,l,r,o))};a.call(this,"left-body",this.leftBodyRowData.rows,e,i,n),a.call(this,"body",this.bodyRowData.rows,e,i,n)}return this},this.addColumn=function(){var t={first:function(t){this.config.columns=[].concat(t).concat(this.config.columns)},last:function(t){this.config.columns=this.config.columns.concat([].concat(t))}};return function(e,n){if("undefined"==typeof e)throw"_column must not be null";if("undefined"==typeof n&&(n="last"),n in t)t[n].call(this,e);else{if(!i.isNumber(n))throw"invalid argument _cindex";this.config.columns.splice(n,[].concat(e))}return s.call(this),this}}(),this.removeColumn=function(){var t={first:function(t){this.config.columns.splice(t,1)},last:function(){this.config.columns.splice(this.config.columns.length-1,1)}};return function(e){if("undefined"==typeof e&&(e="last"),e in t)t[e].call(this,e);else{if(!i.isNumber(e))throw"invalid argument _cindex";this.config.columns.splice(e,1)}return s.call(this),this}}(),this.updateColumn=function(t,e){if(!i.isNumber(e))throw"invalid argument _cindex";return this.config.columns.splice(e,1,t),s.call(this),this},this.setColumnWidth=function(e,i){return this.colGroup[this.xvar.columnResizerIndex]._width=e,this.needToPaintSum=!0,t.header.repaint.call(this),t.body.repaint.call(this,!0),t.scroller.resize.call(this),u.call(this),this},this.getColumnSortInfo=function(){var t={sortInfo:[]};for(var e in this.sortInfo)t.sortInfo.push({key:e,orderBy:this.sortInfo[e].orderBy,seq:this.sortInfo[e].seq});return t.sortInfo.sort(function(t,e){return t.seq>e.seq}),t.sortInfo},this.setColumnSort=function(e){return"undefined"!=typeof e&&(this.sortInfo=e,t.header.applySortStatus.call(this,e)),h.call(this,e||this.sortInfo),this},this.select=function(e,n){if(i.isNumber(e)){var a=e;this.config.multipleSelect?n&&n.selectedClear&&this.clearSelect():this.clearSelect(),t.data.select.call(this,a,n&&n.selected),t.body.updateRowState.call(this,["selected"],a)}return this},this.clearSelect=function(){return t.body.updateRowState.call(this,["selectedClear"]),t.data.clearSelect.call(this),this},this.selectAll=function(e){return t.data.selectAll.call(this,e&&e.selected,e),t.body.updateRowStateAll.call(this,["selected"]),this},this.exportExcel=function(e){var i=[];return i.push(''),i.push(t.header.getExcelString.call(this)),i.push(t.body.getExcelString.call(this)),i.push("
"),"undefined"==typeof e?i.join(""):(t.excel["export"].call(this,[i.join("")],e),this)},this.focus=function(e){var i=this;if(t.body.moveFocus.call(this,e)){var n=void 0;for(var a in this.focusedColumn){n=jQuery.extend({},this.focusedColumn[a],!0);break}n&&this.select(n.dindex,{selectedClear:!0})}else"undefined"==typeof this.selectedDataIndexs[0]?this.select(0):!function(){var n=i.selectedDataIndexs[0],a={UP:function(){n>0&&(this.select(n-1,{selectedClear:!0}),t.body.moveFocus.call(this,n-1))},DOWN:function(){ne&&r.push("top"),l.xvar.frozenColumnIndex>n&&r.push("left"),r.push("body"),"top"!==r[0]&&r.push("scroll"),d=r.join("-"),l.selectedColumn[e+"_"+n+"_"+a]={panelName:d,dindex:e,rowIndex:a,colIndex:n,colspan:t.colspan},r=null,d=null}e=null,n=null,a=null;for(var c in l.selectedColumn){var u=l.selectedColumn[c];u&&l.$.panel[u.panelName].find('[data-ax5grid-tr-data-index="'+u.dindex+'"]').find('[data-ax5grid-column-rowindex="'+u.rowIndex+'"][data-ax5grid-column-colindex="'+u.colIndex+'"]').attr("data-ax5grid-column-selected","true")}}},n={on:function(t){var a=this;this.inlineEditing[t.dindex+"_"+t.colIndex+"_"+t.rowIndex]||(i.init.call(a,t),this.$.container.body.on("mousemove.ax5grid-"+this.instanceId,'[data-ax5grid-column-attr="default"]',function(t){this.getAttribute("data-ax5grid-column-rowIndex")&&(i.update.call(a,{panelName:this.getAttribute("data-ax5grid-panel-name"),dindex:Number(this.getAttribute("data-ax5grid-data-index")),rowIndex:Number(this.getAttribute("data-ax5grid-column-rowIndex")),colIndex:Number(this.getAttribute("data-ax5grid-column-colIndex")),colspan:Number(this.getAttribute("colspan"))}),e.stopEvent(t))}).on("mouseup.ax5grid-"+this.instanceId,function(){n.off.call(a)}).on("mouseleave.ax5grid-"+this.instanceId,function(){n.off.call(a)}),jQuery(document.body).attr("unselectable","on").css("user-select","none").on("selectstart",!1))},off:function(){this.$.container.body.off("mousemove.ax5grid-"+this.instanceId).off("mouseup.ax5grid-"+this.instanceId).off("mouseleave.ax5grid-"+this.instanceId),jQuery(document.body).removeAttr("unselectable").css("user-select","auto").off("selectstart")}},a=function(t,e,i){var n=this,a=this.config,o={selected:function(t){for(var e=this.$.livePanelKeys.length;e--;)this.$.panel[this.$.livePanelKeys[e]].find('[data-ax5grid-tr-data-index="'+t+'"]').attr("data-ax5grid-selected",this.list[t][a.columnKeys.selected])},selectedClear:function(){for(var t=this.selectedDataIndexs.length;t--;)for(var e=this.selectedDataIndexs[t],i=this.$.livePanelKeys.length;i--;)this.$.panel[this.$.livePanelKeys[i]].find('[data-ax5grid-tr-data-index="'+e+'"]').attr("data-ax5grid-selected",!1),this.list[e][a.columnKeys.selected]=!1},cellChecked:function(t,e){var i=(e.key,e.rowIndex),n=e.colIndex,a=function(){var e=[];return this.xvar.frozenRowIndex>t&&e.push("top"),this.xvar.frozenColumnIndex>n&&e.push("left"),e.push("body"),"top"!==e[0]&&e.push("scroll"),e.join("-")}.call(this);this.$.panel[a].find('[data-ax5grid-tr-data-index="'+t+'"]').find('[data-ax5grid-column-rowIndex="'+i+'"][data-ax5grid-column-colIndex="'+n+'"]').find('[data-ax5grid-editor="checkbox"]').attr("data-ax5grid-checked",""+e.checked)}};t.forEach(function(t){if(!o[t])throw"invaild state name";o[t].call(n,e,i)})},o=function(e,i){var n=this,a=(this.config,{selected:function(e){t.body.repaint.call(this,!0)}});e.forEach(function(t){if(!a[t])throw"invaild state name";a[t].call(n,i)})},l=function(){var i=this;this.$.container.body.on("click","[data-ax5grid-column-attr]",function(e){var n,o,l,s,r,d,c,u={"default":function(e){var n=i.bodyRowMap[e.rowIndex+"_"+e.colIndex],o={self:i,page:i.page,list:i.list,item:i.list[e.dindex],dindex:e.dindex,rowIndex:e.rowIndex,colIndex:e.colIndex,column:n,value:i.list[e.dindex][n.key]};if(n.editor&&"checkbox"==n.editor.type){var l,s,r=t.data.getValue.call(i,e.dindex,n.key);s=n.editor.config&&n.editor.config.trueValue?(l=!(r==n.editor.config.trueValue))?n.editor.config.trueValue:n.editor.config.falseValue:l=0==r||"false"==r||r<"1"?"true":"false",t.data.setValue.call(i,e.dindex,n.key,s),a.call(i,["cellChecked"],e.dindex,{key:n.key,rowIndex:e.rowIndex,colIndex:e.colIndex,editorConfig:n.editor.config,checked:l})}else i.config.body.onClick&&i.config.body.onClick.call(o)},rowSelector:function(e){return!i.list[e.dindex][i.config.columnKeys.disableSelection]&&(i.config.multipleSelect||i.selectedDataIndexs[0]===e.dindex||(t.body.updateRowState.call(i,["selectedClear"]),t.data.clearSelect.call(i)),t.data.select.call(i,e.dindex,void 0,{internalCall:!0}),void a.call(i,["selected"],e.dindex))},lineNumber:function(t){}};n=this.getAttribute("data-ax5grid-panel-name"),o=this.getAttribute("data-ax5grid-column-attr"),l=Number(this.getAttribute("data-ax5grid-column-row")),s=Number(this.getAttribute("data-ax5grid-column-col")),d=Number(this.getAttribute("data-ax5grid-column-rowIndex")),c=Number(this.getAttribute("data-ax5grid-column-colIndex")),r=Number(this.getAttribute("data-ax5grid-data-index")),o in u&&u[o]({panelName:n,attr:o,row:l,col:s,dindex:r,rowIndex:d,colIndex:c})}),this.$.container.body.on("dblclick","[data-ax5grid-column-attr]",function(e){var n,a,o,l,s,r,d,c={"default":function(n){if(this.isInlineEditing)for(var a in this.inlineEditing)if(a==n.dindex+"_"+n.colIndex+"_"+n.rowIndex)return this;var o=i.bodyRowMap[n.rowIndex+"_"+n.colIndex],l="";o&&(i.list[s].__isGrouping||(l=t.data.getValue.call(i,s,o.key))),t.body.inlineEdit.active.call(i,i.focusedColumn,e,l)},rowSelector:function(t){},lineNumber:function(t){}};n=this.getAttribute("data-ax5grid-panel-name"),a=this.getAttribute("data-ax5grid-column-attr"),o=Number(this.getAttribute("data-ax5grid-column-row")),l=Number(this.getAttribute("data-ax5grid-column-col")),r=Number(this.getAttribute("data-ax5grid-column-rowIndex")),d=Number(this.getAttribute("data-ax5grid-column-colIndex")),s=Number(this.getAttribute("data-ax5grid-data-index")),a in c&&c[a]({panelName:n,attr:a,row:o,col:l,dindex:s,rowIndex:r,colIndex:d})}),this.$.container.body.on("mouseover","tr",function(){return}),this.$.container.body.on("mousedown",'[data-ax5grid-column-attr="default"]',function(t){return!i.xvar.touchmoved&&void(this.getAttribute("data-ax5grid-column-rowIndex")&&n.on.call(i,{panelName:this.getAttribute("data-ax5grid-panel-name"),dindex:Number(this.getAttribute("data-ax5grid-data-index")),rowIndex:Number(this.getAttribute("data-ax5grid-column-rowIndex")),colIndex:Number(this.getAttribute("data-ax5grid-column-colIndex")),colspan:Number(this.getAttribute("colspan"))}))}).on("dragstart",function(t){return e.stopEvent(t),!1}),s.call(this)},s=function(){var e=this.config,i=t.util.divideTableByFrozenColumnIndex(this.bodyRowTable,this.xvar.frozenColumnIndex);if(this.asideBodyRowData=function(t){for(var i={rows:[]},n=0,a=t.rows.length;n":">"};if("__d-index__"===r)return"undefined"!=typeof n.__index?n.__index+1:"";if("__d-checkbox__"===r)return'
';if(o.editor&&function(e){return e.type in t.inlineEditor&&"inline"==t.inlineEditor[e.type].editMode}(o.editor))return l=l||t.data.getValue.call(this,a,r),e.isFunction(o.editor.disabled)&&o.editor.disabled.call({list:i,dindex:a,item:i[a],key:r,value:l})?l:s?l:t.inlineEditor[o.editor.type].getHtml(this,o.editor,l);if(o.formatter){var c={key:r,value:l||t.data.getValue.call(this,a,r),dindex:a,item:n,list:i};return e.isFunction(o.formatter)?o.formatter.call(c):t.formatter[o.formatter].call(c)}var u="";return"undefined"!=typeof l?u=l:(l=t.data.getValue.call(this,a,r),null!==l&&"undefined"!=typeof l&&(u=l)),"number"==typeof u?u:u.replace(/[<>]/g,function(t){return d[t]||t})},d=function(i,n,a){var o,l,s=a.key,r=a.label;return"undefined"==typeof s?(l={key:s,list:i.__groupingList,groupBy:i.__groupingBy},o=e.isFunction(r)?r.call(l):r,i[a.colIndex]=o,o):"__d-index__"===s?"":"__d-checkbox__"===s?"":a.collector?(l={key:s,list:i.__groupingList},o=e.isFunction(a.collector)?a.collector.call(l):t.collector[a.collector].call(l),i[a.colIndex]=o,a.formatter?(l.value=o,e.isFunction(a.formatter)?a.formatter.call(l):t.formatter[a.formatter].call(l)):o):" "},c=function(i,n){var a=n.key,o=n.label;if("undefined"==typeof a)return o;if("__d-index__"===a||"__d-checkbox__"===a)return" ";if(n.collector){var l,s={key:a,list:i};return l=e.isFunction(n.collector)?n.collector.call(s):t.collector[n.collector].call(s),n.formatter?(s.value=l,e.isFunction(n.formatter)?n.formatter.call(s):t.formatter[n.formatter].call(s)):l}return" "},u=function(i){var n=this.config,a=this.list;i&&(s.call(this),this.xvar.paintStartRowIndex=void 0);var o=Math.floor(Math.abs(this.$.panel["body-scroll"].position().top)/this.xvar.bodyTrHeight)+this.xvar.frozenRowIndex;if(this.xvar.dataRowCount===a.length&&this.xvar.paintStartRowIndex===o)return this;var l="undefined"==typeof this.xvar.paintStartRowIndex,u=this.asideBodyRowData,h=this.leftBodyRowData,p=this.bodyRowData,f=this.leftFootSumData,m=this.footSumData,g=this.asideBodyGroupingData,x=this.leftBodyGroupingData,v=this.bodyGroupingData,b=n.body.align,y=Math.ceil(this.$.panel.body.height()/this.xvar.bodyTrHeight)+1;document.addEventListener&&ax5.info.supportTouch&&(y=2*y),this.xvar.scrollContentHeight=this.xvar.bodyTrHeight*(this.list.length-this.xvar.frozenRowIndex),this.$.livePanelKeys=[];var w=function(t,i,a,o,s,c){var u=this.$.panel[t];if(!l&&!c)return this.$.livePanelKeys.push(t),!1;var h=[],p=void 0,f=void 0,m=void 0,g=void 0,x=void 0,v=void 0,y=void 0,w=void 0,_=void 0,I=void 0,k=void 0,C=function(){return"undefined"!=typeof c&&"undefined"!=typeof c.paintStartRowIndex||(c={paintStartRowIndex:0,paintRowCount:s.length},!1)}();for(C&&h.push('
'),h.push(''),h.push(""),p=0,f=i.length;p');for(h.push(""),h.push(""),m=c.paintStartRowIndex,g=function(){var t=void 0;return t=s.length,c.paintRowCount+c.paintStartRowIndex"),y=0,w=S.rows[x].cols.length;y'),h.push(function(t){var e=n.body.columnHeight-2*n.body.columnPadding-n.body.columnBorderWidth;return _.multiLine||(t=n.body.columnHeight-n.body.columnBorderWidth),''}(I),$?d.call(this,s[m],m,_):r.call(this,s,s[m],m,_),""),h.push("");h.push(""),h.push("")}}return h.push("
"),C&&s.length&&h.push('
'),u.empty().get(0).innerHTML=h.join(""),this.$.livePanelKeys.push(t),!0},_=function(t,i,a,o,s){var r=this.$.panel[t];if(!l&&!s)return this.$.livePanelKeys.push(t),!1;var d=[],u=void 0,h=void 0,p=void 0,f=void 0,m=void 0,g=void 0,x=void 0,v=void 0,y=void 0;for(d.push(''),d.push(""),u=0,h=i.length;u');for(d.push(""),d.push(""),p=0,f=a.rows.length;p'),m=0,g=a.rows[p].cols.length;m'),d.push(function(t){var e=n.body.columnHeight-2*n.body.columnPadding-n.body.columnBorderWidth;return x.multiLine||(t=n.body.columnHeight-n.body.columnBorderWidth),''}(v),c.call(this,o,x),""),d.push("");d.push(""),d.push("")}return d.push("
"),r.empty().get(0).innerHTML=d.join(""),this.$.livePanelKeys.push(t),!0},I={paintStartRowIndex:o,paintRowCount:y,bodyTrHeight:this.xvar.bodyTrHeight};n.asidePanelWidth>0&&(this.xvar.frozenRowIndex>0&&w.call(this,"top-aside-body",this.asideColGroup,u,g,a.slice(0,this.xvar.frozenRowIndex)),w.call(this,"aside-body-scroll",this.asideColGroup,u,g,a,I),n.footSum),this.xvar.frozenColumnIndex>0&&(this.xvar.frozenRowIndex>0&&w.call(this,"top-left-body",this.leftHeaderColGroup,h,x,a.slice(0,this.xvar.frozenRowIndex)),w.call(this,"left-body-scroll",this.leftHeaderColGroup,h,x,a,I),n.footSum&&this.needToPaintSum&&_.call(this,"bottom-left-body",this.leftHeaderColGroup,f,a)),this.xvar.frozenRowIndex>0&&w.call(this,"top-body-scroll",this.headerColGroup,p,v,a.slice(0,this.xvar.frozenRowIndex)),w.call(this,"body-scroll",this.headerColGroup,p,v,a,I),n.footSum&&this.needToPaintSum&&_.call(this,"bottom-body-scroll",this.headerColGroup,m,a,I),n.rightSum,this.xvar.paintStartRowIndex=o,this.xvar.paintRowCount=y,this.xvar.dataRowCount=a.length,this.needToPaintSum=!1,t.page.statusUpdate.call(this)},h=function(i,n,a,o,l){var s=this,u=this.config,h=this.list,p=this.$.panel[i].find('[data-ax5grid-tr-data-index="'+n+'"]').find('[data-ax5grid-column-rowindex="'+a+'"][data-ax5grid-column-colindex="'+o+'"]').find("[data-ax5grid-cellholder]"),f=this.colGroup,m=f[o];p.html(r.call(this,h,h[n],n,m)),m.editor&&m.editor.updateWith&&m.editor.updateWith.forEach(function(e){f.forEach(function(i){if(i.key==e){var a=i.rowIndex,o=i.colIndex,l=t.util.findPanelByColumnIndex.call(s,n,o,a).panelName,d=s.$.panel[l].find('[data-ax5grid-tr-data-index="'+n+'"]').find('[data-ax5grid-column-rowindex="'+a+'"][data-ax5grid-column-colindex="'+o+'"]').find("[data-ax5grid-cellholder]");d.html(r.call(s,h,h[n],n,i))}})});var g=Math.floor(Math.abs(this.$.panel["body-scroll"].position().top)/this.xvar.bodyTrHeight)+this.xvar.frozenRowIndex,x=this.leftFootSumData,v=this.footSumData,b=(this.asideBodyGroupingData,this.leftBodyGroupingData),y=this.bodyGroupingData,w=u.body.align,_=Math.ceil(this.$.panel.body.height()/this.xvar.bodyTrHeight)+1,I={paintStartRowIndex:g,paintRowCount:_,bodyTrHeight:this.xvar.bodyTrHeight},k=function(t,i,n,a,o){var l,s,r,d,h,p,f,m,g,x=this.$.panel[t],v=[];for(v.push(''),v.push(""),l=0,s=i.length;l');for(v.push(""),v.push(""),r=0,d=n.rows.length;r'),h=0,p=n.rows[r].cols.length;h'),v.push(function(t){var e=u.body.columnHeight-2*u.body.columnPadding-u.body.columnBorderWidth;return f.multiLine||(t=u.body.columnHeight-u.body.columnBorderWidth),''}(m),c.call(this,a,f),""),v.push("");v.push(""),v.push("")}return v.push("
"),x.empty().get(0).innerHTML=v.join(""),!0},C=function(t,i,n,a,o){var l,s,r,c,h,p,f,m,g,x=this.$.panel[t],v=[];for(l=o.paintStartRowIndex,s=function(){var t;return t=a.length,o.paintRowCount+o.paintStartRowIndex'),v.push(function(t){var e=u.body.columnHeight-2*u.body.columnPadding-u.body.columnBorderWidth;return f.multiLine||(t=u.body.columnHeight-u.body.columnBorderWidth),''}(m),d.call(this,a[l],l,f),""),v.push("");v.push("")}x.find('tr[data-ax5grid-tr-data-index="'+l+'"]').empty().get(0).innerHTML=v.join("")}};u.body.grouping&&(this.xvar.frozenColumnIndex>0&&(this.xvar.frozenRowIndex>0&&C.call(this,"top-left-body",this.leftHeaderColGroup,b,h.slice(0,this.xvar.frozenRowIndex),{paintStartRowIndex:0,paintRowCount:this.xvar.frozenRowIndex,bodyTrHeight:this.xvar.bodyTrHeight}),C.call(this,"left-body-scroll",this.leftHeaderColGroup,b,h,I)),this.xvar.frozenRowIndex>0&&C.call(this,"top-body-scroll",this.headerColGroup,y,h.slice(0,this.xvar.frozenRowIndex),{paintStartRowIndex:0,paintRowCount:this.xvar.frozenRowIndex,bodyTrHeight:this.xvar.bodyTrHeight}),C.call(this,"body-scroll",this.headerColGroup,y,h,I)),this.xvar.frozenColumnIndex>0&&u.footSum&&this.needToPaintSum&&k.call(this,"bottom-left-body",this.leftHeaderColGroup,x,h),u.footSum&&this.needToPaintSum&&k.call(this,"bottom-body-scroll",this.headerColGroup,v,h,I)},p=function(t){var i=this.config,n=this.list,a=Math.floor(Math.abs(this.$.panel["body-scroll"].position().top)/this.xvar.bodyTrHeight)+this.xvar.frozenRowIndex,o=(this.asideBodyRowData,this.leftBodyRowData),l=this.bodyRowData,s=this.leftFootSumData,u=this.footSumData,h=(this.asideBodyGroupingData,this.leftBodyGroupingData),p=this.bodyGroupingData,f=i.body.align,m=Math.ceil(this.$.panel.body.height()/this.xvar.bodyTrHeight)+1,g={paintStartRowIndex:a,paintRowCount:m,bodyTrHeight:this.xvar.bodyTrHeight},x=function(t,n,a,o){var l,s,r,d,u,h,p,m,g,x=this.$.panel[t],v=[];for(v.push(''),v.push(""),l=0,s=n.length;l');for(v.push(""),v.push(""),r=0,d=a.rows.length;r'),u=0,h=a.rows[r].cols.length;u'),v.push(function(t){var e=i.body.columnHeight-2*i.body.columnPadding-i.body.columnBorderWidth;return p.multiLine||(t=i.body.columnHeight-i.body.columnBorderWidth),''}(m),c.call(this,o,p),""),v.push("");v.push(""),v.push("")}return v.push("
"),x.empty().get(0).innerHTML=v.join(""),!0},v=function(t,n,a,o,l){var s,r,c,u,h,p,m,g,x,v=this.$.panel[t],b=[];for(s=l.paintStartRowIndex,r=function(){var t;return t=o.length,l.paintRowCount+l.paintStartRowIndex'),b.push(function(t){var e=i.body.columnHeight-2*i.body.columnPadding-i.body.columnBorderWidth;return m.multiLine||(t=i.body.columnHeight-i.body.columnBorderWidth),''}(g),d.call(this,o[s],s,m),""),b.push("");b.push("")}v.find('tr[data-ax5grid-tr-data-index="'+s+'"]').empty().get(0).innerHTML=b.join("")}},b=function(t,n,a,o,l){var l,s,d,c,u,h,p,m,g=this.$.panel[t],x=[],v=a;for(s=0,d=v.rows.length;s'),x.push(function(t){var e=i.body.columnHeight-2*i.body.columnPadding-i.body.columnBorderWidth;return h.multiLine||(t=i.body.columnHeight-i.body.columnBorderWidth),''}(p),r.call(this,o,o[l],l,h),""),x.push("");x.push("")}g.find('tr[data-ax5grid-tr-data-index="'+l+'"]').empty().get(0).innerHTML=x.join("")};this.xvar.frozenColumnIndex>0&&(this.xvar.frozenRowIndex>0&&b.call(this,"top-left-body",this.leftHeaderColGroup,o,n,t),b.call(this,"left-body-scroll",this.leftHeaderColGroup,o,n,t)),this.xvar.frozenRowIndex>0&&b.call(this,"top-body-scroll",this.headerColGroup,l,n,t),b.call(this,"body-scroll",this.headerColGroup,l,n,t),i.body.grouping&&(this.xvar.frozenColumnIndex>0&&(this.xvar.frozenRowIndex>0&&v.call(this,"top-left-body",this.leftHeaderColGroup,h,n.slice(0,this.xvar.frozenRowIndex)),v.call(this,"left-body-scroll",this.leftHeaderColGroup,h,n,g)),this.xvar.frozenRowIndex>0&&v.call(this,"top-body-scroll",this.headerColGroup,p,n.slice(0,this.xvar.frozenRowIndex)),v.call(this,"body-scroll",this.headerColGroup,p,n,g)),this.xvar.frozenColumnIndex>0&&i.footSum&&this.needToPaintSum&&x.call(this,"bottom-left-body",this.leftHeaderColGroup,s,n),i.footSum&&this.needToPaintSum&&x.call(this,"bottom-body-scroll",this.headerColGroup,u,n,g)},f=function(e,i){var n=this.config;if(this.isInlineEditing)for(var a in this.inlineEditing)t.body.inlineEdit.deActive.call(this,"ESC",a);n.asidePanelWidth>0&&"top"in e&&this.$.panel["aside-body-scroll"].css({top:e.top}),this.xvar.frozenColumnIndex>0&&"top"in e&&this.$.panel["left-body-scroll"].css({top:e.top}),this.xvar.frozenRowIndex>0&&"left"in e&&this.$.panel["top-body-scroll"].css({left:e.left}),this.$.panel["body-scroll"].css(e),n.footSum&&"left"in e&&this.$.panel["bottom-body-scroll"].css({left:e.left}),!i&&"top"in e&&u.call(this)},m=function(){i.focusClear.call(this),i.clear.call(this),this.isInlineEditing&&x.deActive.call(this)},g=function(e){var n={UD:function(e){var n=!0,a=void 0,o=void 0,l=void 0;for(var s in this.focusedColumn){a=jQuery.extend({},this.focusedColumn[s],!0);break}if(!a)return!1;for(o=this.bodyRowMap[a.rowIndex+"_"+a.colIndex],i.focusClear.call(this),i.clear.call(this),e>0?a.rowIndex+(o.rowspan-1)+e>this.bodyRowTable.rows.length-1?(a.dindex=a.dindex+e,a.rowIndex=0,a.dindex>this.list.length-1&&(a.dindex=this.list.length-1,n=!1)):a.rowIndex=a.rowIndex+e:a.rowIndex+e<0?(a.dindex=a.dindex+e,a.rowIndex=this.bodyRowTable.rows.length-1,a.dindex<0&&(a.dindex=0,n=!1)):a.rowIndex=a.rowIndex+e,l=0;"undefined"==typeof this.bodyRowMap[a.rowIndex+"_"+a.colIndex];){if(0==a.rowIndex||l%2==(e>0?0:1)?a.colIndex--:a.rowIndex--,a.rowIndex<=0&&a.colIndex<=0){n=!1;break}l++}var r=t.util.findPanelByColumnIndex.call(this,a.dindex,a.colIndex);return a.panelName=r.panelName,function(){a.dindex+1>this.xvar.frozenRowIndex&&(a.dindex<=this.xvar.paintStartRowIndex?(f.call(this,{top:-(a.dindex-this.xvar.frozenRowIndex)*this.xvar.bodyTrHeight +}),t.scroller.resize.call(this)):a.dindex+1>this.xvar.paintStartRowIndex+(this.xvar.paintRowCount-2)&&(f.call(this,{top:-(a.dindex-this.xvar.frozenRowIndex-this.xvar.paintRowCount+3)*this.xvar.bodyTrHeight}),t.scroller.resize.call(this)))}.call(this),this.focusedColumn[a.dindex+"_"+a.colIndex+"_"+a.rowIndex]=a,this.$.panel[a.panelName].find('[data-ax5grid-tr-data-index="'+a.dindex+'"]').find('[data-ax5grid-column-rowindex="'+a.rowIndex+'"][data-ax5grid-column-colindex="'+a.colIndex+'"]').attr("data-ax5grid-column-focused","true"),n},LR:function(e){var n,a,o=!0,l=0,s=!1,r="";for(var d in this.focusedColumn){n=jQuery.extend({},this.focusedColumn[d],!0);break}if(!n)return!1;for(a=this.bodyRowMap[n.rowIndex+"_"+n.colIndex],i.focusClear.call(this),i.clear.call(this),e<0?(n.colIndex=n.colIndex+e,n.colIndex<0&&(n.colIndex=0,o=!1)):(n.colIndex=n.colIndex+(a.colspan-1)+e,n.colIndex>this.colGroup.length-1&&(n.colIndex=this.colGroup.length-1,o=!1)),"undefined"==typeof this.bodyRowMap[n.rowIndex+"_"+n.colIndex]&&(n.rowIndex=0),l=0;"undefined"==typeof this.bodyRowMap[n.rowIndex+"_"+n.colIndex];){if(n.colIndex--,n.rowIndex<=0&&n.colIndex<=0){o=!1;break}l++}var c=t.util.findPanelByColumnIndex.call(this,n.dindex,n.colIndex);n.panelName=c.panelName,r=c.containerPanelName,s=c.isScrollPanel,this.focusedColumn[n.dindex+"_"+n.colIndex+"_"+n.rowIndex]=n;var u=this.$.panel[n.panelName].find('[data-ax5grid-tr-data-index="'+n.dindex+'"]').find('[data-ax5grid-column-rowindex="'+n.rowIndex+'"][data-ax5grid-column-colindex="'+n.colIndex+'"]').attr("data-ax5grid-column-focused","true");if(u&&s){var h=function(){return u.position().left+u.outerWidth()>Math.abs(this.$.panel[n.panelName].position().left)+this.$.panel[r].width()?u.position().left+u.outerWidth()-this.$.panel[r].width():Math.abs(this.$.panel[n.panelName].position().left)>u.position().left?u.position().left:void 0}.call(this);"undefined"!=typeof h&&(t.header.scrollTo.call(this,{left:-h}),f.call(this,{left:-h}),t.scroller.resize.call(this))}return o},INDEX:function(e){var n,a,o,l=!0;for(var s in this.focusedColumn){n=jQuery.extend({},this.focusedColumn[s],!0);break}for(n||(n={rowIndex:0,colIndex:0}),a=this.bodyRowMap[n.rowIndex+"_"+n.colIndex],i.focusClear.call(this),i.clear.call(this),"end"==e&&(e=this.list.length-1),n.dindex=e,n.rowIndex=0,o=0;"undefined"==typeof this.bodyRowMap[n.rowIndex+"_"+n.colIndex]&&(0==n.rowIndex||o%2==(_dy>0?0:1)?n.colIndex--:n.rowIndex--,!(n.rowIndex<=0&&n.colIndex<=0));)o++;var r=t.util.findPanelByColumnIndex.call(this,n.dindex,n.colIndex);return n.panelName=r.panelName,function(){n.dindex+1>this.xvar.frozenRowIndex&&(n.dindexthis.xvar.paintStartRowIndex+(this.xvar.paintRowCount-2)&&(f.call(this,{top:-(n.dindex-this.xvar.frozenRowIndex-this.xvar.paintRowCount+3)*this.xvar.bodyTrHeight}),t.scroller.resize.call(this)))}.call(this),this.focusedColumn[n.dindex+"_"+n.colIndex+"_"+n.rowIndex]=n,this.$.panel[n.panelName].find('[data-ax5grid-tr-data-index="'+n.dindex+'"]').find('[data-ax5grid-column-rowindex="'+n.rowIndex+'"][data-ax5grid-column-colindex="'+n.colIndex+'"]').attr("data-ax5grid-column-focused","true"),l}},a={UP:function(){return n.UD.call(this,-1)},DOWN:function(){return n.UD.call(this,1)},LEFT:function(){return n.LR.call(this,-1)},RIGHT:function(){return n.LR.call(this,1)},HOME:function(){return n.INDEX.call(this,0)},END:function(){return n.INDEX.call(this,"end")},position:function(t){return n.INDEX.call(this,t)}};return e in a?a[e].call(this):a.position.call(this,e)},x={active:function(i,n,o){var l,s,r,d,c,u,h,p=this;for(var f in i){if(d=i[f].panelName,l=i[f].dindex,s=i[f].colIndex,r=i[f].rowIndex,c=i[f].colspan,u=this.colGroup[s],!(h=u.editor))return this;if(e.isFunction(h.disabled)&&h.disabled.call({list:this.list,dindex:l,item:this.list[l],key:u.key,value:o}))return this;if(!function(e,i){if(e.type in t.inlineEditor)return"popup"==t.inlineEditor[e.type].editMode}(h)){if("checkbox"==h.type){var m,g;g=h.config&&h.config.trueValue?(m=!(o==h.config.trueValue))?h.config.trueValue:h.config.falseValue:m=0==o||"false"==o||o<"1"?"true":"false",t.data.setValue.call(p,l,u.key,g),a.call(p,["cellChecked"],l,{key:u.key,rowIndex:r,colIndex:s,editorConfig:u.editor.config,checked:m})}return this}if(this.list[l].__isGrouping)return!1;if(f in this.inlineEditing)return!1;this.inlineEditing[f]={editor:h,panelName:d,columnKey:f,column:i[f],useReturnToSave:t.inlineEditor[h.type].useReturnToSave},this.isInlineEditing=!0}if(this.isInlineEditing){var x=t.data.getValue.call(p,l,u.key),v=function(t,i){return e.isNothing(t)&&(t=e.isNothing(x)?"":x),"money"==i.type?e.number(t,{money:!0}):t}.call(this,o,h);return this.inlineEditing[f].$inlineEditorCell=this.$.panel[d].find('[data-ax5grid-tr-data-index="'+l+'"]').find('[data-ax5grid-column-rowindex="'+r+'"][data-ax5grid-column-colindex="'+s+'"]').find("[data-ax5grid-cellholder]"),this.inlineEditing[f].$inlineEditor=t.inlineEditor[h.type].init(this,f,h,this.inlineEditing[f].$inlineEditorCell,v),!0}},deActive:function(i,n,a){if(!this.inlineEditing[n])return this;var o=this.inlineEditing[n].panelName,l=this.inlineEditing[n].column.dindex,s=this.inlineEditing[n].column.rowIndex,r=this.inlineEditing[n].column.colIndex,d=this.bodyRowMap[this.inlineEditing[n].column.rowIndex+"_"+this.inlineEditing[n].column.colIndex],c=function(t){return"undefined"==typeof a?"SELECT"==t.get(0).tagName||"INPUT"==t.get(0).tagName||"TEXTAREA"==t.get(0).tagName?t.val():(i="CANCEL",!1):a}(this.inlineEditing[n].$inlineEditor),u=function(t,i){return"money"==i.type?e.number(t):t}.call(this,c,d.editor),h={CANCEL:function(t,e,i){h.__clear.call(this)},RETURN:function(e,i,n){t.data.setValue.call(this,e,i.key,n)?(h.__clear.call(this),t.body.repaintCell.call(this,o,l,s,r,n)):h.__clear.call(this)},__clear:function(){this.isInlineEditing=!1;var t=this.inlineEditing[n].$inlineEditor.data("binded-ax5ui");"ax5picker"==t?this.inlineEditing[n].$inlineEditor.ax5picker("close"):"ax5select"==t&&this.inlineEditing[n].$inlineEditor.ax5select("close"),this.inlineEditing[n].$inlineEditor.remove(),this.inlineEditing[n].$inlineEditor=null,this.inlineEditing[n].$inlineEditorCell=null,this.inlineEditing[n]=void 0,delete this.inlineEditing[n]}};i in h?h[i||"RETURN"].call(this,l,d,u):h.__clear.call(this)},keydown:function(e,i,n){var o={ESC:function(){for(var t in this.inlineEditing)x.deActive.call(this,"CANCEL",t)},RETURN:function(){if(this.isInlineEditing)this.inlineEditing[i]&&this.inlineEditing[i].useReturnToSave&&x.deActive.call(this,"RETURN",i);else for(var e in this.focusedColumn){var o=this.focusedColumn[e],l=this.bodyRowMap[o.rowIndex+"_"+o.colIndex],s=o.dindex,r="";l&&(this.list[s].__isGrouping||(r=t.data.getValue.call(this,s,l.key)));var d=this.colGroup[o.colIndex];if("inline"===t.inlineEditor[d.editor.type].editMode){if(n&&n.moveFocus);else if(l.editor&&"checkbox"==l.editor.type){r=t.data.getValue.call(this,s,l.key);var c,u;u=l.editor.config&&l.editor.config.trueValue?(c=!(r==l.editor.config.trueValue))?l.editor.config.trueValue:l.editor.config.falseValue:c=0==r||"false"==r||r<"1"?"true":"false",t.data.setValue.call(this,o.dindex,l.key,u),a.call(this,["cellChecked"],s,{key:l.key,rowIndex:o.rowIndex,colIndex:o.colIndex,editorConfig:l.editor.config,checked:c})}}else t.body.inlineEdit.active.call(this,this.focusedColumn,null,r)}}};e in o&&o[e].call(this,e,i,n)}},v=function(){var t=this.config,e=this.list,i=this.bodyRowTable,n=this.footSumTable,a=this.bodyGroupingTable,o=function(t,e,i,n){var a=[],o=void 0,l=void 0,s=void 0,c=void 0,u=void 0,h=void 0,p=void 0;for(o=0,l=n.length;o"),u=0,h=m.rows[s].cols.length;u",f?d.call(this,n[o],o,p):r.call(this,n,n[o],o,p,void 0,"text"),"");a.push("\n")}}return a.join("")},l=function(t,e,i){var n=[],a=void 0,o=void 0,l=void 0,s=void 0,r=void 0;for(a=0,o=e.rows.length;a"),l=0,s=e.rows[a].cols.length;l",c.call(this,i,r),"");n.push("\n")}return n.join("")},s=[];return s.push(o.call(this,this.headerColGroup,i,a,e)),t.footSum&&s.push(l.call(this,this.headerColGroup,n,e)),t.rightSum,s.join("")};t.body={init:l,repaint:u,repaintCell:h,repaintRow:p,updateRowState:a,updateRowStateAll:o,scrollTo:f,blur:m,moveFocus:g,inlineEdit:x,getExcelString:v}}(),function(){var t=ax5.ui.grid,e=ax5.util,i=function(){for(var t=0,i=this.list.length;i--;)"__groupingList"in this.list[i]||(t+=e.number(this.list[i][this.key]));return t},n=function(){for(var t=0,i=this.list.length,n=0;i--;)"__groupingList"in this.list[i]||(t+=e.number(this.list[i][this.key]),n++);return e.number(t/(n||1),{round:2})};t.collector={sum:i,avg:n}}(),function(){var t=ax5.ui.grid,e=ax5.util,i=function(){},n=function(t){for(var e=0,i=t.length,n=[];e0&&c!=s[r].compareString){for(var p={keys:[],labels:[],list:s[r].list},f=0;fthis.list.length?this.list.length:this.config.frozenRowIndex,this.xvar.paintStartRowIndex=void 0,t.page.navigationUpdate.call(this),this.config.body.grouping,this},l=function(t){return{list:this.list,page:this.page}},s=function(e){var i=[],n=0,a=this.list.length;switch(e){case"modified":for(;nthis.list.length?this.list.length:this.config.frozenRowIndex,this.xvar.paintStartRowIndex=void 0,t.page.navigationUpdate.call(this),this},d=function(i){var o=this.config.body.grouping?n.call(this,this.list):this.list,l={first:function(){o.splice(i,1)},last:function(){var t=o.length-1;o.splice(t,1)}};if("undefined"==typeof i&&(i="last"),i in l)l[i].call(this,i);else{if(!e.isNumber(i))throw"invalid argument _dindex";o.splice(i,1)}return o=this.config.body.grouping?a.call(this,x.call(this,this.sortInfo,o)):Object.keys(this.sortInfo).length?a.call(this,x.call(this,this.sortInfo,o)):a.call(this,o),this.list=o,this.needToPaintSum=!0,this.xvar.frozenRowIndex=this.config.frozenRowIndex>this.list.length?this.list.length:this.config.frozenRowIndex,this.xvar.paintStartRowIndex=void 0,t.page.navigationUpdate.call(this),this},c=function(i){var o=this.config.body.grouping?n.call(this,this.list):this.list,l={first:function(){o[0][this.config.columnKeys.deleted]=!0},last:function(){o[o.length-1][this.config.columnKeys.deleted]=!0},selected:function(){for(var t=o.length;t--;)o[t][this.config.columnKeys.selected]&&(o[t][this.config.columnKeys.deleted]=!0)}};if("undefined"==typeof i&&(i="last"),i in l)l[i].call(this,i);else{if(!e.isNumber(i))throw"invalid argument _dindex";o[i][this.config.columnKeys.deleted]=!0}return o=this.config.body.grouping?a.call(this,x.call(this,this.sortInfo,o)):Object.keys(this.sortInfo).length?a.call(this,x.call(this,this.sortInfo,o)):a.call(this,o),this.list=o,this.needToPaintSum=!0,this.xvar.frozenRowIndex=this.config.frozenRowIndex>this.list.length?this.list.length:this.config.frozenRowIndex,this.xvar.paintStartRowIndex=void 0,t.page.navigationUpdate.call(this),this},u=function(t,i){if(!e.isNumber(i))throw"invalid argument _dindex";this.needToPaintSum=!0,this.list.splice(i,1,t),this.config.body.grouping&&(this.list=a.call(this,n.call(this,this.list)))},h=function(e,i,n){var a=p.call(this,e,i);if(this.needToPaintSum=!0,a!==n){if(/[\.\[\]]/.test(i))try{this.list[e][this.config.columnKeys.modified]=!0,Function("val","this"+t.util.getRealPathForDataItem(i)+" = val;").call(this.list[e],n)}catch(o){}else this.list[e][this.config.columnKeys.modified]=!0,this.list[e][i]=n;this.onDataChanged&&this.onDataChanged.call({self:this,list:this.list,dindex:e,item:this.list[e],key:i,value:n})}return!0},p=function(e,i,n){if(/[\.\[\]]/.test(i))try{n=Function("","return this"+t.util.getRealPathForDataItem(i)+";").call(this.list[e])}catch(a){}else n=this.list[e][i];return n},f=function(){this.selectedDataIndexs=[]},m=function(t,e,i){var n=this.config;return!this.list[t].__isGrouping&&(!this.list[t][n.columnKeys.disableSelection]&&("undefined"==typeof e?(this.list[t][n.columnKeys.selected]=!this.list[t][n.columnKeys.selected])&&this.selectedDataIndexs.push(t):(this.list[t][n.columnKeys.selected]=e)&&this.selectedDataIndexs.push(t),this.onDataChanged&&i&&i.internalCall&&this.onDataChanged.call({self:this,list:this.list,dindex:t,item:this.list[t],key:n.columnKeys.selected,value:this.list[t][n.columnKeys.selected]}),this.list[t][n.columnKeys.selected]))},g=function(t,e){var i=this.config,n=this.list.length;if("undefined"==typeof t)for(;n--;)this.list[n].__isGrouping||e&&e.filter&&e.filter.call(this.list[n])!==!0||this.list[n][i.columnKeys.disableSelection]||(this.list[n][i.columnKeys.selected]=!this.list[n][i.columnKeys.selected])&&this.selectedDataIndexs.push(n);else for(;n--;)this.list[n].__isGrouping||e&&e.filter&&e.filter.call(this.list[n])!==!0||this.list[n][i.columnKeys.disableSelection]||(this.list[n][i.columnKeys.selected]=t)&&this.selectedDataIndexs.push(n);return this.onDataChanged&&e&&e.internalCall&&this.onDataChanged.call({self:this,list:this.list}),this.list},x=function(i,n){var a=n||this.list,o=[],l=function(e,i,n){if(/[\.\[\]]/.test(i))try{n=Function("","return this"+t.util.getRealPathForDataItem(i)+";").call(e)}catch(a){}else n=e[i];return n};for(var s in i)o[i[s].seq]={key:s,order:i[s].orderBy};o=e.filter(o,function(){return"undefined"!=typeof this});var r=0,d=o.length,c=void 0,u=void 0;return a.sort(function(t,e){for(r=0;ru)return"asc"===o[r].order?1:-1}}),n?a:(this.xvar.frozenRowIndex=this.config.frozenRowIndex>this.list.length?this.list.length:this.config.frozenRowIndex,this.xvar.paintStartRowIndex=void 0,t.page.navigationUpdate.call(this),this)};t.data={init:i,set:o,get:l,getList:s,setValue:h,getValue:p,clearSelect:f,select:m,selectAll:g,add:r,remove:d,deleteRow:c,update:u,sort:x,initData:a,clearGroupingData:n}}(),function(){var t=ax5.ui.grid,e=(ax5.util,function(t){return window.btoa(unescape(encodeURIComponent(t)))}),i="data:application/vnd.ms-excel;base64,",n=function(){return"\ufeff\n{{#tables}}{{{body}}}{{/tables}}\n"},a=function(t,a){var o,l=[].concat(t);o=ax5.mustache.render(n(),{worksheet:function(){var t=[];return l.forEach(function(e,i){t.push({name:"Sheet"+(i+1)})}),t}(),tables:function(){var t=[];return l.forEach(function(e,i){t.push({body:e})}),t}()});var s=navigator.userAgent.indexOf("Chrome")>-1,r=!s&&navigator.userAgent.indexOf("Safari")>-1,d=!!document.documentMode;if(navigator.msSaveOrOpenBlob){var c=new Blob([o],{type:"text/html"});window.navigator.msSaveOrOpenBlob(c,a)}else if(r){var u=window.open("about:blank",this.id+"-excel-export","width=600,height=400");u.document.write(o),u=null}else if(d&&"undefined"==typeof Blob){var h=jQuery('');jQuery(document.body).append(h);var p=window[this.id+"-excel-export"];p.document.open("text/html","replace"),p.document.write(o),p.document.close(),p.focus(),p.document.execCommand("SaveAs",!0,a),h.remove()}else{var f=document.body.appendChild(document.createElement("a"));"download"in f&&(f.download=a,f.href=i+e(o),f.click(),document.body.removeChild(f))}return!0};t.excel={"export":a}}(),function(){var t=ax5.ui.grid,e=ax5.util,i=function(){return e.number(this.value,{money:!0})};t.formatter={money:i}}(),function(){var t=ax5.ui.grid,e=ax5.util,i={on:function(n,a){var o=this,l=$(n),s=l.offset().left,r=o.$.container.root.offset().left;o.xvar.columnResizerIndex=a;var d={min:-o.colGroup[a]._width+2,max:o.colGroup[a+1]?o.colGroup[a+1]._width:o.$.container.root.width()-2};jQuery(document.body).bind(t.util.ENM.mousemove+".ax5grid-"+this.instanceId,function(e){var i=t.util.getMousePosition(e);o.xvar.__da=i.clientX-o.xvar.mousePosition.clientX,d.min>o.xvar.__da?o.xvar.__da=d.min:d.max':t.label||" "},l=function(t){var i=this.config,n=this.colGroup;t&&(a.call(this),this.xvar.paintStartRowIndex=void 0);var l=this.asideHeaderData,s=this.leftHeaderData,r=this.headerData,d=i.header.align;this.leftHeaderColGroup=n.slice(0,this.config.frozenColumnIndex),this.headerColGroup=n.slice(this.config.frozenColumnIndex);var c=function(t,a,l){var s=0,r=[];r.push(''),r.push("");for(var c=0,u=a.length;c'),s+=a[c]._width;r.push(""),r.push("");for(var h=0,p=l.rows.length;h');for(var m=0,g=l.rows[h].cols.length;m'),r.push(function(){var t=i.header.columnHeight-2*i.header.columnPadding-i.header.columnBorderWidth;return''}(),function(){var t="";return e.isNothing(x.key)||e.isNothing(x.colIndex)||i.sortable!==!0&&x.sortable!==!0||x.sortable===!1||(t+=''),t}(),o.call(this,x),""),e.isNothing(x.colIndex)||i.enableFilter&&r.push(''),r.push("")}r.push(""),r.push("")}return r.push("
"),t.html(r.join("")),function(){for(var n=i.header.columnHeight*l.rows.length-i.header.columnBorderWidth,o=0,s=[],r=0,d=a.length;r'))}t.append(s)}.call(this),s};i.asidePanelWidth>0&&c.call(this,this.$.panel["aside-header"],this.asideColGroup,l),i.frozenColumnIndex>0&&c.call(this,this.$.panel["left-header"],this.leftHeaderColGroup,s),this.xvar.scrollContentWidth=c.call(this,this.$.panel["header-scroll"],this.headerColGroup,r),i.rightSum},s=function(t){return this.$.panel["header-scroll"].css(t),this},r=function(t){var e="",i={},n=0;for(var a in this.sortInfo)this.sortInfo[a].fixed&&(i[a]=this.sortInfo[a],n++);for(var o=0,l=this.colGroup.length;o");for(var l=0,s=e.rows[n].cols.length;l",o.call(this,r),"")}i.push("")}return i.join("")};return i.call(this,t,e)};t.header={init:n,repaint:l,scrollTo:s,toggleSort:r,applySortStatus:d,getExcelString:c}}(),function(){var t=ax5.ui.grid,e={useReturnToSave:!0,editMode:"popup",getHtml:function(t,e,i,n){return''},init:function(e,i,n,a,o){var l;return a.append(l=jQuery(this.getHtml(e,i,n,o))),this.bindUI(e,i,l,n,a,o),l.on("blur",function(){t.body.inlineEdit.deActive.call(e,"RETURN",i)}),l},bindUI:function(t,e,i,n,a,o){i.focus().select()}},i={useReturnToSave:!0,editMode:"popup",getHtml:function(t,e,i,n){return''},init:function(e,i,n,a,o){var l;return a.append(l=jQuery(this.getHtml(e,i,n,o))),this.bindUI(e,i,l,n,a,o),l.on("blur",function(){t.body.inlineEdit.deActive.call(e,"RETURN",i)}),l},bindUI:function(t,e,i,n,a,o){i.data("binded-ax5ui","ax5formater"),i.ax5formatter({pattern:"money"}),i.focus().select()}},n={useReturnToSave:!0,editMode:"popup",getHtml:function(t,e,i,n){return''},init:function(e,i,n,a,o){var l;return a.append(l=jQuery(this.getHtml(e,i,n,o))),this.bindUI(e,i,l,n,a,o),l.on("blur",function(){t.body.inlineEdit.deActive.call(e,"RETURN",i)}),l},bindUI:function(t,e,i,n,a,o){i.data("binded-ax5ui","ax5formater"),i.ax5formatter({pattern:"number"}),i.focus().select()}},a={useReturnToSave:!0,editMode:"popup",getHtml:function(t,e,i,n){return''},init:function(t,e,i,n,a){var o;return n.append(o=jQuery(this.getHtml(t,e,i,a))),this.bindUI(t,e,o,i,n,a),o},bindUI:function(e,i,n,a,o,l){var s=e;n.data("binded-ax5ui","ax5picker"),n.ax5picker({direction:"auto",content:{type:"date",formatter:{pattern:"date"}},onStateChanged:function(){"open"==this.state?this.self.activePicker.attr("data-ax5grid-inline-edit-picker","date"):"close"==this.state&&t.body.inlineEdit.deActive.call(s,"RETURN",i)}}),n.focus().select()}},o={useReturnToSave:!1,editMode:"popup",getHtml:function(t,e,i,n){var a=[];return a.push('
'),a.push("
"),a.join("")},init:function(t,e,i,n,a){var o;return n.append(o=jQuery(this.getHtml(t,e,i,a))),this.bindUI(t,e,o,i,n,a),o},bindUI:function(e,i,n,a,o,l){var s={columnKeys:{optionValue:"value",optionText:"text",optionSelected:"selected"}};jQuery.extend(!0,s,a.config),s.options.forEach(function(t){t[s.columnKeys.optionValue]==l&&(t[s.columnKeys.optionSelected]=!0)});var r=e;n.data("binded-ax5ui","ax5select"),n.ax5select({direction:"auto",columnKeys:s.columnKeys,options:s.options,onStateChanged:function(){"open"==this.state?this.self.activeSelectOptionGroup.attr("data-ax5grid-inline-edit-picker","select"):"changeValue"==this.state?t.body.inlineEdit.deActive.call(r,"RETURN",i,this.value[0][s.columnKeys.optionValue]):"close"==this.state&&t.body.inlineEdit.deActive.call(r,"ESC",i)}}),n.ax5select("open"),n.ax5select("setValue",l),n.find("a").focus()}},l={editMode:"inline",getHtml:function(t,e,i){var n,a=t.config.body.columnHeight-2*t.config.body.columnPadding-t.config.body.columnBorderWidth;n=e.config&&e.config.trueValue?i==e.config.trueValue?"true":"false":0==i||"false"==i||i<"1"?"false":"true";var o={marginTop:2,height:a-4};return jQuery.extend(!0,o,e.config),o.marginTop=(a-o.height)/2,'
'}};t.inlineEditor={text:e,money:i,number:n,date:a,select:o,checkbox:l}}(),function(){var t=ax5.ui.grid,e=ax5.util,i=function(t){var e=function(t){this.page.currentPage!=t&&(this.page.selectPage=t,this.config.page.onChange&&this.config.page.onChange.call({self:this,page:this.page,data:this.data}))},i={first:function(){e.call(this,0)},prev:function(){var t=this.page.currentPage-1;t<0&&(t=0),e.call(this,t)},next:function(){var t=this.page.currentPage+1;t>this.page.totalPages-1&&(t=this.page.totalPages-1),e.call(this,t)},last:function(){e.call(this,this.page.totalPages-1)}};t in i?i[t].call(this):e.call(this,t-1)},n=function(){var e=this;if(this.page){var n={hasPage:!1,currentPage:this.page.currentPage,pageSize:this.page.pageSize,totalElements:this.page.totalElements,totalPages:this.page.totalPages,firstIcon:this.config.page.firstIcon,prevIcon:this.config.page.prevIcon||"«",nextIcon:this.config.page.nextIcon||"»",lastIcon:this.config.page.lastIcon},a=this.config.page.navigationItemCount;n["@paging"]=function(){var t=[],e=n.currentPage-Math.floor(a/2);e<0&&(e=0);var i=n.currentPage+a;i>n.totalPages&&(i=n.totalPages),i-e>a&&(i=e+a),i-e0&&(n.hasPage=!0),this.$.page.navigation.html(t.tmpl.get("page_navigation",n)),this.$.page.navigation.find("[data-ax5grid-page-move]").on("click",function(){var t=this.getAttribute("data-ax5grid-page-move");i.call(e,t)})}else this.$.page.navigation.empty()},a=function(){var i=this.xvar.paintStartRowIndex,n=this.xvar.paintStartRowIndex+this.xvar.paintRowCount-1,a=this.xvar.dataRowCount;n>a&&(n=a),this.$.page.status.html(t.tmpl.get("page_status",{fromRowIndex:e.number(i+1,{money:!0}),toRowIndex:e.number(n,{money:!0}),totalElements:e.number(a,{money:!0}),dataRowCount:a!==this.xvar.dataRealRowCount&&e.number(this.xvar.dataRealRowCount,{money:!0})}))};t.page={navigationUpdate:n,statusUpdate:a}}(),function(){var t=ax5.ui.grid,e=ax5.util,i={vertical:function(t,e){var i=e._content_height-e._panel_height,n=e._vertical_scroller_height-e.verticalScrollBarHeight,a=i*t.top/n;return a<0?a=0:il){s=-l;var r=i[a].call(this,{top:-s},{_content_width:n._content_width,_content_height:n._content_height,_panel_width:n._panel_width,_panel_height:n._panel_height,_horizontal_scroller_width:n._horizontal_scroller_width,_vertical_scroller_height:n._vertical_scroller_height,verticalScrollBarHeight:n.verticalScrollBarHeight,horizontalScrollBarWidth:n.horizontalScrollBarWidth});t.body.scrollTo.call(this,r); +}return-s},horizontal:function(e,n){var a="horizontal",o=n._content_width-n._panel_width,l=n._horizontal_scroller_width-n.horizontalScrollBarWidth,s=l*e/o;if(-s>l){s=-l;var r=i[a].call(this,{left:-s},{_content_width:n._content_width,_content_height:n._content_height,_panel_width:n._panel_width,_panel_height:n._panel_height,_horizontal_scroller_width:n._horizontal_scroller_width,_vertical_scroller_height:n._vertical_scroller_height,verticalScrollBarHeight:n.verticalScrollBarHeight,horizontalScrollBarWidth:n.horizontalScrollBarWidth});t.header.scrollTo.call(this,r),t.body.scrollTo.call(this,r)}return-s}},a={click:function(e,n,a,o){if((new Date).getTime()-t.scroller.moveout_timer<20)return!1;var l=this,s=e.offset(),r={width:n.outerWidth(),height:n.outerHeight()},d={width:e.innerWidth(),height:e.innerHeight()},c=l.$.scroller.vertical.innerHeight(),u=l.$.panel.body.height(),h=l.$.scroller.horizontal.innerWidth(),p=l.$.panel.body.width(),f=l.xvar.scrollContentHeight,m=l.xvar.scrollContentWidth,g=l.$.scroller["vertical-bar"].outerHeight(),x=l.$.scroller["horizontal-bar"].outerWidth(),v={vertical:function(e){var i=t.util.getMousePosition(e),n=i.clientY-s.top;return n<0?n=0:n+r.height>d.height&&(n=d.height-r.height),{top:n}},horizontal:function(e){var i=t.util.getMousePosition(e),n=i.clientX-s.left;return n<0?n=0:n+r.width>d.width&&(n=d.width-r.width),{left:n}}},b=v[a](o);n.css(b);var y=i[a].call(l,b,{_content_width:m,_content_height:f,_panel_width:p,_panel_height:u,_horizontal_scroller_width:h,_vertical_scroller_height:c,verticalScrollBarHeight:g,horizontalScrollBarWidth:x});"horizontal"===a&&t.header.scrollTo.call(l,y),t.body.scrollTo.call(l,y)},on:function(e,n,o,l){var s=this,r=n.position(),d={width:n.outerWidth(),height:n.outerHeight()},c={width:e.innerWidth(),height:e.innerHeight()},u=s.$.scroller.vertical.innerHeight(),h=s.$.panel.body.height(),p=s.$.scroller.horizontal.innerWidth(),f=s.$.panel.body.width(),m=s.xvar.scrollContentHeight,g=s.xvar.scrollContentWidth,x=s.$.scroller["vertical-bar"].outerHeight(),v=s.$.scroller["horizontal-bar"].outerWidth(),b={vertical:function(e){var i=t.util.getMousePosition(e);s.xvar.__da=i.clientY-s.xvar.mousePosition.clientY;var n=r.top+s.xvar.__da;return n<0?n=0:n+d.height>c.height&&(n=c.height-d.height),{top:n}},horizontal:function(e){var i=t.util.getMousePosition(e);s.xvar.__da=i.clientX-s.xvar.mousePosition.clientX;var n=r.left+s.xvar.__da;return n<0?n=0:n+d.width>c.width&&(n=c.width-d.width),{left:n}}};s.xvar.__da=0,jQuery(document.body).bind(t.util.ENM.mousemove+".ax5grid-"+this.instanceId,function(e){var a=b[o](e);n.css(a);var l=i[o].call(s,a,{_content_width:g,_content_height:m,_panel_width:f,_panel_height:h,_horizontal_scroller_width:p,_vertical_scroller_height:u,verticalScrollBarHeight:x,horizontalScrollBarWidth:v});"horizontal"===o&&t.header.scrollTo.call(s,l),t.body.scrollTo.call(s,l)}).bind(t.util.ENM.mouseup+".ax5grid-"+this.instanceId,function(t){a.off.call(s)}).bind("mouseleave.ax5grid-"+this.instanceId,function(t){a.off.call(s)}),jQuery(document.body).attr("unselectable","on").css("user-select","none").on("selectstart",!1)},off:function(){t.scroller.moveout_timer=(new Date).getTime(),jQuery(document.body).unbind(t.util.ENM.mousemove+".ax5grid-"+this.instanceId).unbind(t.util.ENM.mouseup+".ax5grid-"+this.instanceId).unbind("mouseleave.ax5grid-"+this.instanceId),jQuery(document.body).removeAttr("unselectable").css("user-select","auto").off("selectstart")}},o={wheel:function(e){var i=this,n=i.$.panel["body-scroll"].position(),a=i.$.panel.body.height(),o=i.$.panel.body.width(),l=i.xvar.scrollContentHeight,r=i.xvar.scrollContentWidth;if(isNaN(l)||isNaN(r))return!1;var d=void 0,c=void 0,u=!1,h=!1;return d=n.left-e.x,c=n.top-e.y,c>=0?(c=0,u=!0):c<=a-l?(c=a-l,c>=0&&(c=0),u=!0):0==e.y&&(u=!0),d>=0?(d=0,h=!0):d<=o-r?(d=o-r,d>=0&&(d=0),h=!0):0==e.x&&(h=!0),t.header.scrollTo.call(this,{left:d}),t.body.scrollTo.call(this,{left:d,top:c}),s.call(this),!u||!h},on:function(){var i=this,n=i.$.panel["body-scroll"].position(),a=i.$.panel.body.height(),l=i.$.panel.body.width(),r=i.xvar.scrollContentHeight,d=i.xvar.scrollContentWidth,c=function(e){var o=t.util.getMousePosition(e),s=void 0,c=void 0;return i.xvar.__x_da=o.clientX-i.xvar.mousePosition.clientX,i.xvar.__y_da=o.clientY-i.xvar.mousePosition.clientY,s=n.left+i.xvar.__x_da,c=n.top+i.xvar.__y_da,c>=0?c=0:c<=a-r&&(c=a-r,c>=0&&(c=0)),s>=0?s=0:s<=l-d&&(s=l-d,s>=0&&(s=0)),{left:s,top:c}};this.xvar.__x_da=0,this.xvar.__y_da=0,this.xvar.touchmoved=!1,jQuery(document.body).on("touchmove.ax5grid-"+this.instanceId,function(n){var a=c(n);t.header.scrollTo.call(i,{left:a.left}),t.body.scrollTo.call(i,a,"noRepaint"),s.call(i),e.stopEvent(n),i.xvar.touchmoved=!0}).on("touchend.ax5grid-"+this.instanceId,function(n){if(i.xvar.touchmoved){var a=c(n);t.header.scrollTo.call(i,{left:a.left}),t.body.scrollTo.call(i,a),s.call(i),e.stopEvent(n),o.off.call(i)}}),jQuery(document.body).attr("unselectable","on").css("user-select","none").on("selectstart",!1)},off:function(){jQuery(document.body).off("touchmove.ax5grid-"+this.instanceId).off("touchend.ax5grid-"+this.instanceId),jQuery(document.body).removeAttr("unselectable").css("user-select","auto").off("selectstart")}},l=function(){var i=this,n=this.config.scroller.trackPadding;this.$.scroller["vertical-bar"].css({width:this.config.scroller.size-(n+1),left:n/2}),this.$.scroller["horizontal-bar"].css({height:this.config.scroller.size-(n+1),top:n/2}),this.$.scroller["vertical-bar"].on(t.util.ENM.mousedown,function(e){this.xvar.mousePosition=t.util.getMousePosition(e),a.on.call(this,this.$.scroller.vertical,this.$.scroller["vertical-bar"],"vertical",e)}.bind(this)).on("dragstart",function(t){return e.stopEvent(t),!1}),this.$.scroller.vertical.on("click",function(t){"vertical"==t.target.getAttribute("data-ax5grid-scroller")&&a.click.call(this,this.$.scroller.vertical,this.$.scroller["vertical-bar"],"vertical",t)}.bind(this)),this.$.scroller["horizontal-bar"].on(t.util.ENM.mousedown,function(e){this.xvar.mousePosition=t.util.getMousePosition(e),a.on.call(this,this.$.scroller.horizontal,this.$.scroller["horizontal-bar"],"horizontal",e)}.bind(this)).on("dragstart",function(t){return e.stopEvent(t),!1}),this.$.scroller.horizontal.on("click",function(t){"horizontal"==t.target.getAttribute("data-ax5grid-scroller")&&a.click.call(this,this.$.scroller.horizontal,this.$.scroller["horizontal-bar"],"horizontal",t)}.bind(this)),this.$.container.body.on("mousewheel DOMMouseScroll",function(t){var i=t.originalEvent,n={x:0,y:0};i.detail?n.y=10*i.detail:"undefined"==typeof i.deltaY?(n.y=-i.wheelDelta,n.x=0):(n.y=i.deltaY,n.x=i.deltaX),o.wheel.call(this,n)&&e.stopEvent(t)}.bind(this)),document.addEventListener&&ax5.info.supportTouch&&this.$.container.body.on("touchstart","[data-ax5grid-panel]",function(e){i.xvar.mousePosition=t.util.getMousePosition(e),o.on.call(i)})},s=function(){var t=this.$.scroller.vertical.height(),e=this.$.scroller.horizontal.width(),i=this.$.panel.body.height(),a=this.$.panel.body.width(),o=this.xvar.scrollContentHeight,l=this.xvar.scrollContentWidth,s=i*t/o,r=a*e/l;s\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
\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
\n '},i=function(){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=function(){return"{{fromRowIndex}} - {{toRowIndex}} of {{totalElements}}{{#dataRowCount}} ({{dataRowCount}}){{/dataRowCount}}"};t.tmpl={main:e,page_navigation:i,page_status:n,get:function(e,i,n){return ax5.mustache.render(t.tmpl[e].call(this,n),i)}}}(),function(){var t=ax5.ui.grid,e=ax5.util,i=function(t,e){for(var i={rows:[]},n={rows:[]},a=0,o=t.rows.length;a0?(a.rows[e]||(a.rows[e]={cols:[]}),a.rows[e].cols=a.rows[e].cols.concat(l.cols),l.cols.length-1+c):c};l(i,0);for(var s=0,r=a.rows.length;s0?(n.rows[e]||(n.rows[e]={cols:[]}),n.rows[e].cols=n.rows[e].cols.concat(o.cols),o.cols.length-1+u):u};return o(i,0),function(t){for(var e=0,i=t.rows.length;ethis.columns.length);l++){var r=a[l].colspan||1;a[l].label||a[l].key?e.rows[i].cols.push({colspan:r,rowspan:1,colIndex:o,columnAttr:"sum",align:a[l].align,label:a[l].label,key:a[l].key,collector:a[l].collector,formatter:a[l].formatter}):e.rows[i].cols.push({colIndex:o,colspan:r,rowspan:1,label:" "}),o+=r}if(othis.columns.length);a++){var l=t[a].colspan||1;t[a].label||t[a].key?e.rows[i].cols.push({colspan:l,rowspan:1,rowIndex:0,colIndex:n,columnAttr:"default",align:t[a].align,label:t[a].label,key:t[a].key,collector:t[a].collector,formatter:t[a].formatter}):e.rows[i].cols.push({rowIndex:0,colIndex:n,colspan:l,rowspan:1,label:" "}),n+=l}if(nt&&o.push("top"),this.xvar.frozenColumnIndex>e&&o.push("left"),o.push("body"),(this.xvar.frozenColumnIndex<=e||this.xvar.frozenRowIndex<=t)&&(n=o.join("-"),o.push("scroll"),a=!0),{panelName:o.join("-"),containerPanelName:n,isScrollPanel:a}},u=function(t){var e=[],i=[].concat(t.split(/[\.\[\]]/g));return i.forEach(function(t){""!==t&&e.push('["'+t.replace(/['\"]/g,"")+'"]')}),i=null,e.join("")};t.util={divideTableByFrozenColumnIndex:i,getMousePosition:n,ENM:a,makeHeaderTable:o,makeBodyRowTable:l,makeBodyRowMap:s,makeFootSumTable:r,makeBodyGroupingTable:d,findPanelByColumnIndex:c,getRealPathForDataItem:u}}(),function(){var t,e=ax5.ui,i=ax5.util;e.addClass({className:"mediaViewer",version:"1.3.66"},function(){var n=function(){var n,a=this,o={mousedown:ax5.info.supportTouch?"touchstart":"mousedown",mousemove:ax5.info.supportTouch?"touchmove":"mousemove",mouseup:ax5.info.supportTouch?"touchend":"mouseup"},l=function(t){var e="changedTouches"in t.originalEvent?t.originalEvent.changedTouches[0]:t;return{clientX:e.clientX,clientY:e.clientY,time:(new Date).getTime()}};this.instanceId=ax5.getGuid(),this.config={clickEventName:"click",theme:"default",animateTime:250,columnKeys:{src:"src",poster:"poster",html:"html"},loading:{icon:"",text:"Now Loading"},viewer:{prevHandle:!1,nextHandle:!1,ratio:16/9},media:{prevHandle:"<",nextHandle:">",width:36,height:36,list:[]}},this.queue=[],this.openTimer=null,this.closeTimer=null,this.selectedIndex=0,this.mousePosition={},n=this.config;var s=function(){var e=jQuery.extend(!0,{id:this.id},n);try{return t.tmpl.get.call(this,"frame",e,n.columnKeys)}finally{e=null}},r=function(t,e){var o,l="",s={thumbnail:function(t){this.select(t.getAttribute("data-media-thumbnail"))},prev:function(t){this.selectedIndex>0?this.select(this.selectedIndex-1):this.select(n.media.list.length-1)},next:function(t){this.selectedIndex0){for(var t=n.media.list.length,e=0;t--;)if(n.media.list[t].selected){e=t;break}0==e&&(n.media.list[0].selected=!0);try{return e}finally{t=null,e=null}}},c=function(){var t=this.$.list.find("[data-media-thumbnail="+this.selectedIndex+"]"),e=t.position(),i=t.outerWidth(),n=this.$.list.outerWidth(),a=this.$["list-table"].position().left,o=this.$["list-table"].outerWidth(),l=0;e.left+i+a>n?(l=n-(e.left+i),a!=l&&this.$["list-table"].css({left:a=l})):e.left+a<0&&(l=e.left,l>0&&(l=0),a!=l&&this.$["list-table"].css({left:a=l})),a!=l&&a+o0&&(l=0),this.$["list-table"].css({left:l})),t=null,e=null,i=null,n=null,a=null,l=null},u={on:function(t){var e=function(e){var i=e;return"changedTouches"in e.originalEvent&&(i=e.originalEvent.changedTouches[0]),t.__dx=i.clientX-t.clientX,t.__dy=i.clientY-t.clientY,t.__time=(new Date).getTime(),Math.abs(t.__dx)>Math.abs(t.__dy)?{left:t.__dx}:{top:t.__dy}},l=this.$.viewer.width();jQuery(document.body).bind(o.mousemove+".ax5media-viewer-"+this.instanceId,function(t){var o=e(t);if("left"in o){if(a.$["viewer-holder"].css(o),Math.abs(a.mousePosition.__dx)>l/3){var s=0;a.mousePosition.__dx>0?s=a.selectedIndex>0?a.selectedIndex-1:n.media.list.length-1:a.selectedIndex0&&this.attach(n.target)},this.attach=function(t,e){return t||console.log(ax5.info.getError("ax5mediaViewer","401","setConfig")),"undefined"!=typeof e&&this.setConfig(e,!1),this.target=jQuery(t),this.target.html(s.call(this)),this.$={root:this.target.find("[data-ax5-ui-media-viewer]"),"viewer-holder":this.target.find('[data-media-viewer-els="viewer-holder"]'),viewer:this.target.find('[data-media-viewer-els="viewer"]'),"viewer-loading":this.target.find('[data-media-viewer-els="viewer-loading"]'),"list-holder":this.target.find('[data-media-viewer-els="media-list-holder"]'),"list-prev-handle":this.target.find('[data-media-viewer-els="media-list-prev-handle"]'),list:this.target.find('[data-media-viewer-els="media-list"]'),"list-table":this.target.find('[data-media-viewer-els="media-list-table"]'),"list-next-handle":this.target.find('[data-media-viewer-els="media-list-next-handle"]')},this.align(),jQuery(window).unbind("resize.ax5media-viewer-"+this.id).bind("resize.ax5media-viewer-"+this.id,function(){this.align(),c.call(this)}.bind(this)),this.target.unbind("click").bind("click",function(t){t=t||window.event,r.call(this,t),i.stopEvent(t)}.bind(this)),this.$.viewer.unbind(o.mousedown).bind(o.mousedown,function(t){this.mousePosition=l(t),u.on.call(this,this.mousePosition)}.bind(this)).unbind("dragstart").bind("dragstart",function(t){return i.stopEvent(t),!1}),this.select(d.call(this)),this},this.align=function(){if(this.$["viewer-holder"].css({height:this.$.viewer.width()/n.viewer.ratio}),this.$.viewer.css({height:this.$.viewer.width()/n.viewer.ratio}),"image"==this.$.viewer.data("media-type")){var t=this.$.viewer.find("img");t.css({width:this.$.viewer.height()*this.$.viewer.data("img-ratio"),height:this.$.viewer.height()}),setTimeout(function(t){t.css({left:(this.$.viewer.width()-t.width())/2})}.bind(this,t),1)}else"video"==this.$.viewer.data("media-type")&&this.$.viewer.find("iframe").css({width:this.$.viewer.height()*this.$.viewer.data("img-ratio"),height:this.$.viewer.height()});this.$["viewer-loading"].css({height:this.$.viewer.height()});var e="%"==i.right(n.media.width,1)?i.number(n.media.width)/100*this.$.viewer.width():i.number(n.media.width),a="%"==i.right(n.media.height,1)?i.number(n.media.height)/100*this.$.viewer.width():i.number(n.media.height);return e=Math.floor(e),a=Math.floor(a),this.$["list-prev-handle"].css({width:1.5*e}),this.$["list-next-handle"].css({width:1.5*e}),this.$.list.css({height:a}),this.$["list-table"].find("[data-media-thumbnail]").css({width:e,height:a}),this.$["list-table"].find("[data-media-thumbnail-video]").css({width:e,height:a}),this},this.select=function(){var t={image:function(t,e){a.$["viewer-loading"].show();var i=[this.$.viewer.width(),this.$.viewer.height()],o=new Image;return o.src=t.image[n.columnKeys.src],o.onload=function(){a.$["viewer-loading"].fadeOut();var t=i[1],n=t*o.width/o.height;e(o,Math.floor(n),t)},o},video:function(t,e){a.$["viewer-loading"].show();var i=[this.$.viewer.width(),this.$.viewer.height()],o=jQuery(t.video[n.columnKeys.html]);e(o,i[0],i[1]),a.$["viewer-loading"].fadeOut()}},e={image:function(t,e,i){t.width=e,t.height=i;var n=$(t);this.$.viewer.html(n),n.css({left:(this.$.viewer.width()-e)/2}),this.$.viewer.data("media-type","image"),this.$.viewer.data("img-ratio",e/i)},video:function(t,e,i){t.css({width:e,height:i}),this.$.viewer.html(t),this.$.viewer.data("media-type","video"),this.$.viewer.data("img-ratio",e/i)}},i=function(t){this.$.list.find("[data-media-thumbnail]").removeClass("selected"),this.$.list.find("[data-media-thumbnail="+t+"]").addClass("selected"),c.call(this)};return function(a){if("undefined"==typeof a)return this;this.selectedIndex=Number(a);var o=n.media.list[a];i.call(this,a);for(var l in t)if(o[l]){t[l].call(this,o,e[l].bind(this));break}return this}}(),this.setMediaList=function(t){return n.media.list=[].concat(t),this.attach(n.target),this},this.main=function(){e.mediaViewer_instance=e.mediaViewer_instance||[],e.mediaViewer_instance.push(this),arguments&&i.isObject(arguments[0])?this.setConfig(arguments[0]):this.init()}.apply(this,arguments)};return n}()),t=ax5.ui.mediaViewer}(),function(){var t=ax5.ui.mediaViewer,e=function(t){return'\n
\n
\n
\n
\n
\n
\n
\n {{{loading.icon}}}\n {{{loading.text}}}\n
\n
\n
\n {{#media}}\n
\n
{{{prevHandle}}}
\n
\n
\n {{#list}}\n
\n {{#image}}\n
\n \n
\n {{/image}}\n {{#video}}\n
{{#'+t.poster+'}}>{{/'+t.poster+"}}{{^"+t.poster+'}}{{{media.'+t.poster+"}}}{{/"+t.poster+'}}
\n {{/video}}\n
\n {{/list}}\n
\n
\n
{{{nextHandle}}}
\n
\n {{/media}}\n
\n '};t.tmpl={frame:e,get:function(e,i,n){return ax5.mustache.render(t.tmpl[e].call(this,n),i)}}}(),function(){var t=ax5.ui,e=ax5.util,i=void 0;t.addClass({className:"uploader",version:"1.3.66"},function(){var n=function(){var n=this,a=void 0;this.instanceId=ax5.getGuid(),this.config={clickEventName:"click",theme:"default",lang:{upload:"Upload",abort:"Abort"},uploadedBox:{columnKeys:{name:"name",type:"type",size:"size",uploadedName:"uploadedName",uploadedPath:"uploadedPath",downloadPath:"downloadPath",previewPath:"previewPath",thumbnail:"thumbnail"}},animateTime:100,accept:"*/*",multiple:!1,manualUpload:!1,progressBox:!0},this.defaultBtns={upload:{label:this.config.lang.upload,theme:"btn-primary"},abort:{label:this.config.lang.abort,theme:this.config.theme}},this.uploadedFiles=[],this.$target=null,this.$inputContainer=null,this.$inputFile=null,this.$inputFileForm=null,this.$fileSelector=null,this.$dropZone=null,this.$uploadedBox=null,this.__uploading=!1,this.selectedFiles=[],this.selectedFilesTotal=0,this.__loaded=0,a=this.config;var o=function(t){return a.onStateChanged?a.onStateChanged.call(t,t):this.onStateChanged&&this.onStateChanged.call(t,t),t=null,!0}.bind(this),l=function(t){var i=void 0;return ax5.info.supportFileApi?"dataTransfer"in t?i=t.dataTransfer.files:"target"in t?i=t.target.files:t&&(i=t):i={path:t.target.value},!!i&&(length in i?this.selectedFiles=e.toArray(i):this.selectedFiles=[i],a.progressBox&&c(),a.manualUpload||this.send(),void(ax5.info.supportFileApi||r(!1)))}.bind(this),s=function(){this.$fileSelector.off("click.ax5uploader").on("click.ax5uploader",function(){this.$inputFile.trigger("click")}.bind(this)),ax5.info.supportFileApi||(this.$fileSelector.off("mouseover.ax5uploader").on("mouseover.ax5uploader",function(){r(!0)}.bind(this)),this.$inputFile.off("mouseover.ax5uploader").on("mouseover.ax5uploader",function(){this.$fileSelector.addClass("active")}.bind(this)),this.$inputFile.off("mouseout.ax5uploader").on("mouseout.ax5uploader",function(){this.$fileSelector.removeClass("active"),r(!1)}.bind(this))),function(){return!(!this.$uploadedBox||!this.$uploadedBox.get(0))&&void this.$uploadedBox.on("click","[data-uploaded-item-cell]",function(){var t=jQuery(this),e=t.attr("data-uploaded-item-cell"),i=Number(t.parents("[data-ax5uploader-uploaded-item]").attr("data-ax5uploader-uploaded-item")),o={};a.uploadedBox&&a.uploadedBox.onclick&&(o={self:n,cellType:e,uploadedFiles:n.uploadedFiles,fileIndex:i},a.uploadedBox.onclick.call(o,o)),t=null,e=null,i=null,o=null})}.call(this),function(){if(!ax5.info.supportFileApi)return!1;if(!this.$dropZone||!this.$dropZone.get(0))return!1;this.$dropZone.parent().on("click","[data-ax5uploader-dropzone]",function(t){(this==t.target||$.contains(this,t.target))&&(e.isFunction(a.dropZone.onclick)?a.dropZone.onclick.call({self:n}):n.$inputFile.trigger("click"))}),this.$dropZone.get(0).addEventListener("dragover",function(t){e.stopEvent(t),e.isFunction(a.dropZone.ondragover)?a.dropZone.ondragover.call({self:n}):n.$dropZone.addClass("dragover")},!1),this.$dropZone.get(0).addEventListener("dragleave",function(t){e.stopEvent(t),e.isFunction(a.dropZone.ondragover)?a.dropZone.ondragout.call({self:n}):n.$dropZone.removeClass("dragover")},!1),this.$dropZone.get(0).addEventListener("drop",function(t){e.stopEvent(t),e.isFunction(a.dropZone.ondrop)?a.dropZone.ondrop.call({self:n}):n.$dropZone.removeClass("dragover"),l(t||window.event)},!1)}.call(this)}.bind(this),r=function(t){if(t){if(!ax5.info.supportFileApi){var e=this.$fileSelector.offset();e.width=this.$fileSelector.outerWidth(),e.height=this.$fileSelector.outerHeight(),this.$inputFile.css(e)}}else this.$inputFile.css({left:-1e3,top:-1e3})}.bind(this),d=function(t){var e=function(){var e=jQuery(window),i=jQuery(document.body),n={},o=6,l={},s={},r=void 0;n=this.$progressBox.parent().get(0)==this.$target.get(0)?this.$fileSelector.position():this.$fileSelector.offset(),l={width:this.$fileSelector.outerWidth(),height:this.$fileSelector.outerHeight()},s={winWidth:Math.max(e.width(),i.width()),winHeight:Math.max(e.height(),i.height()),width:this.$progressBox.outerWidth(),height:this.$progressBox.outerHeight()},a.progressBoxDirection&&""!==a.progressBoxDirection&&"auto"!==a.progressBoxDirection?r=a.progressBoxDirection:(r="top",n.top-s.height-o<0?r="top":n.top+l.height+s.height+o>s.winHeight&&(r="bottom")),t&&this.$progressBox.addClass("direction-"+r);var d=function(){var t={left:0,top:0};switch(r){case"top":t.left=n.left+l.width/2-s.width/2,t.top=n.top+l.height+o;break;case"bottom":t.left=n.left+l.width/2-s.width/2,t.top=n.top-s.height-o;break;case"left":t.left=n.left+l.width+o,t.top=n.top-s.height/2+l.height/2;break;case"right":t.left=n.left-s.width-o,t.top=n.top-s.height/2+l.height/2}return t}();(function(){"top"!=r&&"bottom"!=r||(d.left<0?(d.left=o,this.$progressBoxArrow.css({left:n.left+l.width/2-d.left})):d.left+s.width>s.winWidth&&(d.left=s.winWidth-s.width-o,this.$progressBoxArrow.css({left:n.left+l.width/2-d.left})))}).call(this),this.$progressBox.css(d)};this.$progressBox.css({top:-999}),t&&(function(){return a.viewport?jQuery(a.viewport.selector):this.$target}.call(this).append(this.$progressBox),this.$progressBox.off("click.ax5uploader").on("click.ax5uploader","button",function(t){var e=t.target.getAttribute("data-pregressbox-btn"),i={upload:function(){this.send()},abort:function(){this.abort()}};i[e]&&i[e].call(this)}.bind(this))),setTimeout(function(){e.call(this)}.bind(this))}.bind(this),c=function(){this.$progressBox.removeClass("destroy"),this.$progressUpload.removeAttr("disabled"),this.$progressAbort.removeAttr("disabled"),d("append"),o({self:this,state:"open" +})}.bind(this),u=function(){this.$progressBox.addClass("destroy"),setTimeout(function(){this.$progressBox.remove()}.bind(this),a.animateTime)}.bind(this),h=function(){var t={html5:function(){var t=this.selectedFiles.shift();if(!t)return m(),this;var i=new FormData;this.$target.find("input").each(function(){i.append(this.name,this.value)}),i.append(a.form.fileName,t),this.xhr=new XMLHttpRequest,this.xhr.open("post",a.form.action,!0),this.xhr.onload=function(t){var i=t.target.response;try{"string"==typeof i&&(i=e.parseJson(i))}catch(t){return!1}return a.debug&&console.log(i),i.error?(a.debug&&console.log(i.error),e.isFunction(a.onuploaderror)&&a.onuploaderror.call({self:this,error:i.error},i),n.send(),!1):(f(i),void n.send())},this.xhr.upload.onprogress=function(t){p(t),e.isFunction(a.onprogress)&&a.onprogress.call({loaded:t.loaded,total:t.total},t)},this.xhr.send(i)},form:function(){this.__uploading=!0;var t=jQuery('');jQuery(document.body).append(t),t.load(function(){var e=this.contentWindow?this.contentWindow.document:this.contentDocument?this.contentDocument:this.document,i=e.documentElement?e.documentElement:e.body,n=i.textContent?i.textContent:i.innerText,o=void 0;try{o=JSON.parse(n)}catch(l){o={error:"Syntax error",body:n}}a.debug&&console.log(o),o.error?console.log(o):(f(o),t.remove(),setTimeout(function(){m()},300))}),this.$inputFileForm.attr("target","ax5uploader-"+this.instanceId+"-iframe").attr("action",a.form.action).submit(),this.selectedFilesTotal=1,p({loaded:1,total:1})}};if(this.__uploading===!1){var i=0;this.selectedFiles.forEach(function(t){i+=t.size}),this.selectedFilesTotal=i,this.__loaded=0,this.__uploading=!0,this.$progressUpload.attr("disabled","disabled"),this.$progressAbort.removeAttr("disabled")}t[ax5.info.supportFileApi?"html5":"form"].call(this)}.bind(this),p=function(t){this.__loaded+=t.loaded,this.$progressBar.css({width:e.number(this.__loaded/this.selectedFilesTotal*100,{round:2})+"%"}),t.lengthComputable&&t.loaded>=t.total}.bind(this),f=function(t){a.debug&&console.log(t),this.uploadedFiles.push(t),x(),e.isFunction(a.onuploaded)&&a.onuploaded.call({self:this},t)}.bind(this),m=function(){this.__uploading=!1,this.$progressUpload.removeAttr("disabled"),this.$progressAbort.attr("disabled","disabled"),a.progressBox&&u(),e.isFunction(a.onuploadComplete)&&a.onuploadComplete.call({self:this}),v()}.bind(this),g=function(){var t={html5:function(){this.xhr&&this.xhr.abort()},form:function(){}};this.__uploading=!1,this.$progressUpload.removeAttr("disabled"),this.$progressAbort.attr("disabled","disabled"),t[ax5.info.supportFileApi?"html5":"form"].call(this),a.progressBox&&u(),v(),a.debug&&console.log("cancelUpload")}.bind(this),x=function(){return null===this.$uploadedBox?this:void this.$uploadedBox.html(i.tmpl.get("upoadedBox",{uploadedFiles:this.uploadedFiles,icon:a.uploadedBox.icon,lang:a.uploadedBox.lang,supportFileApi:!!ax5.info.supportFileApi},a.uploadedBox.columnKeys))}.bind(this),v=function(){this.$inputFile&&this.$inputFile.get(0)&&this.$inputFile.remove(),this.$inputFileForm&&this.$inputFileForm.get(0)&&this.$inputFileForm.remove(),this.$inputFile=jQuery(i.tmpl.get.call(this,"inputFile",{instanceId:this.instanceId,multiple:a.multiple,accept:a.accept,name:a.form.fileName})),ax5.info.supportFileApi?jQuery(document.body).append(this.$inputFile):(this.$fileSelector.attr("tabindex",-1),this.$inputFileForm=jQuery(i.tmpl.get.call(this,"inputFileForm",{instanceId:this.instanceId})),this.$inputFileForm.append(this.$inputFile),jQuery(document.body).append(this.$inputFileForm)),this.$inputFile.off("change.ax5uploader").on("change.ax5uploader",function(t){l(t)}.bind(this))}.bind(this);this.init=function(t){return a=jQuery.extend(!0,{},a,t),a.target?(this.$target=jQuery(a.target),a.dropZone&&a.dropZone.target&&ax5.info.supportFileApi&&(this.$dropZone=jQuery(a.dropZone.target),this.$dropZone.attr("data-ax5uploader-dropzone",this.instanceId)),a.uploadedBox&&a.uploadedBox.target&&(this.$uploadedBox=jQuery(a.uploadedBox.target)),function(t){e.isObject(t)&&!t.error&&(a=jQuery.extend(!0,a,t))}.call(this,e.parseJson(this.$target.attr("data-ax5uploader-config"),!0)),this.$fileSelector=this.$target.find('[data-ax5uploader-button="selector"]'),0===this.$fileSelector.length?(console.log(ax5.info.getError("ax5uploader","402","can not find file selector")),this):(v(),a.btns=jQuery.extend({},this.defaultBtns,a.btns),this.$progressBox=jQuery(i.tmpl.get.call(this,"progressBox",{instanceId:this.instanceId,btns:a.btns})),this.$progressBar=this.$progressBox.find('[role="progressbar"]'),this.$progressBoxArrow=this.$progressBox.find(".ax-progressbox-arrow"),this.$progressUpload=this.$progressBox.find('[data-pregressbox-btn="upload"]'),this.$progressAbort=this.$progressBox.find('[data-pregressbox-btn="abort"]'),ax5.info.supportFileApi||this.$progressAbort.hide(),s(),x(),this)):(console.log(ax5.info.getError("ax5uploader","401","init")),this)},this.send=function(){return function(){if(e.isFunction(a.validateSelectedFiles)){var t={self:this,uploadedFiles:this.uploadedFiles,selectedFiles:this.selectedFiles};if(!a.validateSelectedFiles.call(t,t))return g(),!1}return h(),this}}(),this.abort=function(){return function(){return ax5.info.supportFileApi?(g(),this):(alert("This browser not supported abort method"),this)}}(),this.setUploadedFiles=function(t){if(e.isArray(t)&&(this.uploadedFiles=t),e.isString(t))try{this.uploadedFiles=JSON.parse(t)}catch(i){}return x(),this},this.removeFile=function(t){return isNaN(Number(t))||this.uploadedFiles.splice(t,1),x(),this},this.removeFileAll=function(){return this.uploadedFiles=[],x(),this},this.selectFile=function(){return!!ax5.info.supportFileApi&&(this.$inputFile.trigger("click"),!0)},this.main=function(){t.uploader_instance=t.uploader_instance||[],t.uploader_instance.push(this),arguments&&e.isObject(arguments[0])&&this.setConfig(arguments[0])}.apply(this,arguments)};return n}()),i=ax5.ui.uploader}(),function(){var t=ax5.ui.uploader,e=function(t){return"\n "},i=function(t){return''},n=function(t){return'
'},a=function(t){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'},o=function(t){return'\n{{#uploadedFiles}}
\n
\n
{{{icon.download}}}
\n
{{'+t.name+'}}
\n
({{#@fn_get_byte}}{{'+t.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'};t.tmpl={uploadProgress:e,inputFile:i,inputFileForm:n,progressBox:a,upoadedBox:o,get:function(e,i,n){return i["@fn_get_byte"]=function(){return function(t,e){return ax5.util.number(e(t),{round:2,"byte":!0})}},ax5.mustache.render(t.tmpl[e].call(this,n),i)}}}(),function(){var t,e=ax5.ui,i=ax5.util;e.addClass({className:"combobox",version:"1.3.66"},function(){var e=function(){var e,n=this;this.instanceId=ax5.getGuid(),this.config={theme:"default",animateTime:250,removeIcon:"X",lang:{noSelected:"",noOptions:"no options",loading:"now loading.."},columnKeys:{optionValue:"value",optionText:"text",optionSelected:"selected"}},this.queue=[],this.activecomboboxOptionGroup=null,this.activecomboboxQueueIndex=-1,this.openTimer=null,this.closeTimer=null,this.waitOptionsCallback=null,this.keyUpTimer=null,e=this.config;var a=jQuery(window),o=function(t,e){return t&&t.onStateChanged?t.onStateChanged.call(e,e):this.onStateChanged&&this.onStateChanged.call(e,e),"changeValue"==e.state&&(t&&t.onChange?t.onChange.call(e,e):this.onChange&&this.onChange.call(e,e)),t=null,e=null,!0},l=function(){for(var t,e=this.queue.length;e--;){var n=this.queue[e];if(n.$display&&(t=Math.max(n.$select.outerWidth(),i.number(n.minWidth)),n.$display.css({"min-width":t}),n.reset&&n.$display.find(".addon-icon-reset").css({"line-height":this.queue[e].$display.height()+"px"}),n.multiple)){var a=function(){return i.number(n.$display.css("border-top-width"))+i.number(n.$display.css("border-bottom-width"))}.call(this);n.$target.height(""),n.$display.height("");var o=n.$displayTable.outerHeight();Math.abs(o-n.$target.height())>a&&(n.$target.css({height:o+a+4}),n.$display.css({height:o+a+4}))}}return e=null,t=null,this},s=function(t){if(!this.activecomboboxOptionGroup)return this;var e,i=this.queue[this.activecomboboxQueueIndex],n={},o=0,l={},s={};t&&jQuery(document.body).append(this.activecomboboxOptionGroup),n=i.$target.offset(),l={width:i.$target.outerWidth(),height:i.$target.outerHeight()},s={winWidth:Math.max(a.width(),jQuery(document.body).width()),winHeight:Math.max(a.height(),jQuery(document.body).height()),width:this.activecomboboxOptionGroup.outerWidth(),height:this.activecomboboxOptionGroup.outerHeight()},i.direction&&""!==i.direction&&"auto"!==i.direction?e=i.direction:(e="top",n.top-s.height-o<0?e="top":n.top+l.height+s.height+o>s.winHeight&&(e="bottom")),t&&this.activecomboboxOptionGroup.addClass("direction-"+e),this.activecomboboxOptionGroup.css(function(){if("top"==e){if(n.top+l.height+s.height+o>s.winHeight){var t=n.top+l.height/2-s.height/2;return t+s.height+o>s.winHeight&&(t=0),t<0&&(t=0),{left:n.left,top:t,width:l.width}}return{left:n.left,top:n.top+l.height+1,width:l.width}}if("bottom"==e)return{left:n.left,top:n.top-s.height-1,width:l.width}}.call(this))},r=function(t,e){if(!this.activecomboboxOptionGroup)return this;var n=this.queue[this.activecomboboxQueueIndex],a="display";return(e=i.findParentNode(t.target,function(t){return t.getAttribute("data-option-value")?(a="optionItem",!0):n.$target.get(0)==t?(a="display",!0):void 0}))?("optionItem"===a&&(_.call(this,n.id,{index:{gindex:e.getAttribute("data-option-group-index"),index:e.getAttribute("data-option-index")}},void 0,!0),l.call(this),s.call(this),n.multiple||this.close()),this):(this.close(),this)},d=function(e){var i=this.queue[e],n={};return n.id=i.id,n.theme=i.theme,n.size="ax5combobox-option-group-"+i.size,n.multiple=i.multiple,n.lang=i.lang,n.options=i.options,n.selected=i.selected,n.hasSelected=n.selected&&n.selected.length>0,n.removeIcon=i.removeIcon,t.tmpl.get.call(this,"label",n,i.columnKeys)},c=function(t){var e=this.queue[t];e.$displayLabel.find("[data-ax5combobox-selected-label]").remove(),e.$displayLabelInput.before(d.call(this,t))},u=function(t){return this.queue[t].disabled?this:(this.queue[t].$displayLabel.trigger("focus"),void this.queue[t].$displayLabelInput.focus())},h=function(t){this.queue[t].$displayLabelInput.val("")},p=function(t){this.queue[t].$displayLabel.trigger("blur"),this.queue[t].$displayLabelInput.trigger("blur")},f=function(e,n){this.queue[e].waitOptions=!0,this.activecomboboxOptionGroup.find('[data-els="content"]').html(jQuery(t.tmpl.get.call(this,"option",this.queue[e],this.queue[e].columnKeys))),this.queue[e].onSearch.call({self:this,item:this.queue[e],searchWord:n},function(e){var n={},a=this.queue[this.activecomboboxQueueIndex];return!!a&&(function(t,e){var n={};e.options.forEach(function(e,i){e["@index"]=i,n[e[t.columnKeys.optionValue]]=e}),i.isArray(t.selected)&&t.selected.forEach(function(i){n[i[t.columnKeys.optionValue]]&&(e.options[n[i[t.columnKeys.optionValue]]["@index"]][t.columnKeys.optionSelected]=!0)})}(a,e),a.options=v.call(this,this.activecomboboxQueueIndex,e.options),l.call(this),n.id=a.id,n.theme=a.theme,n.size="ax5combobox-option-group-"+a.size,n.multiple=a.multiple,n.lang=a.lang,n.options=a.options,void this.activecomboboxOptionGroup.find('[data-els="content"]').html(jQuery(t.tmpl.get.call(this,"options",n,a.columnKeys))))}.bind(this))},m=function(t,e){if(this.activecomboboxQueueIndex==-1)return this;var i,n=[],a=-1,o=this.queue[t].indexedOptions.length-1;if(""!=e){var l=/[\{\}\[\]\/?.,;:|\)*~`!^\-_+<>@\#$%&\\\=\(\'\"]/gi;if(e=e.replace(l,""),this.queue[t].onSearch){f.call(this,t,e);try{return n}finally{n=null,a=null,o=null,i=null}}for(;o-a++;){if(i=this.queue[t].indexedOptions[a],(""+i.text).toLowerCase()==e.toLowerCase()){n=[{"@findex":i["@findex"],optionsSort:0}];break}var s=(""+i.text).toLowerCase().search(e.toLowerCase());if(s>-1&&(n.push({"@findex":i["@findex"],optionsSort:s}),n.length>2))break;s=null}n.sort(function(t,e){return t.optionsSort-e.optionsSort})}n&&n.length>0?x.call(this,t,void 0,n[0]["@findex"]):g.call(this,t);try{return n}finally{n=null,a=null,o=null,i=null}},g=function(t){this.activecomboboxOptionGroup&&this.activecomboboxOptionGroup.find("[data-option-focus-index]").removeClass("hover").removeAttr("data-option-selected"),this.queue[t].optionFocusIndex=-1},x=function(t,e,i){var n,a,o,l,s=this.queue[t];if(this.activecomboboxOptionGroup&&s.options&&s.options.length>0){if("undefined"!=typeof i?n=i:(a=s.optionFocusIndex==-1?s.optionSelectedIndex||-1:s.optionFocusIndex,a==-1?n=0:(n=a+e,n<0?n=0:n>s.optionItemLength-1&&(n=s.optionItemLength-1))),s.optionFocusIndex=n,s.options[n]&&s.options[n].hide){if("undefined"==typeof e)return this;for(;s.options[n].hide;){if(n+=e,n<0){n=0;break}if(n>s.optionItemLength-1){n=s.optionItemLength-1;break}}}if("undefined"!=typeof n&&(this.activecomboboxOptionGroup.find("[data-option-focus-index]").removeClass("hover"),o=this.activecomboboxOptionGroup.find('[data-option-focus-index="'+n+'"]').addClass("hover"),l=this.activecomboboxOptionGroup.find('[data-els="content"]'),o.get(0))){var r=o.outerHeight(),d=l.innerHeight(),c=l.scrollTop(),u=o.position().top+l.scrollTop();d+cu&&l.scrollTop(u),"undefined"!=typeof e&&s.$displayLabelInput.val(s.options[n].text)}}},v=function(){var t=function(t,e){e?this.queue[t].selected.push(jQuery.extend({},e)):this.queue[t].selected=[]};return function(e,a){var o,l,s,r=this.queue[e],d=0;return t.call(this,e,!1),a?(r.options=a,r.indexedOptions=[],o=[],o.push(''),r.options.forEach(function(i,a){i.optgroup?(i["@gindex"]=a,i.options.forEach(function(i,l){i["@index"]=l,i["@findex"]=d,o.push('"),i[r.columnKeys.optionSelected]&&t.call(n,e,i),r.indexedOptions.push({"@gindex":a,"@index":l,"@findex":d,value:i[r.columnKeys.optionValue],text:i[r.columnKeys.optionText]}),d++})):(i["@index"]=a,i["@findex"]=d,o.push('"),i[r.columnKeys.optionSelected]&&t.call(n,e,i),r.indexedOptions.push({"@index":a,"@findex":d,value:i[r.columnKeys.optionValue],text:i[r.columnKeys.optionText]}),d++)}),r.optionItemLength=d,r.$select.html(o.join(""))):(r.$select.get(0).options&&r.$select.get(0).options.length&&(r.$select.get(0).options[0].selected=!1),l=i.toArray(r.$select.get(0).options),s=[],l.forEach(function(i,a){var o={};o[r.columnKeys.optionValue]=i.value,o[r.columnKeys.optionText]=i.text,o[r.columnKeys.optionSelected]=i.selected,o["@index"]=a,o["@findex"]=d,i.selected&&t.call(n,e,o),s.push(o),d++,o=null}),r.options=s,r.indexedOptions=s,r.$select.prepend(''),r.$select.get(0).options[0].selected=!0),o=null,l=null,s=null,r.options}}(),b=function(t){return t instanceof jQuery?t=t.data("data-ax5combobox-id"):i.isString(t)||(t=jQuery(t).data("data-ax5combobox-id")),i.isString(t)?i.search(this.queue,function(){return this.id==t}):void console.log(ax5.info.getError("ax5combobox","402","getQueIdx"))},y=function(t,e,i){return"undefined"==typeof i?!t.multiple||!e:i},w=function(t){this.queue[t].options.forEach(function(t){t.optgroup?t.options.forEach(function(t){t.selected=!1}):t.selected=!1})},_=function(){var t={index:function(t,e,a,o){var l=this.queue[t];i.isString(e.index.gindex)?"undefined"!=typeof l.options[e.index.gindex]&&(l.options[e.index.gindex].options[e.index.index][l.columnKeys.optionSelected]=y(l,l.options[e.index.gindex].options[e.index.index][l.columnKeys.optionSelected],a),n.activecomboboxOptionGroup&&n.activecomboboxOptionGroup.find('[data-option-group-index="'+e.index.gindex+'"][data-option-index="'+e.index.index+'"]').attr("data-option-Selected",l.options[e.index.gindex].options[e.index.index][l.columnKeys.optionSelected].toString())):"undefined"!=typeof l.options[e.index.index]&&(l.options[e.index.index][l.columnKeys.optionSelected]=y(l,l.options[e.index.index][l.columnKeys.optionSelected],a),n.activecomboboxOptionGroup&&n.activecomboboxOptionGroup.find('[data-option-index="'+e.index.index+'"]').attr("data-option-Selected",l.options[e.index.index][l.columnKeys.optionSelected].toString())),"undefined"!=typeof o&&"justSetValue"===o||(v.call(this,t,l.options),s.call(this))},arr:function(e,a,o,l){a.forEach(function(a){if(i.isString(a)||i.isNumber(a))t.text.call(n,e,a,o,"justSetValue");else for(var l in t)if(a[l]){t[l].call(n,e,a,o,"justSetValue");break}}),v.call(this,e,this.queue[e].options),s.call(this)},value:function(t,e,n,a){var o,l=this.queue[t],r=i.search(l.options,function(){return this[l.columnKeys.optionValue]==e[l.columnKeys.optionValue]});r>-1?l.options[r][l.columnKeys.optionSelected]=y(l,l.options[r][l.columnKeys.optionSelected],n):(r=l.options.length,o={"@index":r,hide:!0,addedOption:!0},o[l.columnKeys.optionValue]=e,o[l.columnKeys.optionText]=e,l.options.push(o),l.options[r][l.columnKeys.optionSelected]=y(l,l.options[r][l.columnKeys.optionSelected],n)),"undefined"!=typeof a&&"justSetValue"===a||(v.call(this,t,this.queue[t].options),s.call(this))},text:function(t,e,n,a){var o,l=this.queue[t],r=i.search(l.options,function(){return this[l.columnKeys.optionText]==e});r>-1?l.options[r][l.columnKeys.optionSelected]=y(l,l.options[r][l.columnKeys.optionSelected],n):(r=l.options.length,o={"@index":r,hide:!0,addedOption:!0},o[l.columnKeys.optionValue]=e,o[l.columnKeys.optionText]=e,l.options.push(o),l.options[r][l.columnKeys.optionSelected]=y(l,l.options[r][l.columnKeys.optionSelected],n)),"undefined"!=typeof a&&"justSetValue"===a||(v.call(this,t,this.queue[t].options),s.call(this))},clear:function(t){w.call(this,t),v.call(this,t,this.queue[t].options),g.call(this,t),this.activecomboboxOptionGroup&&this.activecomboboxOptionGroup.find("[data-option-index]").attr("data-option-Selected","false"),this.queue[t].optionSelectedIndex=-1}};return function(e,n,a,l){var s=i.isNumber(e)?e:b.call(this,e);if(s===-1)return void console.log(ax5.info.getError("ax5combobox","402","val"));if("undefined"==typeof n)throw"error not found value";if(i.isArray(n))t.clear.call(this,s),t.arr.call(this,s,this.queue[s].multiple||0==n.length?n:[n[n.length-1]],a);else if(i.isString(n)||i.isNumber(n))"undefined"==typeof n||null===n||this.queue[s].multiple||w.call(this,s),t.text.call(this,s,n,a,"justSetValue");else if(null===n)t.clear.call(this,s);else{this.queue[s].multiple||w.call(this,s);for(var r in t)if(n[r]){t[r].call(this,s,n,a,"justSetValue");break}}return v.call(this,s,this.queue[s].options),c.call(this,s),u.call(this,s),"undefined"!=typeof n&&l&&!l.noStateChange&&o.call(this,this.queue[s],{self:this,item:this.queue[s],state:"changeValue",value:this.queue[s].selected}),e=null,this}}();this.init=function(){this.onStateChanged=e.onStateChanged,this.onChange=e.onChange,jQuery(window).bind("resize.ax5combobox-display-"+this.instanceId,function(){l.call(this)}.bind(this))},this.bind=function(a){var o,r=function(){var e=i.debounce(function(t){return this.activecomboboxQueueIndex==-1?this:void m.call(n,t,this.queue[t].$displayLabelInput.val())},150),o=function(t){h.call(this,t)},r={click:function(t,e){var a,o=i.findParentNode(e.target,function(t){return t.getAttribute("data-ax5combobox-remove")?(a="optionItemRemove",!0):t.getAttribute("data-selected-clear")?(a="clear",!0):void 0});if(o){if("optionItemRemove"===a){var r=o.getAttribute("data-ax5combobox-remove-index"),d=this.queue[t].selected[r];return _.call(this,t,{index:{gindex:d["@gindex"],index:d["@index"]}},!1,!0),l.call(this),s.call(this),u.call(this,t),i.stopEvent(e),this}"clear"===a&&(_.call(this,t,{clear:!0}),l.call(this),s.call(this),u.call(this,t))}else n.activecomboboxQueueIndex==t?this.queue[t].optionFocusIndex==-1&&n.close():(n.open(t),u.call(this,t))},keyUp:function(t,a){if(a.which==ax5.info.eventKeys.ESC&&n.activecomboboxQueueIndex===-1)return i.stopEvent(a),this;n.activecomboboxQueueIndex!=t&&(n.open(t),i.stopEvent(a));var o={40:"KEY_DOWN",38:"KEY_UP"};if(!o[a.which])if(a.which==ax5.info.eventKeys.BACKSPACE&&""==this.queue[t].$displayLabelInput.val()){if(this.queue[t].selected.length>0){var r=this.queue[t].selected[this.queue[t].selected.length-1];_.call(this,t,{index:{gindex:r["@gindex"],index:r["@index"]}},!1,!0)}l.call(this),s.call(this),i.stopEvent(a)}else e.call(this,t)},keyDown:function(t,e){e.which==ax5.info.eventKeys.ESC?(h.call(this,t),this.close(),i.stopEvent(e)):e.which==ax5.info.eventKeys.RETURN?(_.call(this,a.id,{index:{gindex:a.indexedOptions[a.optionFocusIndex]["@gindex"],index:a.indexedOptions[a.optionFocusIndex]["@index"]}},void 0,!0),h.call(this,t),l.call(this),this.close(),i.stopEvent(e)):e.which==ax5.info.eventKeys.DOWN?(x.call(this,t,1),i.stopEvent(e)):e.which==ax5.info.eventKeys.UP&&(x.call(this,t,-1),i.stopEvent(e))},focus:function(t,e){},blur:function(t,e){o.call(this,t),i.stopEvent(e)},selectChange:function(t,e){_.call(this,t,{value:this.queue[t].$select.val()},!0)}};return function(e){var i=this.queue[e],n={};return i.selected=[],i.$display?(i.$displayLabel.html(d.call(this,e)),i.options=v.call(this,e,i.options)):(n.instanceId=this.instanceId,n.id=i.id,n.name=i.name,n.theme=i.theme,n.tabIndex=i.tabIndex,n.multiple=i.multiple,n.reset=i.reset,n.label=d.call(this,e),n.formSize=function(){return i.size?"input-"+i.size:""}(),i.$display=jQuery(t.tmpl.get.call(this,"comboboxDisplay",n,i.columnKeys)),i.$displayTable=i.$display.find('[data-els="display-table"]'),i.$displayLabel=i.$display.find('[data-ax5combobox-display="label"]'),i.$displayLabelInput=i.$display.find('[data-ax5combobox-display="input"]'),i.$target.find("select").get(0)?(i.$select=i.$target.find("select"),i.$select.attr("tabindex","-1").attr("class","form-control "+n.formSize),n.name&&i.$select.attr("name","name"),n.multiple&&i.$select.attr("multiple","multiple")):(i.$select=jQuery(t.tmpl.get.call(this,"formSelect",n,i.columnKeys)),i.$target.append(i.$select)),i.$target.append(i.$display),i.options=v.call(this,e,i.options)),l.call(this),i.$display.unbind("click.ax5combobox").bind("click.ax5combobox",r.click.bind(this,e)),i.$displayLabelInput.unbind("focus.ax5combobox").bind("focus.ax5combobox",r.focus.bind(this,e)).unbind("blur.ax5combobox").bind("blur.ax5combobox",r.blur.bind(this,e)).unbind("keyup.ax5combobox").bind("keyup.ax5combobox",r.keyUp.bind(this,e)).unbind("keydown.ax5combobox").bind("keydown.ax5combobox",r.keyDown.bind(this,e)),i.$select.unbind("change.ax5combobox").bind("change.ax5combobox",r.selectChange.bind(this,e)),n=null,i=null,e=null,this}}(),c={};return a=jQuery.extend(!0,c,e,a),a.target?(a.$target=jQuery(a.target),a.id||(a.id=a.$target.data("data-ax5combobox-id")),a.id||(a.id="ax5combobox-"+ax5.getGuid(),a.$target.data("data-ax5combobox-id",a.id)),a.name=a.$target.attr("data-ax5combobox"),a.options&&(a.options=JSON.parse(JSON.stringify(a.options))),function(t){i.isObject(t)&&!t.error&&(a=jQuery.extend(!0,a,t))}(i.parseJson(a.$target.attr("data-ax5combobox-config"),!0)),o=i.search(this.queue,function(){return this.id==a.id}),o===-1?(this.queue.push(a),r.call(this,this.queue.length-1)):(this.queue[o]=jQuery.extend(!0,{},this.queue[o],a),r.call(this,o)),c=null,o=null,this):(console.log(ax5.info.getError("ax5combobox","401","bind")),this)},this.open=function(){var n=function(e){e.onExpand.call({self:this,item:e},function(e){if(this.waitOptionsCallback){var n={},a=this.queue[this.activecomboboxQueueIndex];!function(t,e){var n={};e.options.forEach(function(e,i){e["@index"]=i,n[e[t.columnKeys.optionValue]]=e}),i.isArray(t.selected)&&t.selected.forEach(function(i){n[i[t.columnKeys.optionValue]]&&(e.options[n[i[t.columnKeys.optionValue]]["@index"]][t.columnKeys.optionSelected]=!0)})}(a,e),a.options=v.call(this,this.activecomboboxQueueIndex,e.options),c.call(this,this.activecomboboxQueueIndex),l.call(this),n.id=a.id,n.theme=a.theme,n.size="ax5combobox-option-group-"+a.size,n.multiple=a.multiple,n.lang=a.lang,n.options=a.options,this.activecomboboxOptionGroup.find('[data-els="content"]').html(jQuery(t.tmpl.get.call(this,"options",n,a.columnKeys)))}}.bind(this))};return function(a,l){this.waitOptionsCallback=null;var d,c,u=i.isNumber(a)?a:b.call(this,a),h=this.queue[u],p={};return h.$display.attr("disabled")?this:(this.openTimer&&clearTimeout(this.openTimer),this.activecomboboxOptionGroup?this.activecomboboxQueueIndex==u?this:l>2?this:(this.close(),this.openTimer=setTimeout(function(){this.open(u,(l||0)+1)}.bind(this),e.animateTime),this):(h.optionFocusIndex=-1,h.selected&&h.selected.length>0&&(h.optionSelectedIndex=h.selected[0]["@findex"]),p.id=h.id,p.theme=h.theme,p.size="ax5combobox-option-group-"+h.size,p.multiple=h.multiple,p.lang=h.lang,h.$display.attr("data-combobox-option-group-opened","true"),h.onExpand&&(p.waitOptions=!0),p.options=i.filter(h.options,function(){return!this.hide}),this.activecomboboxOptionGroup=jQuery(t.tmpl.get.call(this,"optionGroup",p,h.columnKeys)),this.activecomboboxOptionGroup.find('[data-els="content"]').html(jQuery(t.tmpl.get.call(this,"options",p,h.columnKeys))),this.activecomboboxQueueIndex=u,s.call(this,"append"),jQuery(window).bind("resize.ax5combobox-"+this.instanceId,function(){s.call(this)}.bind(this)),h.selected&&h.selected.length>0&&(c=this.activecomboboxOptionGroup.find('[data-option-index="'+h.selected[0]["@index"]+'"]'),c.get(0)&&(d=c.position().top-this.activecomboboxOptionGroup.height()/3,this.activecomboboxOptionGroup.find('[data-els="content"]').stop().animate({scrollTop:d},h.animateTime,"swing",function(){}))),jQuery(window).bind("click.ax5combobox-"+this.instanceId,function(t){t=t||window.event,r.call(this,t),i.stopEvent(t)}.bind(this)),o.call(this,h,{self:this,state:"open",item:h}),h.onExpand&&(this.waitOptionsCallback=!0,n.call(this,h)),p=null,d=null,c=null,this))}}(),this.update=function(t){return this.bind(t),this},this.setValue=function(t,e,n){var a=i.isNumber(t)?t:b.call(this,t);if(a===-1)return void console.log(ax5.info.getError("ax5combobox","402","val"));if(w.call(this,a),i.isArray(e)){var o=i.map(e,function(){return{value:this}});_.call(this,a,o,n||!0,{noStateChange:!0})}else i.isString(e)||i.isNumber(e)?_.call(this,a,{value:e},n||!0,{noStateChange:!0}):c.call(this,a);return p.call(this,a),l.call(this),this},this.setText=function(t,e,n){var a=i.isNumber(t)?t:b.call(this,t);return a===-1?void console.log(ax5.info.getError("ax5combobox","402","val")):(w.call(this,a),_.call(this,a,e,!0,{noStateChange:!0}),p.call(this,a),l.call(this),this)},this.getSelectedOption=function(t){var e=i.isNumber(t)?t:b.call(this,t);return e===-1?void console.log(ax5.info.getError("ax5combobox","402","val")):i.deepCopy(this.queue[e].selected)},this.close=function(t){return this.closeTimer&&clearTimeout(this.closeTimer),this.activecomboboxOptionGroup?(t=this.queue[this.activecomboboxQueueIndex],t.optionFocusIndex=-1,t.$display.removeAttr("data-combobox-option-group-opened").trigger("focus"),t.$displayLabel.attr("contentEditable","false"),this.activecomboboxOptionGroup.addClass("destroy"),jQuery(window).unbind("resize.ax5combobox-"+this.instanceId).unbind("click.ax5combobox-"+this.instanceId).unbind("keyup.ax5combobox-"+this.instanceId),this.closeTimer=setTimeout(function(){this.activecomboboxOptionGroup&&this.activecomboboxOptionGroup.remove(),this.activecomboboxOptionGroup=null,this.activecomboboxQueueIndex=-1,o.call(this,t,{self:this,state:"close"})}.bind(this),e.animateTime),this.waitOptionsCallback=null,this):this},this.blur=function(t){var e=i.isNumber(t)?t:b.call(this,t);return e===-1?void console.log(ax5.info.getError("ax5combobox","402","val")):(p.call(this,e),this)},this.enable=function(t){var e=b.call(this,t);return"undefined"!=typeof e&&(this.queue[e].disabled=!1,this.queue[e].$display[0]&&(this.queue[e].$display.removeAttr("disabled"),this.queue[e].$displayLabelInput.removeAttr("disabled")),this.queue[e].$select[0]&&this.queue[e].$select.removeAttr("disabled"),o.call(this,this.queue[e],{self:this,state:"enable"})),this},this.disable=function(t){var e=b.call(this,t);return"undefined"!=typeof e&&(this.queue[e].disabled=!0,this.queue[e].$display[0]&&(this.queue[e].$display.attr("disabled","disabled"),this.queue[e].$displayLabelInput.attr("disabled","disabled")),this.queue[e].$select[0]&&this.queue[e].$select.attr("disabled","disabled"),o.call(this,this.queue[e],{self:this,state:"disable"})),this},this.align=function(){return l.call(this),this},this.main=function(){arguments&&i.isObject(arguments[0])?this.setConfig(arguments[0]):this.init()}.apply(this,arguments)};return e}()),t=ax5.ui.combobox}(),ax5.ui.combobox_instance=new ax5.ui.combobox,jQuery.fn.ax5combobox=function(){return function(t){if(ax5.util.isString(arguments[0])){var e=arguments[0];switch(e){case"open":return ax5.ui.combobox_instance.open(this);case"close":return ax5.ui.combobox_instance.close(this);case"setValue":return ax5.ui.combobox_instance.setValue(this,arguments[1],arguments[2],arguments[3],arguments[4]||"justSetValue");case"setText":return ax5.ui.combobox_instance.setText(this,arguments[1],arguments[2],arguments[3],arguments[4]||"justSetValue");case"getSelectedOption":return ax5.ui.combobox_instance.getSelectedOption(this);case"enable":return ax5.ui.combobox_instance.enable(this);case"disable":return ax5.ui.combobox_instance.disable(this);case"blur":return ax5.ui.combobox_instance.blur(this);default:return this}}else"undefined"==typeof t&&(t={}),jQuery.each(this,function(){var e={target:this};t=jQuery.extend({},t,e),ax5.ui.combobox_instance.bind(t)});return this}}(),function(){var t=ax5.ui.combobox,e=(ax5.util,function(t){return'\n
\n
\n
\n
\n
\n
\n '}),i=function(t){return'\n
\n
\n
\n \n
\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=function(t){return'\n \n '},a=function(t){return'\n{{#selected}}\n\n{{/selected}}\n"},o=function(t){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 {{'+t.optionText+'}}\n
\n
\n {{/hide}}\n {{/options}}\n
\n {{/optgroup}}\n {{^optgroup}}\n {{^hide}}\n
\n
\n {{#multiple}}\n \n \n \n {{/multiple}}\n {{'+t.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 '},l=function(t){return'{{#selected}}
{{{removeIcon}}}
{{text}}
{{/selected}}'};t.tmpl={comboboxDisplay:i,formSelect:n,formSelectOptions:a,optionGroup:e,options:o,label:l,get:function(e,i,n){return ax5.mustache.render(t.tmpl[e].call(this,n),i)}}}(),function(){var t=ax5.ui.combobox,e=(ax5.util,{1:function(t,e,i){var n=this.config,a=e;$(e).find("span").get(0)&&(a=$(e).find("span").get(0));var o,l,s=(a.textContent||a.innerText).replace(/^[\s\r\n\t]*|[\s\r\n\t]*$/g,""),r=this.queue[t];if(r.selected&&r.selected.length>0&&e.getAttribute("data-ax5combobox-selected-text")==s)return o=e.getAttribute("data-ax5combobox-selected-label"),l=r.selected[o],{index:{gindex:l["@gindex"],index:l["@index"],value:l[n.columnKeys.optionValue]}};if(e.getAttribute("data-ax5combobox-selected-text"))return s;if(""!=s){if(i)return s;var d;return r.optionFocusIndex>-1&&(d=this.activecomboboxOptionGroup.find('[data-option-focus-index="'+r.optionFocusIndex+'"]')),r.optionFocusIndex>-1&&d.get(0)&&d.attr("data-option-value")?{index:{gindex:d.attr("data-option-group-index"),index:d.attr("data-option-index")}}:r.editable?s:void 0}},3:function(t,e,i){var n=(this.config,(e.textContent||e.innerText).replace(/^[\s\r\n\t]*|[\s\r\n\t]*$/g,"")),a=this.queue[t];if(""!=n){if(i)return n;var o;return a.optionFocusIndex>-1&&(o=this.activecomboboxOptionGroup.find('[data-option-focus-index="'+a.optionFocusIndex+'"]')),a.optionFocusIndex>-1&&o.get(0)&&o.attr("data-option-value")?{index:{gindex:o.attr("data-option-group-index"),index:o.attr("data-option-index")}}:a.editable?n:void 0}}});t.util={nodeTypeProcessor:e}}(),function(){var t=ax5.ui,e=ax5.util;t.addClass({className:"layout",version:"1.3.66"},function(){var t=function(){var t,i=this,n={mousedown:ax5.info.supportTouch?"touchstart":"mousedown",mousemove:ax5.info.supportTouch?"touchmove":"mousemove",mouseup:ax5.info.supportTouch?"touchend":"mouseup"},a=function(t){var e="changedTouches"in t.originalEvent?t.originalEvent.changedTouches[0]:t;return{clientX:e.clientX,clientY:e.clientY}};this.instanceId=ax5.getGuid(),this.config={theme:"default",animateTime:250,splitter:{size:4},autoResize:!0},this.queue=[],this.openTimer=null,this.closeTimer=null,this.resizer=null,t=this.config;var o=function(){for(var t=this.queue.length;t--;)"undefined"==typeof this.queue[t].parentQueIdx&&this.queue[t].autoResize&&r.call(this,t,null,"windowResize")},l={width:function(t,e){return e?e.__width+(e.split?t.splitter.size:0):0},height:function(t,e){return e?e.__height+(e.split?t.splitter.size:0):0}},s=function(t,i){return"*"==t?void 0:"%"==e.right(t,1)?i*e.number(t)/100:Number(t)},r=function(){var t={split:{horizontal:function(t,e,i){e.splitter?e.__height=t.splitter.size:i==t.splitPanel.length-1&&0==t.splitPanel.asteriskLength?(e.height="*",e.__height=void 0,t.splitPanel.asteriskLength++):"*"==e.height&&t.splitPanel.asteriskLength++},vertical:function(t,e,i){e.splitter?e.__width=t.splitter.size:i==t.splitPanel.length-1&&0==t.splitPanel.asteriskLength?(e.width="*",e.__width=void 0,t.splitPanel.asteriskLength++):"*"==e.width&&t.splitPanel.asteriskLength++}}},i={top:function(t,e){e.$target.css({height:e.__height||0}),e.split&&e.$splitter.css({height:t.splitter.size,top:e.__height||0})},bottom:function(t,e){e.$target.css({height:e.__height||0}),e.split&&e.$splitter.css({height:t.splitter.size,bottom:e.__height||0})},left:function(t,e){var i={width:e.__width||0,height:t.targetDimension.height};t.dockPanel.top&&(i.height-=t.dockPanel.top.__height,i.top=t.dockPanel.top.__height,t.dockPanel.top.split&&(i.height-=t.splitter.size,i.top+=t.splitter.size)),t.dockPanel.bottom&&(i.height-=t.dockPanel.bottom.__height,t.dockPanel.bottom.split&&(i.height-=t.splitter.size)),e.$target.css(i),e.split&&e.$splitter.css({width:t.splitter.size,height:i.height,top:i.top,left:i.width})},right:function(t,e){var i={width:e.__width||0,height:t.targetDimension.height};t.dockPanel.top&&(i.height-=t.dockPanel.top.__height,i.top=t.dockPanel.top.__height,t.dockPanel.top.split&&(i.height-=t.splitter.size,i.top+=t.splitter.size)),t.dockPanel.bottom&&(i.height-=t.dockPanel.bottom.__height,t.dockPanel.bottom.split&&(i.height-=t.splitter.size)),e.$target.css(i),e.split&&e.$splitter.css({width:t.splitter.size,height:i.height,top:i.top,right:i.width})},center:function(t,e){var i={width:t.targetDimension.width,height:t.targetDimension.height};t.dockPanel.top&&(i.height-=t.dockPanel.top.__height||0,i.top=t.dockPanel.top.__height||0,t.dockPanel.top.split&&(i.height-=t.splitter.size,i.top+=t.splitter.size)),t.dockPanel.bottom&&(i.height-=t.dockPanel.bottom.__height||0,t.dockPanel.bottom.split&&(i.height-=t.splitter.size)),t.dockPanel.left&&(i.width-=t.dockPanel.left.__width||0,i.left=t.dockPanel.left.__width||0,t.dockPanel.left.split&&(i.width-=t.splitter.size,i.left+=t.splitter.size)),t.dockPanel.right&&(i.width-=t.dockPanel.right.__width||0,t.dockPanel.right.split&&(i.width-=t.splitter.size));var n=e.minWidth||0,a=e.minHeight||0;i.widtha.offsetEnd-s&&(e.__da=a.offsetEnd-e.offsetEnd-s),{top:e.$target.position().top+e.__da}}e.__da=i.clientX-e.mousePosition.clientX;var n=o.splitPanel[e.panelIndex-1],a=o.splitPanel[e.panelIndex+1],r=n.minWidth||0,d=a.minWidth||0;return e.offsetStart+e.__daa.offsetEnd-d&&(e.__da=a.offsetEnd-e.offsetEnd-d),{left:Number(e.$target.position().left)+Number(e.__da)}}};e.__da=0,jQuery(document.body).bind(n.mousemove+".ax5layout-"+this.instanceId,function(t){i.resizer||(i.resizer=jQuery('
'),i.resizer.css({left:s.left,top:s.top,width:r.width,height:r.height}),o.$target.append(i.resizer)),i.resizer.css(c[e.resizerType](t))}).bind(n.mouseup+".ax5layout-"+this.instanceId,function(n){d.off.call(i,t,e,a)}).bind("mouseleave.ax5layout-"+this.instanceId,function(n){d.off.call(i,t,e,a)}),jQuery(document.body).attr("unselectable","on").css("user-select","none").on("selectstart",!1)},off:function(t,e,a){var o=this.queue[t],l={"dock-panel":{left:function(t,e){e.__width+=e.__da},right:function(){e.__width-=e.__da},top:function(){e.__height+=e.__da},bottom:function(){e.__height-=e.__da}},"split-panel":{split:function(){"horizontal"==o.orientation?(o.splitPanel[e.panelIndex-1].__height+=e.__da,o.splitPanel[e.panelIndex+1].__height-=e.__da):(o.splitPanel[e.panelIndex-1].__width+=e.__da,o.splitPanel[e.panelIndex+1].__width-=e.__da)}},"tab-panel":{}};i.resizer&&(i.resizer.remove(),i.resizer=null,l[this.queue[t].layout][e.resizerType].call(this,t,e),r.call(this,t)),jQuery(document.body).unbind(n.mousemove+".ax5layout-"+this.instanceId).unbind(n.mouseup+".ax5layout-"+this.instanceId).unbind("mouseleave.ax5layout-"+this.instanceId),jQuery(document.body).removeAttr("unselectable").css("user-select","auto").off("selectstart")}},c={open:function(t,e,i){if(e.activePanelIndex!=i&&(e.tabPanel[i].active=!0,e.tabPanel[e.activePanelIndex].active=!1,e.$target.find('[data-tab-panel-label="'+i+'"]').attr("data-tab-active","true"),e.$target.find('[data-tab-panel-label="'+e.activePanelIndex+'"]').removeAttr("data-tab-active"),e.tabPanel[i].$target.attr("data-tab-active","true"),e.tabPanel[e.activePanelIndex].$target.removeAttr("data-tab-active"),e.activePanelIndex=i,e.onOpenTab)){var n={$target:e.$target,name:e.name,id:e.id,layout:e.layout,activePanelIndex:e.activePanelIndex,activePanel:e.tabPanel[e.activePanelIndex],tabPanel:e.tabPanel};e.onOpenTab.call(n)}}},u=function(){return'\n
\n
\n
\n
\n {{#tabPanel}}\n
\n
{{{label}}}
\n
\n {{/tabPanel}}\n
\n
\n
\n'},h=function(){var t={"dock-panel":function(t){var o=this.queue[t];o.dockPanel={},o.$target.find(">[data-dock-panel]").each(function(){var l={};!function(t){e.isObject(t)&&!t.error&&(l=jQuery.extend(!0,l,t))}(e.parseJson(this.getAttribute("data-dock-panel"),!0)),"dock"in l&&(l.$target=jQuery(this),l.$target.addClass("dock-panel-"+l.dock),(l.split=l.split&&"true"==l.split.toString())&&(l.$splitter=jQuery('
'),l.$splitter.bind(n.mousedown,function(e){l.mousePosition=a(e),d.on.call(i,t,l,l.$splitter)}).bind("dragstart",function(t){return e.stopEvent(t),!1}),o.$target.append(l.$splitter)),"top"==l.dock||"bottom"==l.dock?l.__height=s(l.height,o.targetDimension.height):l.__width=s(l.width,o.targetDimension.width),l.resizerType=l.dock,o.dockPanel[l.dock]=l)})},"split-panel":function(t){var o=this.queue[t];o.splitPanel=[],o.$target.find(">[data-split-panel], >[data-splitter]").each(function(l){var r={};!function(t){e.isObject(t)&&!t.error&&(r=jQuery.extend(!0,r,t))}(e.parseJson(this.getAttribute("data-split-panel")||this.getAttribute("data-splitter"),!0)),r.$target=jQuery(this),r.$target.addClass("split-panel-"+o.orientation),r.panelIndex=l,this.getAttribute("data-splitter")?(r.splitter=!0,r.$target.bind(n.mousedown,function(e){r.panelIndex>0&&r.panelIndex[data-tab-panel]").each(function(t){var i={};!function(t){e.isObject(t)&&!t.error&&(i=jQuery.extend(!0,i,t))}(e.parseJson(this.getAttribute("data-tab-panel"),!0)),a&&(i.active=!1),i.$target=jQuery(this),i.active&&"false"!=i.active&&(a=!0,n.activePanelIndex=t,i.$target.attr("data-tab-active","true")),i.panelIndex=t,n.tabPanel.push(i)}),a||(n.tabPanel[0].active=!0,n.tabPanel[0].$target.attr("data-tab-active","true"),n.activePanelIndex=0),n.$target.append(jQuery(ax5.mustache.render(u.call(this,t),n))),n.$target.on("click","[data-tab-panel-label]",function(e){var a=this.getAttribute("data-tab-panel-label");c.open.call(i,t,n,a)})}};return function(e){var i=this.queue[e];i.targetDimension={height:i.$target.innerHeight(),width:i.$target.innerWidth()},i.$target.parents("[data-ax5layout]").get(0)&&f.call(this,i.$target.parents("[data-ax5layout]").get(0),e),i.layout in t&&t[i.layout].call(this,e),r.call(this,e)}}(),p=function(t){return e.isString(t)||(t=jQuery(t).data("data-ax5layout-id")),e.isString(t)?e.search(this.queue,function(){return this.id==t}):-1},f=function(t,i){var n=e.isNumber(t)?t:p.call(this,t);this.queue[n].childQueIdxs||(this.queue[n].childQueIdxs=[]),this.queue[n].childQueIdxs.push(i),this.queue[i].parentQueIdx=n};this.init=function(){this.onStateChanged=t.onStateChanged,this.onClick=t.onClick,jQuery(window).bind("resize.ax5layout-"+this.instanceId,function(){o.call(this)}.bind(this))},this.bind=function(i){var n,a={};return i=jQuery.extend(!0,a,t,i),i.target?(i.$target=jQuery(i.target),i.id||(i.id=i.$target.data("data-ax5layout-id")),i.id||(i.id="ax5layout-"+ax5.getGuid(),i.$target.data("data-ax5layout-id",i.id)),i.name=i.$target.attr("data-ax5layout"),i.options&&(i.options=JSON.parse(JSON.stringify(i.options))),function(t){e.isObject(t)&&!t.error&&(i=jQuery.extend(!0,i,t))}(e.parseJson(i.$target.attr("data-config"),!0)),n=e.search(this.queue,function(){return this.id==i.id}),n===-1?(this.queue.push(i),h.call(this,this.queue.length-1)):(this.queue[n]=jQuery.extend(!0,{},this.queue[n],i),h.call(this,n)),a=null,n=null,this):(console.log(ax5.info.getError("ax5layout","401","bind")),this)},this.align=function(t,i){var n=e.isNumber(t)?t:p.call(this,t);if(n===-1)for(var a=this.queue.length;a--;)r.call(this,a,null,i);else r.call(this,n,null,i);return this},this.onResize=function(t,i){var n=e.isNumber(t)?t:p.call(this,t);return n===-1?void console.log(ax5.info.getError("ax5layout","402","onResize")):(this.queue[n].onResize=i,this)},this.resize=function(){var t={"dock-panel":function(t,i){["top","bottom","left","right"].forEach(function(n){i[n]&&t.dockPanel[n]&&("top"==n||"bottom"==n?t.dockPanel[n].__height=e.isObject(i[n])?i[n].height:i[n]:"left"!=n&&"right"!=n||(t.dockPanel[n].__width=e.isObject(i[n])?i[n].width:i[n]))})},"split-panel":function(){},"tab-panel":function(){}};return function(i,n,a){var o=e.isNumber(i)?i:p.call(this,i);if(o===-1)for(var l=this.queue.length;l--;)t[this.queue[l].layout].call(this,this.queue[l],n),r.call(this,l,a);else this.queue[o]&&(t[this.queue[o].layout].call(this,this.queue[o],n),r.call(this,o,a));return this}}(),this.reset=function(){var t={"dock-panel":function(t){["top","bottom","left","right"].forEach(function(e){t.dockPanel[e]&&("top"==e||"bottom"==e?t.dockPanel[e].__height=t.dockPanel[e].height:"left"!=e&&"right"!=e||(t.dockPanel[e].__width=t.dockPanel[e].width))})},"split-panel":function(t){t.splitPanel.forEach(function(e){"vertical"==t.orientation?e.__width=s(e.width,t.targetDimension.width):"horizontal"==t.orientation&&(e.__height=s(e.height,t.targetDimension.height))})},"tab-panel":function(){}};return function(i,n){var a=e.isNumber(i)?i:p.call(this,i);return a===-1||(t[this.queue[a].layout].call(this,this.queue[a]),r.call(this,a,n)),this}}(),this.hide=function(){},this.tabOpen=function(){return function(t,i){var n=e.isNumber(t)?t:p.call(this,t);return n===-1?void console.log(ax5.info.getError("ax5layout","402","tabOpen")):(c.open.call(this,n,this.queue[n],i),this)}}(),this.main=function(){arguments&&e.isObject(arguments[0])?this.setConfig(arguments[0]):this.init()}.apply(this,arguments)};return t}())}(),ax5.ui.layout_instance=new ax5.ui.layout,jQuery.fn.ax5layout=function(){return function(t){if(ax5.util.isString(arguments[0])){var e=arguments[0];switch(e){case"align":return ax5.ui.layout_instance.align(this,arguments[1]);case"resize":return ax5.ui.layout_instance.resize(this,arguments[1],arguments[2]);case"reset":return ax5.ui.layout_instance.reset(this,arguments[1]);case"hide":return ax5.ui.layout_instance.hide(this,arguments[1]);case"onResize":return ax5.ui.layout_instance.onResize(this,arguments[1]);case"tabOpen":return ax5.ui.layout_instance.tabOpen(this,arguments[1]);default:return this}}else"undefined"==typeof t&&(t={}),jQuery.each(this,function(){var e={target:this};t=jQuery.extend({},t,e),ax5.ui.layout_instance.bind(t)});return this}}(),function(){var t=ax5.ui,e=ax5.util;t.addClass({className:"binder",version:"1.3.66"},function(){var t=function(){var t;this.instanceId=ax5.getGuid(),this.config={},t=this.config,this.model={},this.tmpl={},this.view_target=null,this.change_trigger={},this.click_trigger={},this.update_trigger={},this.onerror=null;var i=Object.prototype.toString,n=function(t){var e;return null!=t&&t==t.window?e="window":t&&1==t.nodeType?e="element":t&&11==t.nodeType?e="fragment":"undefined"==typeof t?e="undefined":"[object Object]"==i.call(t)?e="object":"[object Array]"==i.call(t)?e="array":"[object String]"==i.call(t)?e="string":"[object Number]"==i.call(t)?e="number":"[object NodeList]"==i.call(t)?e="nodelist":"function"==typeof t&&(e="function"),e},a=function(t,e,i){return t+"["+e+"]"+("."==i?"":"."+i)},o=function(t){var e=[],i=[].concat(t.split(/[\.\[\]]/g));return i.forEach(function(t){""!==t&&e.push('["'+t.replace(/['\"]/g,"")+'"]')}),i=null,e.join("")};this.setModel=function(t,e){return this.model=t,!this.view_target&&e?(this.view_target=e,this._binding()):this._binding("update"),this},this.set=function(t,e){var i,a,l,s=this;if(Function("val","this"+o(t)+" = val;").call(this.model,e),i=n(e),"object"==i)for(var r in e)this.set(t+"."+r,e[r]);else if("array"==i)for(this.view_target.find('[data-ax-path="'+t+'"]').each(function(){l=(this.type||"").toLowerCase(),"checkbox"!=l&&"radio"!=l||s.set_els_value(this,this.tagName.toLowerCase(),l,e,t,"change")}),a=e.length;a--;)this.set(t+"["+a+"]",e[a]);else this.view_target.find('[data-ax-path="'+t+'"]').each(function(){s.set_els_value(this,this.tagName.toLowerCase(),(this.type||"").toLowerCase(),e,t,"change")});return this},this.get=function(t){return"undefined"==typeof t?this.model:Function("","return this"+o(t)+";").call(this.model)},this.onChange=function(t,e){return this.change_trigger[t||"*"]=e,this},this.onClick=function(t,e){return this.click_trigger[t]=e,this},this.add=function(t,e){var i=Function("","return this"+o(t)+";").call(this.model),n=this.tmpl[t];e["@i"]=i.length,e["@r"]=i.length,e.__ADDED__=!0,Function("val","this"+o(t)+".push(val);").call(this.model,e);for(var a in n){var l=$(ax5.mustache.render(n[a].content,e));l.attr("data-ax-repeat-path",t),l.attr("data-ax-repeat-i",e["@i"]),this.bind_event_tmpl(l,t),n[a].container.append(l)}this.change("*");var s=this.update_trigger[t];if(s){var r={repeat_path:t,tmpl:n,list:i};s.call(r,r)}return this},this.remove=function(t,e){var i=Function("","return this"+o(t)+";").call(this.model),n=this.tmpl[t];"undefined"==typeof e&&(e=i.length-1);var a=i[e];a.__ADDED__?i.splice(e,1):i[e].__DELETED__=!0;for(var l in n)n[l].container.empty(),this.print_tmpl(t,n[l]);this.change("*");var s=this.update_trigger[t];if(s){var r={repeat_path:t,tmpl:n,list:i};s.call(r,r)}return this},this.update=function(t,e,i){var n=Function("","return this"+o(t)+";").call(this.model),a=this.tmpl[t];"undefined"!=typeof e&&i&&n.splice(e,1,i);for(var l in a)a[l].container.empty(),this.print_tmpl(t,a[l]);this.change("*");var s=this.update_trigger[t];if(s){var r={repeat_path:t,tmpl:a,list:n};s.call(r,r)}return this},this.childAdd=function(t,e,i,n){var a=Function("","return this"+o(t)+";").call(this.model),l=Function("","return this"+o(t)+"["+e+"]."+i+";").call(this.model);n.__ADDED__=!0,l.push(n),this.update(t,e,a[e])},this.childRemove=function(t,e,i,n){var a=Function("","return this"+o(t)+";").call(this.model),l=Function("","return this"+o(t)+"["+e+"]."+i+";").call(this.model),s=l[n];s.__ADDED__?l.splice(n,1):l[n].__DELETED__=!0,this.update(t,e,a[e])},this.childUpdate=function(t,e,i,n,a){var l=Function("","return this"+o(t)+";").call(this.model),s=Function("","return this"+o(t)+"["+e+"]."+i+";").call(this.model);s[n]=a,this.update(t,e,l[e])},this.childSet=function(t,e,i,n){var a=this;return Function("val","this"+o(t)+"["+e+"]."+i+" = val;").call(this.model,n),this.view_target.find('[data-ax-repeat="'+t+'"]').find('[data-ax-repeat-i="'+e+'"]').find('[data-ax-item-path="'+i+'"]').each(function(){a.set_els_value(this,this.tagName.toLowerCase(),(this.type||"").toLowerCase(),n,t+"["+e+"]."+i)}),this},this.onUpdate=function(t,e){return this.update_trigger[t]=e,this},this._binding=function(t){var e=this;this.view_target.find("[data-ax-path]").each(function(){var t,i=$(this),n=i.attr("data-ax-path"),a=(this.type||"").toLowerCase();try{t=Function("","return this"+o(n)+";").call(e.model)}catch(l){e.onerror&&e.onerror("not found target [model."+o(n)+"]")}e.set_els_value(this,this.tagName.toLowerCase(),a,t||"",n)}),"undefined"==typeof t?this.view_target.find("[data-ax-repeat]").each(function(){var t=$(this),i=t.attr("data-ax-repeat"),n=t.attr("data-ax-repeat-idx");"undefined"==typeof e.tmpl[i]&&(e.tmpl[i]={}),"undefined"!=typeof n?e.tmpl[i][n]={container:t,content:t.find("script").html()}:e.tmpl[i][0]={container:t,content:t.find("script").html()},t.empty()}):this.view_target.find("[data-ax-repeat]").each(function(){var t=$(this);t.empty().show()}),this.view_target.find("[data-ax-path]").unbind("change.axbinder").bind("change.axbinder",function(t){var i,a,l=!1,s=[],r=$(t.target),d=r.attr("data-ax-path"),c=Function("","return this"+o(d)+";").call(e.model),u=(this.type||"").toLowerCase(),h=n(c),p=!0;if("object"!=h&&"array"!=h||(p=!1),"checkbox"==u){if(e.view_target.find('[data-ax-path="'+d+'"]').length>1){for("array"!=n(c)&&(c="undefined"==typeof c||""==c?[]:[].concat(c)),i=c.length,l=!1,a=this.checked;i--;)c[i]==this.value&&(l=!0);if(a)l||c.push(this.value);else{for(i=c.length;i--;)c[i]==this.value||s.push(c[i]);c=s}}else c=this.checked?this.value:"";Function("val","this"+o(d)+" = val;").call(e.model,c),e.change(d,{el:this,jquery:r,tagname:this.tagName.toLowerCase(),value:c})}else p&&(Function("val","this"+o(d)+" = val;").call(e.model,this.value),e.change(d,{el:this,jquery:r,tagname:this.tagName.toLowerCase(),value:this.value}));r.data("changedTime",(new Date).getTime())});var i;for(var a in e.tmpl){for(var l in e.tmpl[a])this.print_tmpl(a,e.tmpl[a][l],"isInit");if(i=this.update_trigger[a]){var s={repeat_path:a,tmpl:e.tmpl[a],list:Function("","return this."+a+";").call(this.model)};i.call(s,s)}}},this.set_els_value=function(t,e,i,n,a,l){n="undefined"==typeof n?[]:[].concat(n);var s,r;if("input"==e)if("checkbox"==i||"radio"==i){r=n.length;var d=!1;try{if(r>0)for(;r--;)"undefined"!=typeof n[r]&&t.value===n[r].toString()&&(d=!0)}catch(c){console.log(c)}t.checked=d}else t.value=n.join("");else if("select"==e){s=t.options,r=s.length;for(var u,h=!1;r--;){for(u=n.length;u--;)if("undefined"!=typeof n[u]&&s[r].value===n[u].toString()){s[r].selected=!0,h=!0;break}if(h)break}h||(s[0]?(s[0].selected=!0,Function("val","this"+o(a)+" = val;").call(this.model,s[0].value)):Function("val","this"+o(a)+" = val;").call(this.model,"")),window.AXSelect&&$("undefined"!=typeof n&&t).bindSelectSetValue(n[n.length-1])}else"textarea"==e?t.value=n.join("")||"":t.innerText?t.innerText=n.join(""):t.innerHTML=n.join("");return l&&this.change(a,{el:t,tagname:e,value:n}),this},this.change=function(t,e){var i=this.change_trigger[t];i&&i.call(e,e),"*"!=t&&this.change_trigger["*"]&&this.change_trigger["*"].call(e,e)},this.click=function(t,e){var i=this.click_trigger[t];i&&i.call(e,e)},this.sync_model=function(){},this.print_tmpl=function(t,e,i){var a=Function("","return this"+o(t)+";").call(this.model);if(a&&"array"==n(a))for(var l=0,s=a.length;l1){for("array"!=n(m)&&(m="undefined"==typeof m||""==m?[]:[].concat(m)),s=m.length,d=!1,r=this.checked;s--;)m[s]==this.value&&(d=!0);if(r)d||m.push(this.value);else{for(s=m.length;s--;)m[s]==this.value||c.push(m[s]);m=c}}else m=this.checked?this.value:"";Function("val","this."+f+" = val;").call(i.model,m),i.change(f,{el:this,jquery:h, +tagname:this.tagName.toLowerCase(),value:m})}else x&&(Function("val","this."+f+" = val;").call(i.model,this.value),i.change(f,{el:this,jquery:h,tagname:this.tagName.toLowerCase(),value:this.value}));h.data("changedTime",(new Date).getTime())}),t.find("[data-ax-item-path]").unbind("blur.axbinder").bind("blur.axbinder",function(t){var e=$(t.target);("undefined"==typeof e.data("changedTime")||e.data("changedTime")<(new Date).getTime()-10)&&e.trigger("change")})},this.focus=function(t){return this.view_target.find('[data-ax-path="'+t+'"]').focus(),this},this.validate=function(){var t=this,e=[];return this.view_target.find("[data-ax-path]").each(function(){var i=$(this),n=i.attr("data-ax-path"),a=i.attr("data-ax-validate"),l=i.attr("pattern");if(a){var s,r,d;s=Function("","return this"+o(n)+";").call(t.model),"undefined"==typeof s&&(s=""),r=s.toString(),d=!1,"required"==a&&""==r.trim()?d=!0:"pattern"==a?d=!new RegExp(l).test(r):"email"==a?d=!/[a-z0-9._%+-]+@[a-z0-9.-]+\.[a-z]{2,4}$/.test(r):!/\D.?/g.test(a)&&r.trim().length0?{error:e}:{}},this.main=function(){arguments&&e.isObject(arguments[0])&&this.setConfig(arguments[0])}.apply(this,arguments)};return t}())}(),function(){var t,e=ax5.ui,i=ax5.util;e.addClass({className:"autocomplete",version:"1.3.66"},function(){var e=function(){var e,n=this;this.instanceId=ax5.getGuid(),this.config={theme:"default",animateTime:250,removeIcon:"X",lang:{noSelected:"",noOptions:"no options",loading:"Now Processing"},columnKeys:{optionValue:"value",optionText:"text",optionSelected:"selected"}},this.queue=[],this.activeautocompleteOptionGroup=null,this.activeautocompleteQueueIndex=-1,this.openTimer=null,this.closeTimer=null,this.waitOptionsCallback=null,this.keyUpTimer=null,e=this.config;var a=jQuery(window),o={18:"KEY_ALT",17:"KEY_CONTROL",46:"KEY_DELETE",40:"KEY_DOWN",35:"KEY_END",187:"KEY_EQUAL",36:"KEY_HOME",45:"KEY_INSERT",37:"KEY_LEFT",189:"KEY_MINUS",34:"KEY_PAGEDOWN",33:"KEY_PAGEUP",39:"KEY_RIGHT",16:"KEY_SHIFT",9:"KEY_TAB",38:"KEY_UP",91:"KEY_WINDOW"},l=function(t,e){return t&&t.onStateChanged?t.onStateChanged.call(e,e):this.onStateChanged&&this.onStateChanged.call(e,e),"changeValue"==e.state&&(t&&t.onChange?t.onChange.call(e,e):this.onChange&&this.onChange.call(e,e)),t=null,e=null,!0},s=function(){for(var t,e=this.queue.length;e--;){var n=this.queue[e];if(n.$display&&(t=Math.max(n.$select.outerWidth(),i.number(n.minWidth)),n.$display.css({"min-width":t}),n.reset&&n.$display.find(".addon-icon-reset").css({"line-height":this.queue[e].$display.height()+"px"}),n.multiple)){var a=function(){return i.number(n.$display.css("border-top-width"))+i.number(n.$display.css("border-bottom-width"))}.call(this);n.$target.height(""),n.$display.height("");var o=n.$displayTable.outerHeight();Math.abs(o-n.$target.height())>a&&(n.$target.css({height:o+a+4}),n.$display.css({height:o+a+4}))}}return e=null,t=null,this},r=function(t){if(t&&!this.activeautocompleteOptionGroup)return this;var e,i=this.queue[this.activeautocompleteQueueIndex],n={},o=0,l={},s={};return i?(t&&jQuery(document.body).append(this.activeautocompleteOptionGroup),n=i.$target.offset(),l={width:i.$target.outerWidth(),height:i.$target.outerHeight()},s={winWidth:Math.max(a.width(),jQuery(document.body).width()),winHeight:Math.max(a.height(),jQuery(document.body).height()),width:this.activeautocompleteOptionGroup.outerWidth(),height:this.activeautocompleteOptionGroup.outerHeight()},i.direction&&""!==i.direction&&"auto"!==i.direction?e=i.direction:(e="top",n.top-s.height-o<0?e="top":n.top+l.height+s.height+o>s.winHeight&&(e="bottom")),t&&this.activeautocompleteOptionGroup.addClass("direction-"+e),void this.activeautocompleteOptionGroup.css(function(){if("top"==e){if(n.top+l.height+s.height+o>s.winHeight){var t=n.top+s.height;return t+s.height+o>s.winHeight&&(t=0),t<0&&(t=0),{left:n.left,top:t,width:l.width}}return{left:n.left,top:n.top+l.height+1,width:l.width}}if("bottom"==e)return{left:n.left,top:n.top-s.height-1,width:l.width}}.call(this))):this},d=function(t,e){if(!this.activeautocompleteOptionGroup)return this;var n=this.queue[this.activeautocompleteQueueIndex],a="display";return(e=i.findParentNode(t.target,function(t){return t.getAttribute("data-option-value")?(a="optionItem",!0):n.$target.get(0)==t?(a="display",!0):void 0}))?("optionItem"===a&&(I.call(this,n.id,{optionIndex:{index:e.getAttribute("data-option-index")}},void 0,"optionItemClick"),s.call(this),r.call(this),n.multiple||this.close()),this):(this.close(),this)},c=function(e){var i=this.queue[e],n={};return n.id=i.id,n.theme=i.theme,n.size="ax5autocomplete-option-group-"+i.size,n.multiple=i.multiple,n.lang=i.lang,n.options=i.options,n.selected=i.selected,n.hasSelected=n.selected&&n.selected.length>0,n.removeIcon=i.removeIcon,t.tmpl.get.call(this,"label",n,i.columnKeys)},u=function(e){var i=this.queue[e];!i.multiple&&i.selected&&i.selected.length>0&&(i.selected=[].concat(i.selected[i.selected.length-1])),i.selected.forEach(function(t,e){t["@index"]=e}),i.$select.html(t.tmpl.get.call(this,"formSelectOptions",{selected:i.selected},i.columnKeys))},h=function(t){var e=this.queue[t];e.$displayLabel.find("[data-ax5autocomplete-selected-label]").remove(),e.$displayLabelInput.before(c.call(this,t))},p=function(t){return this.queue[t].disabled?this:(this.queue[t].$displayLabel.trigger("focus"),void this.queue[t].$displayLabelInput.focus())},f=function(t){this.queue[t].$displayLabelInput.val("")},m=function(t){this.queue[t].$displayLabel.trigger("blur")},g=function(e,n){if(this.activeautocompleteQueueIndex==-1)return this;var a=/[\{\}\[\]\/?.,;:|\)*~`!^\-_+<>@\#$%&\\\=\(\'\"]/gi;n=n.replace(a,""),this.queue[e].waitOptions=!0,this.queue[e].onSearch.call({self:this,item:this.queue[e],searchWord:n},function(e){var a={},o=this.queue[this.activeautocompleteQueueIndex];return!!o&&(function(t,e){var n={};e.options.forEach(function(e,i){e["@index"]=i,e["@findex"]=i,n[e[t.columnKeys.optionValue]]=e}),i.isArray(t.selected)&&t.selected.forEach(function(i){n[i[t.columnKeys.optionValue]]&&(e.options[n[i[t.columnKeys.optionValue]]["@index"]][t.columnKeys.optionSelected]=!0)})}(o,e),o.options=e.options,s.call(this),a.id=o.id,a.theme=o.theme,a.size="ax5autocomplete-option-group-"+o.size,a.multiple=o.multiple,a.lang=o.lang,a.options=o.options,this.activeautocompleteOptionGroup.find('[data-els="content"]').html(jQuery(t.tmpl.get.call(this,"options",a,o.columnKeys))),x.call(this,this.activeautocompleteQueueIndex,n),r.call(this),void setTimeout(function(){r.call(this)}.bind(this)))}.bind(this))},x=function(t,e){if(this.activeautocompleteQueueIndex==-1)return this;var i,n=[],a=-1,o=this.queue[t].options.length-1;if(""!=e){for(;o-a++;){if(i=this.queue[t].options[a],(""+i.text).toLowerCase()==e.toLowerCase()){n=[{"@findex":i["@findex"],optionsSort:0}];break}var l=(""+i.text).toLowerCase().search(e.toLowerCase());if(l>-1&&(n.push({"@findex":i["@findex"],optionsSort:l}),n.length>2))break;l=null}n.sort(function(t,e){return t.optionsSort-e.optionsSort})}n&&n.length>0?b.call(this,t,void 0,n[0]["@findex"]):v.call(this,t)},v=function(t){this.activeautocompleteOptionGroup&&this.activeautocompleteOptionGroup.find("[data-option-focus-index]").removeClass("hover").removeAttr("data-option-selected"),this.queue[t].optionFocusIndex=-1},b=function(t,e,i){var n,a,o,l,s=this.queue[t];if(this.activeautocompleteOptionGroup&&s.options&&s.options.length>0){if("undefined"!=typeof i?n=i:(a=s.optionFocusIndex==-1?s.optionSelectedIndex||-1:s.optionFocusIndex,a==-1?n=0:(n=a+e,n<0?n=0:n>s.optionItemLength-1&&(n=s.optionItemLength-1))),s.optionFocusIndex=n,s.options[n]&&s.options[n].hide){if("undefined"==typeof e)return this;for(;s.options[n].hide;){if(n+=e,n<0){n=0;break}if(n>s.optionItemLength-1){n=s.optionItemLength-1;break}}}if("undefined"!=typeof n&&(this.activeautocompleteOptionGroup.find("[data-option-focus-index]").removeClass("hover"),o=this.activeautocompleteOptionGroup.find('[data-option-focus-index="'+n+'"]').addClass("hover"),l=this.activeautocompleteOptionGroup.find('[data-els="content"]'),o.get(0))){var r=o.outerHeight(),d=l.innerHeight(),c=l.scrollTop(),u=o.position().top+l.scrollTop();d+cu&&l.scrollTop(u),"undefined"!=typeof e&&s.$displayLabelInput.val(s.options[n].text)}}},y=function(t){return t instanceof jQuery?t=t.data("data-ax5autocomplete-id"):i.isString(t)||(t=jQuery(t).data("data-ax5autocomplete-id")),i.isString(t)?i.search(this.queue,function(){return this.id==t}):void console.log(ax5.info.getError("ax5autocomplete","402","getQueIdx"))},w=function(t,e,i){return"undefined"==typeof i?!t.multiple||!e:i},_=function(e){this.queue[e].options.forEach(function(t){t.optgroup?t.options.forEach(function(t){t.selected=!1}):t.selected=!1}),this.queue[e].selected=[],this.queue[e].$select.html(t.tmpl.get.call(this,"formSelectOptions",{selected:this.queue[e].selected},this.queue[e].columnKeys))},I=function(){var t={selectedIndex:function(t,e,i,n){},removeSelectedIndex:function(t,e,i,n){for(var a=this.queue[t],o={},l=[],s=0,r=0;r-1)if(s.options[r][s.columnKeys.optionSelected]=w(s,s.options[r][s.columnKeys.optionSelected],a),s.options[r][s.columnKeys.optionSelected]){for(var d=!0,c=0;c-1)if(s.options[r][s.columnKeys.optionSelected]=w(s,s.options[r][s.columnKeys.optionSelected],a),s.options[r][s.columnKeys.optionSelected]){for(var d=!0,c=0;c-1?I.call(this,a.id,{optionIndex:{index:a.optionFocusIndex}},void 0,"optionItemClick"):""!=n&&I.call(this,t,n,!0),f.call(this,t),s.call(this),this.close(),i.stopEvent(e)}else e.which==ax5.info.eventKeys.DOWN?(b.call(this,t,1),i.stopEvent(e)):e.which==ax5.info.eventKeys.UP&&(b.call(this,t,-1),i.stopEvent(e))},focus:function(t,e){},blur:function(t,e){l.call(this,t),i.stopEvent(e)},selectChange:function(t,e){I.call(this,t,{value:this.queue[t].$select.val()},!0)}};return function(e){var i=this.queue[e],n={};return i.$display?h.call(this,e):(n.instanceId=this.instanceId,n.id=i.id,n.name=i.name,n.theme=i.theme,n.tabIndex=i.tabIndex,n.multiple=i.multiple,n.reset=i.reset,n.label=c.call(this,e),n.formSize=function(){return i.size?"input-"+i.size:""}(),i.$display=jQuery(t.tmpl.get.call(this,"autocompleteDisplay",n,i.columnKeys)),i.$displayTable=i.$display.find('[data-els="display-table"]'),i.$displayLabel=i.$display.find('[data-ax5autocomplete-display="label"]'),i.$displayLabelInput=i.$display.find('[data-ax5autocomplete-display="input"]'),i.$target.find("select").get(0)?(i.$select=i.$target.find("select"),i.$select.attr("tabindex","-1").attr("class","form-control "+n.formSize),n.name&&i.$select.attr("name","name"),i.$select.attr("multiple","multiple")):(i.$select=jQuery(t.tmpl.get.call(this,"formSelect",n,i.columnKeys)),i.$target.append(i.$select)),i.$target.append(i.$display)),s.call(this),i.$display.unbind("click.ax5autocomplete").bind("click.ax5autocomplete",d.click.bind(this,e)),i.$displayLabelInput.off("focus.ax5autocomplete").on("focus.ax5autocomplete",d.focus.bind(this,e)).off("blur.ax5autocomplete").on("blur.ax5autocomplete",d.blur.bind(this,e)).off("keydown.ax5autocomplete").on("keydown.ax5autocomplete",d.keyUp.bind(this,e)).off("keyup.ax5autocomplete").on("keyup.ax5autocomplete",d.keyDown.bind(this,e)),i.$select.unbind("change.ax5autocomplete").bind("change.ax5autocomplete",d.selectChange.bind(this,e)),n=null,i=null,e=null,this}}(),m={};return a=jQuery.extend(!0,m,e,a),a.target?(a.$target=jQuery(a.target),a.id||(a.id=a.$target.data("data-ax5autocomplete-id")),a.id||(a.id="ax5autocomplete-"+ax5.getGuid(),a.$target.data("data-ax5autocomplete-id",a.id)),a.name=a.$target.attr("data-ax5autocomplete"),a.options=[],a.selected=[],function(t){i.isObject(t)&&!t.error&&(a=jQuery.extend(!0,a,t))}(i.parseJson(a.$target.attr("data-ax5autocomplete-config"),!0)),l=i.search(this.queue,function(){return this.id==a.id}),l===-1?(this.queue.push(a),d.call(this,this.queue.length-1)):(this.queue[l]=jQuery.extend(!0,{},this.queue[l],a),d.call(this,l)),m=null,l=null,this):(console.log(ax5.info.getError("ax5autocomplete","401","bind")),this)},this.open=function(){return function(n,a){this.waitOptionsCallback=null;var o,s,c=i.isNumber(n)?n:y.call(this,n),u=this.queue[c],h={};return u.$display.attr("disabled")?this:(this.openTimer&&clearTimeout(this.openTimer),this.activeautocompleteOptionGroup?this.activeautocompleteQueueIndex==c?this:a>2?this:(this.close(),this.openTimer=setTimeout(function(){this.open(c,(a||0)+1)}.bind(this),e.animateTime),this):(u.optionFocusIndex=-1,u.selected&&u.selected.length>0&&(u.optionSelectedIndex=u.selected[0]["@findex"]),h.id=u.id,h.theme=u.theme,h.size="ax5autocomplete-option-group-"+u.size,h.multiple=u.multiple,h.lang=u.lang,u.$display.attr("data-autocomplete-option-group-opened","true"),h.waitOptions=!0,h.options=[],this.activeautocompleteOptionGroup=jQuery(t.tmpl.get.call(this,"optionGroup",h,u.columnKeys)),this.activeautocompleteOptionGroup.find('[data-els="content"]').html(jQuery(t.tmpl.get.call(this,"options",h,u.columnKeys))),this.activeautocompleteQueueIndex=c,r.call(this,"append"),jQuery(window).bind("resize.ax5autocomplete-"+this.instanceId,function(){r.call(this)}.bind(this)),u.selected&&u.selected.length>0&&(s=this.activeautocompleteOptionGroup.find('[data-option-index="'+u.selected[0]["@index"]+'"]'),s.get(0)&&(o=s.position().top-this.activeautocompleteOptionGroup.height()/3,this.activeautocompleteOptionGroup.find('[data-els="content"]').stop().animate({scrollTop:o},u.animateTime,"swing",function(){}))),jQuery(window).bind("click.ax5autocomplete-"+this.instanceId,function(t){t=t||window.event,d.call(this,t),i.stopEvent(t)}.bind(this)),l.call(this,u,{self:this,state:"open",item:u}),h=null,o=null,s=null,this))}}(),this.setValue=function(t,e){var n=i.isNumber(t)?t:y.call(this,t);if(n===-1)return void console.log(ax5.info.getError("ax5autocomplete","402","val"));if(_.call(this,n),i.isArray(e)){var a=i.map(e,function(){return{value:this}});I.call(this,n,a,!0,{noStateChange:!0})}else i.isObject(e)?I.call(this,n,{value:e},!0,{noStateChange:!0}):h.call(this,n);return m.call(this,n),s.call(this),this},this.setText=function(t,e){var n=i.isNumber(t)?t:y.call(this,t);return n===-1?void console.log(ax5.info.getError("ax5autocomplete","402","val")):(this.queue[n].selected=[],_.call(this,n),I.call(this,n,e,!0,{noStateChange:!0}),m.call(this,n),s.call(this),this)},this.getSelectedOption=function(t){var e=i.isNumber(t)?t:y.call(this,t);return e===-1?void console.log(ax5.info.getError("ax5autocomplete","402","val")):i.deepCopy(this.queue[e].selected)},this.close=function(t){return this.closeTimer&&clearTimeout(this.closeTimer),this.activeautocompleteOptionGroup?(t=this.queue[this.activeautocompleteQueueIndex],t.optionFocusIndex=-1,t.$display.removeAttr("data-autocomplete-option-group-opened").trigger("focus"),this.activeautocompleteOptionGroup.addClass("destroy"),jQuery(window).unbind("resize.ax5autocomplete-"+this.instanceId).unbind("click.ax5autocomplete-"+this.instanceId).unbind("keyup.ax5autocomplete-"+this.instanceId),this.closeTimer=setTimeout(function(){this.activeautocompleteOptionGroup&&this.activeautocompleteOptionGroup.remove(),this.activeautocompleteOptionGroup=null,this.activeautocompleteQueueIndex=-1,l.call(this,t,{self:this,state:"close"})}.bind(this),e.animateTime),this.waitOptionsCallback=null,this):this},this.blur=function(t){var e=i.isNumber(t)?t:y.call(this,t);return e===-1?void console.log(ax5.info.getError("ax5autocomplete","402","val")):(m.call(this,e),this)},this.enable=function(t){var e=y.call(this,t);return"undefined"!=typeof e&&(this.queue[e].disable=!1,this.queue[e].$display[0]&&(this.queue[e].$display.removeAttr("disabled"),this.queue[e].$displayLabelInput.removeAttr("disabled")),this.queue[e].$select[0]&&this.queue[e].$select.removeAttr("disabled"),l.call(this,this.queue[e],{self:this,state:"enable"})),this},this.disable=function(t){var e=y.call(this,t);return"undefined"!=typeof e&&(this.queue[e].disable=!0,this.queue[e].$display[0]&&(this.queue[e].$display.attr("disabled","disabled"),this.queue[e].$displayLabelInput.attr("disabled","disabled")),this.queue[e].$select[0]&&this.queue[e].$select.attr("disabled","disabled"),l.call(this,this.queue[e],{self:this,state:"disable"})),this},this.align=function(){return s.call(this),this},this.main=function(){arguments&&i.isObject(arguments[0])?this.setConfig(arguments[0]):this.init()}.apply(this,arguments)};return e}()),t=ax5.ui.autocomplete}(),ax5.ui.autocomplete_instance=new ax5.ui.autocomplete,jQuery.fn.ax5autocomplete=function(){return function(t){if(ax5.util.isString(arguments[0])){var e=arguments[0];switch(e){case"open":return ax5.ui.autocomplete_instance.open(this);case"close":return ax5.ui.autocomplete_instance.close(this);case"setValue":return ax5.ui.autocomplete_instance.setValue(this,arguments[1],arguments[2],arguments[3],arguments[4]||"justSetValue");case"setText":return ax5.ui.autocomplete_instance.setText(this,arguments[1],arguments[2],arguments[3],arguments[4]||"justSetValue");case"getSelectedOption":return ax5.ui.autocomplete_instance.getSelectedOption(this);case"enable":return ax5.ui.autocomplete_instance.enable(this);case"disable":return ax5.ui.autocomplete_instance.disable(this);case"blur":return ax5.ui.autocomplete_instance.blur(this);default:return this}}else"undefined"==typeof t&&(t={}),jQuery.each(this,function(){var e={target:this};t=jQuery.extend({},t,e),ax5.ui.autocomplete_instance.bind(t)});return this}}(),function(){var t=ax5.ui.autocomplete,e=(ax5.util,function(t){return'\n
\n
\n
\n
\n
\n
\n'}),i=function(t){return' \n\n
\n
\n
\n \n
\n
\n {{#multiple}}{{#reset}}\n {{{.}}}\n {{/reset}}{{/multiple}}\n
\n
\n\n'},n=function(t){return'\n\n'},a=function(t){return'\n{{#selected}}\n\n{{/selected}}\n"},o=function(t){return'\n{{#waitOptions}}\n
\n
\n \n {{{lang.loading}}}\n \n
\n
\n{{/waitOptions}}\n{{^waitOptions}}\n {{#options}}\n {{^hide}}\n
\n
\n {{'+t.optionText+'}}\n
\n
\n {{/hide}}\n {{/options}}\n {{^options}}\n
\n
\n \n {{{lang.noOptions}}}\n \n
\n
\n {{/options}}\n{{/waitOptions}}\n'},l=function(t){return'{{#selected}}
{{{removeIcon}}}
{{text}}
{{/selected}}'};t.tmpl={autocompleteDisplay:i,formSelect:n,formSelectOptions:a,optionGroup:e,options:o,label:l,get:function(e,i,n){return ax5.mustache.render(t.tmpl[e].call(this,n),i)}}}(); //# sourceMappingURL=ax5ui.all.min.js.map diff --git a/dist/ax5ui.all.min.js.map b/dist/ax5ui.all.min.js.map index 6898a4b0..fa8137f0 100644 --- a/dist/ax5ui.all.min.js.map +++ b/dist/ax5ui.all.min.js.map @@ -1 +1 @@ -{"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","_close","removeClass","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","$","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","_this2","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","resetFrozenColumn","dividedBodyRowObj","divideTableByFrozenColumnIndex","asideBodyRowData","dataTable","rowspan","_col","columnAttr","leftData","rightData","dividedBodyGroupingObj","asideBodyGroupingData","dividedFootSumObj","getFieldValue","_list","_index","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","cgi","cgl","di","dl","tri","ci","cellHeight","colAlign","SS","isScrolled","rowTable","isGroupingRow","_focusedColumn","_selectedColumn","attrs","tdCSS_class","styleClass","_cellHeight","lineHeight","multiLine","paddingTop","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","compareString","ari","groupingKeys","gi","gl","appendRow","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","fadeOut","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","onSelectFile","_evt","files","dataTransfer","openProgressBox","bindEvent","isItemCell","hasAttribute","alignLayout","alignProgressBox","_alignProgressBox","$progressBox","$progressBoxArrow","viewport","$progressUpload","$progressAbort","closeProgressBox","startUpload","html5","uploadFile","shift","uploadComplete","formData","FormData","xhr","XMLHttpRequest","res","response","debug","uploaded","onprogress","updateProgressBar","loaded","total","filesTotal","$progressBar","lengthComputable","repaintUploadedBox","onuploaded","onuploadComplete","cancelUpload","dropZone","cellType","uploadedItemIndex","parents","fileIndex","setUploadedFiles","_files","removeFile","removeFileAll","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","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,EAAA,Q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,GAAAr9D,IAAAic,GAAAqiD,aAGA1J,GAFA50D,IAAAwG,KAEA,SAAAggB,GACA,MAAA,kTAUAg4C,EAAA,SAAAh4C,GACA,MAAA,w5BAoBAsuC,EAAA,SAAAtuC,GACA,MAAA,6GAKAuuC,EAAA,SAAAvuC,GACA,MAAA,qCAEAA,EAAAyd,YAFA,yBAEAzd,EAAA0d,WAFA,gCAQAhd,EAAA,SAAAV,GACA,MAAA,giBAaAA,EAAAyd,YAbA,UAaAzd,EAAA2d,eAbA,mCAaA3d,EAAA2d,eAbA,yKAeA3d,EAAA0d,WAfA,ycAiCAhhC,EAAA,SAAAsjB,GACA,MAAA,+QAGA62C,GAAAl5C,MACAq6C,oBAAAA,EACA1J,WAAAA,EACAC,kBAAAA,EACAH,YAAAA,EACA1tC,QAAAA,EACAhkB,MAAAA,EAEAyR,IAAA,SAAA8R,EAAA1C,EAAAyC,GACA,MAAAxmB,KAAA0d,SAAAuE,OAAAo7C,EAAAl5C,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.58\";\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.58\"\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 {{{title}}}\\n
\\n
\\n
{{{msg}}}
\\n \\n {{#input}}\\n
\\n {{#@each}}\\n
\\n {{#@value.label}}\\n \\n {{/@value.label}}\\n \\n {{#@value.help}}\\n

{{#_crlf}}{{.}}{{/_crlf}}

\\n {{/@value.help}}\\n
\\n {{/@each}}\\n
\\n {{/input}}\\n \\n
\\n
\\n {{#btns}}\\n {{#@each}}\\n \\n {{/@each}}\\n {{/btns}}\\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.58\"\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 };\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 if (this.$mask) {\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(this), _delay);\n } else {\n _close.call(this);\n }\n }\n return this;\n };\n //== class body end\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.58\"\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
\\n {{#@each}}\\n \\n {{/@each}}\\n
\\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.58\"\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,\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.$ = {}; // 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;\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 onStateChanged.call(this, opts, that);\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;\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 var modalOffset = this.activeModal.position();\n var modalBox = {\n width: this.activeModal.outerWidth(), height: this.activeModal.outerHeight()\n };\n var windowBox = {\n width: jQuery(window).width(),\n height: jQuery(window).height()\n };\n var 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 //console.log(this.activeModal.offset(), this.__dx);\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) {\n if (!this.activeModal) {\n opts = self.modalConfig = jQuery.extend(true, {}, cfg, opts);\n open.call(this, opts, callback);\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 onStateChanged.call(this, opts, {\n self: this,\n state: \"close\"\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 {{{title}}}\\n {{#btns}}\\n
\\n {{#@each}}\\n \\n {{/@each}}\\n
\\n {{/btns}}\\n
\\n {{/header}}\\n
\\n {{#iframe}}\\n \\n
\\n
{{{iframeLoadingMsg}}}
\\n \\n
\\n
\\n \\n {{#param}}\\n {{#@each}}\\n \\n {{/@each}}\\n {{/param}}\\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.58\"\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 {{{left}}}\\n
\\n {{{right}}}\\n
\\n {{/control}}\\n
\\n
\\n ';\n };\n var dayTmpl = function dayTmpl(columnKeys) {\n return '\\n \\n \\n \\n {{#weekNames}}\\n \\n {{/weekNames}}\\n \\n \\n \\n \\n {{#list}} \\n {{#isStartOfWeek}}\\n {{^@first}}\\n \\n \\n {{/@first}}\\n {{/isStartOfWeek}}\\n \\n {{/list}}\\n \\n \\n
\\n {{label}}\\n
\\n \\n \\n {{thisDataLabel}}\\n \\n \\n
\\n ';\n };\n var monthTmpl = function monthTmpl(columnKeys) {\n return '\\n \\n \\n \\n \\n \\n \\n \\n \\n {{#list}} \\n {{#isStartOfRow}}\\n {{^@first}}\\n \\n \\n {{/@first}}\\n {{/isStartOfRow}}\\n \\n {{/list}}\\n \\n \\n
\\n {{colHeadLabel}}\\n
\\n \\n \\n {{thisMonthLabel}}\\n \\n \\n
\\n ';\n };\n var yearTmpl = function yearTmpl(columnKeys) {\n return '\\n \\n \\n \\n \\n \\n \\n \\n \\n {{#list}} \\n {{#isStartOfRow}}\\n {{^@first}}\\n \\n \\n {{/@first}}\\n {{/isStartOfRow}}\\n \\n {{/list}}\\n \\n \\n
\\n {{colHeadLabel}}\\n
\\n \\n \\n {{thisYearLabel}}\\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.58\"\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.58\"\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.58\"\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 {{#' + columnKeys.items + '}}\\n {{^@isMenu}}\\n {{#divide}}\\n
\\n {{/divide}}\\n {{#html}}\\n
{{{@html}}}
\\n {{/html}}\\n {{/@isMenu}}\\n {{#@isMenu}}\\n
\\n \\n {{#check}}\\n \\n {{/check}}\\n {{^check}}\\n \\n {{/check}}\\n \\n {{#icon}}\\n {{{.}}}\\n {{/icon}}\\n {{{' + columnKeys.label + '}}}\\n {{#accelerator}}\\n {{.}}\\n {{/accelerator}}\\n {{#@hasChild}}\\n {{{cfg.icons.arrow}}}\\n {{/@hasChild}}\\n
\\n {{/@isMenu}}\\n\\n {{/' + columnKeys.items + '}}\\n
\\n
\\n
\\n ';\n };\n var tmplMenubar = function tmplMenubar(columnKeys) {\n return '\\n
\\n
\\n {{#' + columnKeys.items + '}}\\n {{^@isMenu}}\\n {{#divide}}\\n
\\n {{/divide}}\\n {{#html}}\\n
{{{@html}}}
\\n {{/html}}\\n {{/@isMenu}}\\n {{#@isMenu}}\\n
\\n {{#icon}}\\n {{{.}}}\\n {{/icon}}\\n {{{' + columnKeys.label + '}}}\\n
\\n {{/@isMenu}}\\n {{/' + columnKeys.items + '}}\\n
\\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.58\"\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
\\n
\\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.58\"\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 _this2 = 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 = _this2.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(_this2);\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 (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) {\n var _key = _col.key;\n var 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 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 var list = this.list;\n if (_reset) {\n resetFrozenColumn.call(this);\n this.xvar.paintStartRowIndex = undefined;\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 var isFirstPaint = typeof this.xvar.paintStartRowIndex === \"undefined\";\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 this.xvar.scrollContentHeight = this.xvar.bodyTrHeight * (this.list.length - this.xvar.frozenRowIndex);\n this.$.livePanelKeys = [];\n\n // body-scroll 의 포지션에 의존적이므로..\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 var cgi, cgl;\n var di, dl;\n var tri, trl;\n var ci, cl;\n var col, cellHeight, colAlign;\n var 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 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;\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 var 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\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('');\n SS.push('');\n }\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 SS.push('
');\n\n if (isScrolled) {\n _elTarget.css({ paddingTop: (_scrollConfig.paintStartRowIndex - this.xvar.frozenRowIndex) * _scrollConfig.bodyTrHeight });\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 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('');\n SS.push('');\n }\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 _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\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('');\n SS.push('');\n }\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 _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('');\n SS.push('');\n }\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 _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 }\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.bodyRowData,\n footSumData = this.footSumData,\n bodyGroupingData = this.bodyGroupingData;\n\n // body-scroll 의 포지션에 의존적이므로..\n var getBody = function getBody(_colGroup, _bodyRow, _groupRow, _list) {\n var SS = [],\n di,\n dl,\n tri,\n trl,\n ci,\n cl,\n col;\n\n //SS.push('');\n for (di = 0, dl = _list.length; di < dl; di++) {\n var isGroupingRow = false;\n var 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('');\n }\n SS.push('\\n');\n }\n }\n //SS.push('
', isGroupingRow ? getGroupingValue.call(this, _list[di], di, col) : getFieldValue.call(this, _list, _list[di], di, col), '
');\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('');\n }\n SS.push('\\n');\n }\n //SS.push('
', getSumFieldValue.call(this, _list, col), '
');\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 var returnList = [];\n var appendIndex = 0;\n var 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,\n appendRow = [],\n 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 } 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\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 var colIndex = this.getAttribute(\"data-ax5grid-column-colindex\");\n var rowIndex = this.getAttribute(\"data-ax5grid-column-rowindex\");\n var 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 var 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 var colGroup = this.colGroup;\n var _key = _col.key;\n var 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 var colGroup = this.colGroup;\n if (_reset) {\n resetFrozenColumn.call(this);\n this.xvar.paintStartRowIndex = undefined;\n }\n var asideHeaderData = this.asideHeaderData;\n var leftHeaderData = this.leftHeaderData;\n var headerData = this.headerData;\n var 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 var 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('');\n SS.push('');\n }\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 _elTarget.html(SS.join(''));\n\n /// append column-resizer\n (function () {\n var resizerHeight = cfg.header.columnHeight * _bodyRow.rows.length - cfg.header.columnBorderWidth;\n var resizerLeft = 0;\n var AS = [];\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 var sortInfo = {};\n var 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 var colGroup = this.colGroup;\n var headerData = this.headerData;\n\n var 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('');\n }\n SS.push('');\n }\n //SS.push('
', getFieldValue.call(this, col), '
');\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, newTop;\n var _top_is_end = false;\n var _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 var 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 this.xvar.__x_da = 0; // 이동량 변수 초기화 (계산이 잘못 될까바)\n this.xvar.__y_da = 0; // 이동량 변수 초기화 (계산이 잘못 될까바)\n\n jQuery(document.body).bind(\"touchmove\" + \".ax5grid-\" + this.instanceId, function (e) {\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 }).bind(\"touchend\" + \".ax5grid-\" + this.instanceId, function (e) {\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 jQuery(document.body).attr('unselectable', 'on').css('user-select', 'none').on('selectstart', false);\n },\n \"off\": function off() {\n\n jQuery(document.body).unbind(\"touchmove\" + \".ax5grid-\" + this.instanceId).unbind(\"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 //this.config.scroller.size\n var 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 var delta = { x: 0, y: 0 };\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
\\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
\\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.58\"\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
\\n
\\n
\\n
\\n {{{loading.icon}}}\\n {{{loading.text}}}\\n
\\n
\\n
\\n {{#media}}\\n
\\n
{{{prevHandle}}}
\\n
\\n
\\n {{#list}}\\n
\\n {{#image}}\\n
\\n \\n
\\n {{/image}}\\n {{#video}}\\n
{{#' + columnKeys.poster + '}}>{{/' + columnKeys.poster + '}}{{^' + columnKeys.poster + '}}{{{media.' + columnKeys.poster + '}}}{{/' + columnKeys.poster + '}}
\\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.58\"\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 onStateChanged = function onStateChanged(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 };\n\n var onSelectFile = function (_evt) {\n var files = void 0;\n\n if (!ax5.info.supportFileApi) {\n // file API 지원 안되는 브라우저.\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 openProgressBox();\n }\n if (!cfg.manualUpload) {\n this.send();\n }\n }.bind(this);\n\n var bindEvent = function bindEvent() {\n this.$fileSelector.off(\"click.ax5uploader\").on(\"click.ax5uploader\", function () {\n this.$inputFile.trigger(\"click\");\n }.bind(this));\n\n this.$inputFile.off(\"change.ax5uploader\").on(\"change.ax5uploader\", function (_evt) {\n onSelectFile(_evt);\n }.bind(this));\n\n (function () {\n // dropZone 설정 방식 변경\n if (!this.$dropZone || !this.$dropZone.get(0)) return false;\n\n var timer = void 0;\n\n this.$dropZone.on(\"click\", function (e) {\n //console.log(e.target.getAttribute(\"data-ax5uploader-dropzone\"));\n var isItemCell = ax5.util.findParentNode(e.target, function (target) {\n if (target.hasAttribute(\"data-uploaded-item-cell\")) {\n return true;\n }\n });\n\n if (!isItemCell) {\n // dropZone click\n self.$inputFile.trigger(\"click\");\n }\n });\n\n this.$dropZone.get(0).addEventListener('dragover', function (e) {\n U.stopEvent(e);\n self.$dropZone.addClass(\"dragover\");\n }, false);\n\n this.$dropZone.get(0).addEventListener('dragleave', function (e) {\n U.stopEvent(e);\n self.$dropZone.removeClass(\"dragover\");\n }, false);\n\n this.$dropZone.get(0).addEventListener('drop', function (e) {\n U.stopEvent(e);\n self.$dropZone.removeClass(\"dragover\");\n onSelectFile(e || window.event);\n }, false);\n }).call(this);\n };\n\n var alignLayout = function alignLayout() {\n // 상황이 좋지 않은경우 (만약 버튼 클릭으로 input file click이 되지 않는 다면 z-index값을 높여서 버튼위를 덮는다.)\n /*\n var box = this.$fileSelector.position();\n box.width = this.$fileSelector.outerWidth();\n box.height = this.$fileSelector.outerHeight();\n this.$inputFile.css(box);\n */\n };\n\n var alignProgressBox = function alignProgressBox(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.direction || cfg.direction === \"\" || cfg.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 = cfg.direction;\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 };\n\n var openProgressBox = function () {\n this.$progressBox.removeClass(\"destroy\");\n this.$progressUpload.removeAttr(\"disabled\");\n this.$progressAbort.removeAttr(\"disabled\");\n\n // apend & align progress box\n alignProgressBox.call(this, \"append\");\n\n // state change\n onStateChanged.call(this, {\n self: this,\n state: \"open\"\n });\n }.bind(this);\n\n var 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 startUpload = function () {\n\n var processor = {\n \"html5\": function html5() {\n\n var uploadFile = this.selectedFiles.shift();\n if (!uploadFile) {\n // 업로드 종료\n 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 return false;\n }\n\n uploaded(res);\n self.send();\n };\n\n this.xhr.upload.onprogress = function (e) {\n // console.log(e.loaded, e.total);\n 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 // 폼과 iframe을 만들어 페이지 아래에 삽입 후 업로드\n // iframe 생성\n var iframe = $('');\n // form 생성.\n\n $(document.body).append(iframe);\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 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 uploaded = function (res) {\n if (cfg.debug) console.log(res);\n this.uploadedFiles.push(res);\n repaintUploadedBox(); // 업로드된 파일 출력\n\n if (U.isFunction(cfg.onuploaded)) {\n cfg.onuploaded.call({\n self: this\n }, res);\n }\n }.bind(this);\n\n var uploadComplete = function () {\n this.__uploading = false; // 업로드 완료 상태처리\n this.$progressUpload.removeAttr(\"disabled\");\n this.$progressAbort.attr(\"disabled\", \"disabled\");\n\n if (cfg.progressBox) {\n closeProgressBox();\n }\n if (U.isFunction(cfg.onuploadComplete)) {\n cfg.onuploadComplete.call({\n self: this\n });\n }\n // update uploadedFiles display\n }.bind(this);\n\n var 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 closeProgressBox();\n }\n\n this.$inputFile.get(0).value = \"\";\n console.log(\"cancelUpload\");\n // update uploadedFiles display\n }.bind(this);\n\n var 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 }, cfg.uploadedBox.columnKeys));\n }.bind(this);\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) {\n this.$dropZone = jQuery(cfg.dropZone);\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 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 }\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 this.$inputFile = jQuery(UPLOADER.tmpl.get.call(this, \"inputFile\", {\n instanceId: this.instanceId,\n multiple: cfg.multiple,\n accept: cfg.accept\n }));\n\n if (ax5.info.supportFileApi) {\n jQuery(document.body).append(this.$inputFile);\n } else {\n this.$inputFileForm = jQuery(UPLOADER.tmpl.get.call(this, \"inputFileForm\", {\n instanceId: this.instanceId\n }));\n this.$inputFileForm.append(this.$inputFile);\n jQuery(document.body).append(this.$inputFileForm);\n }\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 // 레이아웃 정렬\n alignLayout.call(this);\n // 파일버튼 등에 이벤트 연결.\n bindEvent.call(this);\n\n return this;\n };\n\n /**\n * @method ax5uploader.send\n * @returns {ax5uploader}\n *\n */\n this.send = function () {\n return function () {\n // 업로드 시작\n startUpload();\n return this;\n };\n }();\n\n /**\n * @method ax5uploader.abort\n * @returns {ax5uploader}\n */\n this.abort = function () {\n return function () {\n 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 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 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 repaintUploadedBox();\n return this;\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{{{lang.emptyList}}}\\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.58\"\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
\\n
\\n ';\n };\n\n var comboboxDisplay = function comboboxDisplay(columnKeys) {\n return '\\n
\\n
\\n
\\n \\n
\\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 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}}
{{{removeIcon}}}
{{text}}
{{/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.58\"\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
{{{label}}}
\\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.58\"\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.58\"\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
\\n
\\n';\n };\n\n var autocompleteDisplay = function autocompleteDisplay(columnKeys) {\n return ' \\n\\n
\\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}}
{{{removeIcon}}}
{{text}}
{{/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.58\";\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.58\"\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 {{{title}}}\n
\n
\n
{{{msg}}}
\n \n {{#input}}\n
\n {{#@each}}\n
\n {{#@value.label}}\n \n {{/@value.label}}\n \n {{#@value.help}}\n

{{#_crlf}}{{.}}{{/_crlf}}

\n {{/@value.help}}\n
\n {{/@each}}\n
\n {{/input}}\n \n
\n
\n {{#btns}}\n {{#@each}}\n \n {{/@each}}\n {{/btns}}\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.58\"\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 };\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 var _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 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 //== class body end\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 {{{body}}}\n
\n
\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.58\"\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
\n {{#@each}}\n \n {{/@each}}\n
\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.58\"\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 var\n 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 = 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.$ = {}; // UI inside of the jQuery object store\n\n cfg = this.config; // extended config copy cfg\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 getContent = function (modalId, opts) {\n var\n 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 var 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 onStateChanged.call(this, opts, that);\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 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 })\n .bind(\"dragstart\", function (e) {\n U.stopEvent(e);\n return false;\n });\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-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 var modalZIndex = this.activeModal.css(\"z-index\");\n var modalOffset = this.activeModal.position();\n var modalBox = {\n width: this.activeModal.outerWidth(), height: this.activeModal.outerHeight()\n };\n var windowBox = {\n width: jQuery(window).width(),\n height: jQuery(window).height()\n };\n var 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 var setModalPosition = function () {\n //console.log(this.activeModal.offset(), this.__dx);\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)\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) {\n if (!this.activeModal) {\n opts = self.modalConfig = jQuery.extend(true, {}, cfg, opts);\n open.call(this, opts, callback);\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 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 {{{title}}}\n {{#btns}}\n
\n {{#@each}}\n \n {{/@each}}\n
\n {{/btns}}\n
\n {{/header}}\n
\n {{#iframe}}\n \n
\n
{{{iframeLoadingMsg}}}
\n \n
\n
\n \n {{#param}}\n {{#@each}}\n \n {{/@each}}\n {{/param}}\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.58\"\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 {{/weekNames}}\n \n \n \n \n {{#list}} \n {{#isStartOfWeek}}\n {{^@first}}\n \n \n {{/@first}}\n {{/isStartOfWeek}}\n \n {{/list}}\n \n \n
\n {{label}}\n
\n \n \n {{thisDataLabel}}\n \n \n
\n `;\n };\n var monthTmpl = function (columnKeys) {\n return `\n \n \n \n \n \n \n \n \n {{#list}} \n {{#isStartOfRow}}\n {{^@first}}\n \n \n {{/@first}}\n {{/isStartOfRow}}\n \n {{/list}}\n \n \n
\n {{colHeadLabel}}\n
\n \n \n {{thisMonthLabel}}\n \n \n
\n `;\n };\n var yearTmpl = function (columnKeys) {\n return `\n \n \n \n \n \n \n \n \n {{#list}} \n {{#isStartOfRow}}\n {{^@first}}\n \n \n {{/@first}}\n {{/isStartOfRow}}\n \n {{/list}}\n \n \n
\n {{colHeadLabel}}\n
\n \n \n {{thisYearLabel}}\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.58\"\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.58\"\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.58\"\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 {{#${columnKeys.items}}}\n {{^@isMenu}}\n {{#divide}}\n
\n {{/divide}}\n {{#html}}\n
{{{@html}}}
\n {{/html}}\n {{/@isMenu}}\n {{#@isMenu}}\n
\n \n {{#check}}\n \n {{/check}}\n {{^check}}\n \n {{/check}}\n \n {{#icon}}\n {{{.}}}\n {{/icon}}\n {{{${columnKeys.label}}}}\n {{#accelerator}}\n {{.}}\n {{/accelerator}}\n {{#@hasChild}}\n {{{cfg.icons.arrow}}}\n {{/@hasChild}}\n
\n {{/@isMenu}}\n\n {{/${columnKeys.items}}}\n
\n
\n
\n `;\n };\n var tmplMenubar = function (columnKeys) {\n return `\n
\n
\n {{#${columnKeys.items}}}\n {{^@isMenu}}\n {{#divide}}\n
\n {{/divide}}\n {{#html}}\n
{{{@html}}}
\n {{/html}}\n {{/@isMenu}}\n {{#@isMenu}}\n
\n {{#icon}}\n {{{.}}}\n {{/icon}}\n {{{${columnKeys.label}}}}\n
\n {{/@isMenu}}\n {{/${columnKeys.items}}}\n
\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.58\"\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
\n
\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.58\"\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 (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) {\n var _key = _col.key;\n var 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 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 var repaint = function (_reset) {\n var cfg = this.config;\n var list = this.list;\n if (_reset) {\n resetFrozenColumn.call(this);\n this.xvar.paintStartRowIndex = undefined;\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 var isFirstPaint = (typeof this.xvar.paintStartRowIndex === \"undefined\");\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 this.xvar.scrollContentHeight = this.xvar.bodyTrHeight * (this.list.length - this.xvar.frozenRowIndex);\n this.$.livePanelKeys = [];\n\n // body-scroll 의 포지션에 의존적이므로..\n var repaintBody = function (_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 var cgi, cgl;\n var di, dl;\n var tri, trl;\n var ci, cl;\n var col, cellHeight, colAlign;\n var 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 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;\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 var 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\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('');\n SS.push('');\n }\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), (isGroupingRow) ? getGroupingValue.call(this, _list[di], di, col) : getFieldValue.call(this, _list, _list[di], di, col), '');\n SS.push('
');\n\n if (isScrolled) {\n _elTarget.css({paddingTop: (_scrollConfig.paintStartRowIndex - this.xvar.frozenRowIndex) * _scrollConfig.bodyTrHeight});\n }\n _elTarget.empty().get(0).innerHTML = SS.join('');\n\n this.$.livePanelKeys.push(_elTargetKey); // 사용중인 패널키를 모아둠. (뷰의 상태 변경시 사용하려고)\n return true;\n };\n var repaintSum = function (_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 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('');\n SS.push('');\n }\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 _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\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('');\n SS.push('');\n }\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 _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('');\n SS.push('');\n }\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 _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\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 }\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.bodyRowData,\n footSumData = this.footSumData,\n bodyGroupingData = this.bodyGroupingData;\n\n // body-scroll 의 포지션에 의존적이므로..\n let getBody = function (_colGroup, _bodyRow, _groupRow, _list) {\n var 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 var isGroupingRow = false;\n var 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('');\n }\n SS.push('\\n');\n }\n }\n //SS.push('
', (isGroupingRow) ? getGroupingValue.call(this, _list[di], di, col) : getFieldValue.call(this, _list, _list[di], di, col), '
');\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('');\n }\n SS.push('\\n');\n }\n //SS.push('
', getSumFieldValue.call(this, _list, col), '
');\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 var initData = function (_list) {\n this.selectedDataIndexs = [];\n var i = 0, l = _list.length;\n var returnList = [];\n var appendIndex = 0;\n var 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, 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 var set = function (data) {\n var 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 var get = function (_type) {\n return {\n list: this.list,\n page: this.page\n };\n };\n\n var getList = function (_type) {\n var returnList = [];\n var 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 var add = function (_row, _dindex, _options) {\n var list = (this.config.body.grouping) ? clearGroupingData.call(this, this.list) : this.list;\n var 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 var remove = function (_dindex) {\n var list = (this.config.body.grouping) ? clearGroupingData.call(this, this.list) : this.list;\n var 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 var deleteRow = function (_dindex) {\n var list = (this.config.body.grouping) ? clearGroupingData.call(this, this.list) : this.list;\n\n var 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 var 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 var setValue = function (_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\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 var 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 var 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 var key = this.getAttribute(\"data-ax5grid-column-key\");\n var colIndex = this.getAttribute(\"data-ax5grid-column-colindex\");\n var rowIndex = this.getAttribute(\"data-ax5grid-column-rowindex\");\n var 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 var cfg = this.config;\n var 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 var cfg = this.config;\n var colGroup = this.colGroup;\n var _key = _col.key;\n var 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 var cfg = this.config;\n var colGroup = this.colGroup;\n if (_reset) {\n resetFrozenColumn.call(this);\n this.xvar.paintStartRowIndex = undefined;\n }\n var asideHeaderData = this.asideHeaderData;\n var leftHeaderData = this.leftHeaderData;\n var headerData = this.headerData;\n var 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 var tableWidth = 0;\n var 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('');\n SS.push('');\n }\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 _elTarget.html(SS.join(''));\n\n /// append column-resizer\n (function () {\n var resizerHeight = cfg.header.columnHeight * _bodyRow.rows.length - cfg.header.columnBorderWidth;\n var resizerLeft = 0;\n var AS = [];\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 var sortOrder = \"\";\n var sortInfo = {};\n var 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 var cfg = this.config;\n var colGroup = this.colGroup;\n var headerData = this.headerData;\n\n var 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('');\n }\n SS.push('');\n }\n //SS.push('
', getFieldValue.call(this, col), '
');\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 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, newTop;\n var _top_is_end = false;\n var _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 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 (e) {\n var mouseObj = GRID.util.getMousePosition(e);\n var 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 this.xvar.__x_da = 0; // 이동량 변수 초기화 (계산이 잘못 될까바)\n this.xvar.__y_da = 0; // 이동량 변수 초기화 (계산이 잘못 될까바)\n\n jQuery(document.body)\n .bind(\"touchmove\" + \".ax5grid-\" + this.instanceId, function (e) {\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 })\n .bind(\"touchend\" + \".ax5grid-\" + this.instanceId, function (e) {\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 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 .unbind(\"touchmove\" + \".ax5grid-\" + this.instanceId)\n .unbind(\"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 var self = this;\n //this.config.scroller.size\n var 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 var E = e.originalEvent;\n var delta = {x: 0, y: 0};\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\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
\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
\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.58\"\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
\n
\n
\n
\n {{{loading.icon}}}\n {{{loading.text}}}\n
\n
\n
\n {{#media}}\n
\n
{{{prevHandle}}}
\n
\n
\n {{#list}}\n
\n {{#image}}\n
\n \n
\n {{/image}}\n {{#video}}\n
{{#${columnKeys.poster}}}>{{/${columnKeys.poster}}}{{^${columnKeys.poster}}}{{{media.${columnKeys.poster}}}}{{/${columnKeys.poster}}}
\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.58\"\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,\n 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 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 };\n\n let onSelectFile = (function (_evt) {\n let files;\n\n if (!ax5.info.supportFileApi) {\n // file API 지원 안되는 브라우저.\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 openProgressBox();\n }\n if (!cfg.manualUpload) {\n this.send();\n }\n }).bind(this);\n\n let bindEvent = function () {\n this.$fileSelector\n .off(\"click.ax5uploader\")\n .on(\"click.ax5uploader\", (function () {\n this.$inputFile.trigger(\"click\");\n }).bind(this));\n\n this.$inputFile\n .off(\"change.ax5uploader\")\n .on(\"change.ax5uploader\", (function (_evt) {\n onSelectFile(_evt);\n }).bind(this));\n\n (function () {\n // dropZone 설정 방식 변경\n if(!this.$dropZone || !this.$dropZone.get(0)) return false;\n\n let timer;\n\n this.$dropZone\n .on(\"click\", function (e) {\n //console.log(e.target.getAttribute(\"data-ax5uploader-dropzone\"));\n let isItemCell = ax5.util.findParentNode(e.target, function(target){\n if(target.hasAttribute(\"data-uploaded-item-cell\")){\n return true;\n }\n });\n\n if(!isItemCell){\n // dropZone click\n self.$inputFile.trigger(\"click\");\n }\n });\n\n\n this.$dropZone.get(0).addEventListener('dragover', function (e) {\n U.stopEvent(e);\n self.$dropZone.addClass(\"dragover\");\n }, false);\n\n this.$dropZone.get(0).addEventListener('dragleave', function (e) {\n U.stopEvent(e);\n self.$dropZone.removeClass(\"dragover\");\n }, false);\n\n this.$dropZone.get(0).addEventListener('drop', function (e) {\n U.stopEvent(e);\n self.$dropZone.removeClass(\"dragover\");\n onSelectFile(e || window.event);\n }, false);\n\n }).call(this);\n };\n\n let alignLayout = function () {\n // 상황이 좋지 않은경우 (만약 버튼 클릭으로 input file click이 되지 않는 다면 z-index값을 높여서 버튼위를 덮는다.)\n /*\n var box = this.$fileSelector.position();\n box.width = this.$fileSelector.outerWidth();\n box.height = this.$fileSelector.outerHeight();\n this.$inputFile.css(box);\n */\n };\n\n let 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.direction || cfg.direction === \"\" || cfg.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 = cfg.direction;\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 };\n\n let openProgressBox = (function () {\n this.$progressBox.removeClass(\"destroy\");\n this.$progressUpload.removeAttr(\"disabled\");\n this.$progressAbort.removeAttr(\"disabled\");\n\n // apend & align progress box\n alignProgressBox.call(this, \"append\");\n\n // state change\n onStateChanged.call(this, {\n self: this,\n state: \"open\"\n });\n }).bind(this);\n\n let 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 startUpload = (function () {\n\n let processor = {\n \"html5\": function () {\n\n let uploadFile = this.selectedFiles.shift();\n if (!uploadFile) {\n // 업로드 종료\n 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 return false;\n }\n\n uploaded(res);\n self.send();\n };\n\n this.xhr.upload.onprogress = function (e) {\n // console.log(e.loaded, e.total);\n 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 // 폼과 iframe을 만들어 페이지 아래에 삽입 후 업로드\n // iframe 생성\n let iframe = $('');\n // form 생성.\n\n $(document.body).append(iframe);\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\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 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 uploaded = (function (res) {\n if (cfg.debug) console.log(res);\n this.uploadedFiles.push(res);\n repaintUploadedBox(); // 업로드된 파일 출력\n\n if (U.isFunction(cfg.onuploaded)) {\n cfg.onuploaded.call({\n self: this\n }, res);\n }\n }).bind(this);\n\n let uploadComplete = (function () {\n this.__uploading = false; // 업로드 완료 상태처리\n this.$progressUpload.removeAttr(\"disabled\");\n this.$progressAbort.attr(\"disabled\", \"disabled\");\n\n if (cfg.progressBox) {\n closeProgressBox();\n }\n if (U.isFunction(cfg.onuploadComplete)) {\n cfg.onuploadComplete.call({\n self: this\n });\n }\n // update uploadedFiles display\n }).bind(this);\n\n let 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 closeProgressBox();\n }\n\n this.$inputFile.get(0).value = \"\";\n console.log(\"cancelUpload\");\n // update uploadedFiles display\n }).bind(this);\n\n let 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 }, cfg.uploadedBox.columnKeys)\n );\n\n }).bind(this);\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) {\n this.$dropZone = jQuery(cfg.dropZone);\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 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 }\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 this.$inputFile = jQuery(UPLOADER.tmpl.get.call(this, \"inputFile\", {\n instanceId: this.instanceId,\n multiple: cfg.multiple,\n accept: cfg.accept\n }));\n\n if (ax5.info.supportFileApi) {\n jQuery(document.body).append(this.$inputFile);\n } else {\n this.$inputFileForm = jQuery(UPLOADER.tmpl.get.call(this, \"inputFileForm\", {\n instanceId: this.instanceId\n }));\n this.$inputFileForm.append(this.$inputFile);\n jQuery(document.body).append(this.$inputFileForm);\n }\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 // 레이아웃 정렬\n alignLayout.call(this);\n // 파일버튼 등에 이벤트 연결.\n bindEvent.call(this);\n\n return this;\n };\n\n /**\n * @method ax5uploader.send\n * @returns {ax5uploader}\n *\n */\n this.send = (function () {\n return function () {\n // 업로드 시작\n startUpload();\n return this;\n }\n })();\n\n /**\n * @method ax5uploader.abort\n * @returns {ax5uploader}\n */\n this.abort = (function () {\n return function () {\n 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 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 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 repaintUploadedBox();\n return this;\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
\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 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{{{lang.emptyList}}}\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.58\"\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
\n
\n `;\n };\n\n var comboboxDisplay = function (columnKeys) {\n return `\n
\n
\n
\n \n
\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 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}}
{{{removeIcon}}}
{{text}}
{{/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.58\"\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
{{{label}}}
\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.58\"\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.58\"\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
\n
\n`;\n };\n\n var autocompleteDisplay = function (columnKeys) {\n return ` \n\n
\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}}
{{{removeIcon}}}
{{text}}
{{/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,EAAA,QAGAC,IAMAA,GAAAC,KAAA,EAMAD,EAAAE,QAAA,WACA,MAAAF,GAAAC,QAOAD,EAAApB,KAAAA,EAAA,WAsJA,QAAAuB,GAAAC,EAAAC,GAgBA,MAfAD,IACAE,KAAAtB,EAAAuB,SAAAD,KACAE,MAAAxB,EAAAuB,SAAAE,OACAC,SAAAzB,EAAAyB,SACAC,SAAA3B,EAAAuB,SAAAI,SACAC,SAAA5B,EAAAuB,SAAAK,SACAC,KAAA7B,EAAAuB,SAAAM,MACAR,EAAAD,EAAAE,KAAAQ,MAAA,SACAV,EAAAI,MAAAJ,EAAAI,MAAAO,QAAA,IAAA,IACAX,EAAAA,IAAAC,EAAA,GACAD,EAAAE,KAAAG,OAAA,UACAL,EAAAY,SAAAnC,EAAAoC,KAAAZ,IAEAA,EAAA,KACAD,EAAAc,QAAArC,EAAAsC,KAAAf,EAAAE,KAAA,KAAAS,QAAAX,EAAAO,SAAA,IACAP,EAuBA,Q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Content":["'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 {{{title}}}\\n
\\n
\\n
{{{msg}}}
\\n \\n {{#input}}\\n
\\n {{#@each}}\\n
\\n {{#@value.label}}\\n \\n {{/@value.label}}\\n \\n {{#@value.help}}\\n

{{#_crlf}}{{.}}{{/_crlf}}

\\n {{/@value.help}}\\n
\\n {{/@each}}\\n
\\n {{/input}}\\n \\n
\\n
\\n {{#btns}}\\n {{#@each}}\\n \\n {{/@each}}\\n {{/btns}}\\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
\\n {{#@each}}\\n \\n {{/@each}}\\n
\\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 {{{title}}}\\n {{#btns}}\\n
\\n {{#@each}}\\n \\n {{/@each}}\\n
\\n {{/btns}}\\n
\\n {{/header}}\\n
\\n {{#iframe}}\\n \\n
\\n
{{{iframeLoadingMsg}}}
\\n \\n
\\n
\\n \\n {{#param}}\\n {{#@each}}\\n \\n {{/@each}}\\n {{/param}}\\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 {{{left}}}\\n
\\n {{{right}}}\\n
\\n {{/control}}\\n
\\n
\\n ';\n };\n var dayTmpl = function dayTmpl(columnKeys) {\n return '\\n \\n \\n \\n {{#weekNames}}\\n \\n {{/weekNames}}\\n \\n \\n \\n \\n {{#list}} \\n {{#isStartOfWeek}}\\n {{^@first}}\\n \\n \\n {{/@first}}\\n {{/isStartOfWeek}}\\n \\n {{/list}}\\n \\n \\n
\\n {{label}}\\n
\\n \\n \\n {{thisDataLabel}}\\n \\n \\n
\\n ';\n };\n var monthTmpl = function monthTmpl(columnKeys) {\n return '\\n \\n \\n \\n \\n \\n \\n \\n \\n {{#list}} \\n {{#isStartOfRow}}\\n {{^@first}}\\n \\n \\n {{/@first}}\\n {{/isStartOfRow}}\\n \\n {{/list}}\\n \\n \\n
\\n {{colHeadLabel}}\\n
\\n \\n \\n {{thisMonthLabel}}\\n \\n \\n
\\n ';\n };\n var yearTmpl = function yearTmpl(columnKeys) {\n return '\\n \\n \\n \\n \\n \\n \\n \\n \\n {{#list}} \\n {{#isStartOfRow}}\\n {{^@first}}\\n \\n \\n {{/@first}}\\n {{/isStartOfRow}}\\n \\n {{/list}}\\n \\n \\n
\\n {{colHeadLabel}}\\n
\\n \\n \\n {{thisYearLabel}}\\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 {{#' + columnKeys.items + '}}\\n {{^@isMenu}}\\n {{#divide}}\\n
\\n {{/divide}}\\n {{#html}}\\n
{{{@html}}}
\\n {{/html}}\\n {{/@isMenu}}\\n {{#@isMenu}}\\n
\\n \\n {{#check}}\\n \\n {{/check}}\\n {{^check}}\\n \\n {{/check}}\\n \\n {{#icon}}\\n {{{.}}}\\n {{/icon}}\\n {{{' + columnKeys.label + '}}}\\n {{#accelerator}}\\n {{.}}\\n {{/accelerator}}\\n {{#@hasChild}}\\n {{{cfg.icons.arrow}}}\\n {{/@hasChild}}\\n
\\n {{/@isMenu}}\\n\\n {{/' + columnKeys.items + '}}\\n
\\n
\\n
\\n ';\n };\n var tmplMenubar = function tmplMenubar(columnKeys) {\n return '\\n
\\n
\\n {{#' + columnKeys.items + '}}\\n {{^@isMenu}}\\n {{#divide}}\\n
\\n {{/divide}}\\n {{#html}}\\n
{{{@html}}}
\\n {{/html}}\\n {{/@isMenu}}\\n {{#@isMenu}}\\n
\\n {{#icon}}\\n {{{.}}}\\n {{/icon}}\\n {{{' + columnKeys.label + '}}}\\n
\\n {{/@isMenu}}\\n {{/' + columnKeys.items + '}}\\n
\\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
\\n
\\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('');\n SS.push('');\n }\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 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('');\n SS.push('');\n }\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 _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('');\n SS.push('');\n }\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 _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('');\n SS.push('');\n }\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 _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('');\n }\n SS.push('\\n');\n }\n }\n //SS.push('
', isGroupingRow ? getGroupingValue.call(this, _list[di], di, col) : getFieldValue.call(this, _list, _list[di], di, col, undefined, \"text\"), '
');\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('');\n }\n SS.push('\\n');\n }\n //SS.push('
', getSumFieldValue.call(this, _list, col), '
');\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('');\n SS.push('');\n }\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 _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('');\n }\n SS.push('');\n }\n //SS.push('
', getFieldValue.call(this, col), '
');\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
\\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
\\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
\\n
\\n
\\n
\\n {{{loading.icon}}}\\n {{{loading.text}}}\\n
\\n
\\n
\\n {{#media}}\\n
\\n
{{{prevHandle}}}
\\n
\\n
\\n {{#list}}\\n
\\n {{#image}}\\n
\\n \\n
\\n {{/image}}\\n {{#video}}\\n
{{#' + columnKeys.poster + '}}>{{/' + columnKeys.poster + '}}{{^' + columnKeys.poster + '}}{{{media.' + columnKeys.poster + '}}}{{/' + columnKeys.poster + '}}
\\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
\\n
\\n ';\n };\n\n var comboboxDisplay = function comboboxDisplay(columnKeys) {\n return '\\n
\\n
\\n
\\n \\n
\\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 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}}
{{{removeIcon}}}
{{text}}
{{/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
{{{label}}}
\\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
\\n
\\n';\n };\n\n var autocompleteDisplay = function autocompleteDisplay(columnKeys) {\n return ' \\n\\n
\\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}}
{{{removeIcon}}}
{{text}}
{{/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 {{{title}}}\n
\n
\n
{{{msg}}}
\n \n {{#input}}\n
\n {{#@each}}\n
\n {{#@value.label}}\n \n {{/@value.label}}\n \n {{#@value.help}}\n

{{#_crlf}}{{.}}{{/_crlf}}

\n {{/@value.help}}\n
\n {{/@each}}\n
\n {{/input}}\n \n
\n
\n {{#btns}}\n {{#@each}}\n \n {{/@each}}\n {{/btns}}\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 {{{body}}}\n
\n
\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
\n {{#@each}}\n \n {{/@each}}\n
\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 {{{title}}}\n {{#btns}}\n
\n {{#@each}}\n \n {{/@each}}\n
\n {{/btns}}\n
\n {{/header}}\n
\n {{#iframe}}\n \n
\n
{{{iframeLoadingMsg}}}
\n \n
\n
\n \n {{#param}}\n {{#@each}}\n \n {{/@each}}\n {{/param}}\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 {{/weekNames}}\n \n \n \n \n {{#list}} \n {{#isStartOfWeek}}\n {{^@first}}\n \n \n {{/@first}}\n {{/isStartOfWeek}}\n \n {{/list}}\n \n \n
\n {{label}}\n
\n \n \n {{thisDataLabel}}\n \n \n
\n `;\n };\n var monthTmpl = function (columnKeys) {\n return `\n \n \n \n \n \n \n \n \n {{#list}} \n {{#isStartOfRow}}\n {{^@first}}\n \n \n {{/@first}}\n {{/isStartOfRow}}\n \n {{/list}}\n \n \n
\n {{colHeadLabel}}\n
\n \n \n {{thisMonthLabel}}\n \n \n
\n `;\n };\n var yearTmpl = function (columnKeys) {\n return `\n \n \n \n \n \n \n \n \n {{#list}} \n {{#isStartOfRow}}\n {{^@first}}\n \n \n {{/@first}}\n {{/isStartOfRow}}\n \n {{/list}}\n \n \n
\n {{colHeadLabel}}\n
\n \n \n {{thisYearLabel}}\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 {{#${columnKeys.items}}}\n {{^@isMenu}}\n {{#divide}}\n
\n {{/divide}}\n {{#html}}\n
{{{@html}}}
\n {{/html}}\n {{/@isMenu}}\n {{#@isMenu}}\n
\n \n {{#check}}\n \n {{/check}}\n {{^check}}\n \n {{/check}}\n \n {{#icon}}\n {{{.}}}\n {{/icon}}\n {{{${columnKeys.label}}}}\n {{#accelerator}}\n {{.}}\n {{/accelerator}}\n {{#@hasChild}}\n {{{cfg.icons.arrow}}}\n {{/@hasChild}}\n
\n {{/@isMenu}}\n\n {{/${columnKeys.items}}}\n
\n
\n
\n `;\n };\n var tmplMenubar = function (columnKeys) {\n return `\n
\n
\n {{#${columnKeys.items}}}\n {{^@isMenu}}\n {{#divide}}\n
\n {{/divide}}\n {{#html}}\n
{{{@html}}}
\n {{/html}}\n {{/@isMenu}}\n {{#@isMenu}}\n
\n {{#icon}}\n {{{.}}}\n {{/icon}}\n {{{${columnKeys.label}}}}\n
\n {{/@isMenu}}\n {{/${columnKeys.items}}}\n
\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
\n
\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('');\n SS.push('');\n }\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 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('');\n SS.push('');\n }\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 _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('');\n SS.push('');\n }\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 _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('');\n SS.push('');\n }\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 _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('');\n }\n SS.push('\\n');\n }\n }\n //SS.push('
', (isGroupingRow) ? getGroupingValue.call(this, _list[di], di, col) : getFieldValue.call(this, _list, _list[di], di, col, undefined, \"text\"), '
');\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('');\n }\n SS.push('\\n');\n }\n //SS.push('
', getSumFieldValue.call(this, _list, col), '
');\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('');\n SS.push('');\n }\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 _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('');\n }\n SS.push('');\n }\n //SS.push('
', getFieldValue.call(this, col), '
');\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
\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
\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
\n
\n
\n
\n {{{loading.icon}}}\n {{{loading.text}}}\n
\n
\n
\n {{#media}}\n
\n
{{{prevHandle}}}
\n
\n
\n {{#list}}\n
\n {{#image}}\n
\n \n
\n {{/image}}\n {{#video}}\n
{{#${columnKeys.poster}}}>{{/${columnKeys.poster}}}{{^${columnKeys.poster}}}{{{media.${columnKeys.poster}}}}{{/${columnKeys.poster}}}
\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
\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 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
\n
\n `;\n };\n\n var comboboxDisplay = function (columnKeys) {\n return `\n
\n
\n
\n \n
\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 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}}
{{{removeIcon}}}
{{text}}
{{/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
{{{label}}}
\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
\n
\n`;\n };\n\n var autocompleteDisplay = function (columnKeys) {\n return ` \n\n
\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}}
{{{removeIcon}}}
{{text}}
{{/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 - - - - - - + + + + + + +