• R/O
  • SSH
  • HTTPS

opengion: Commit


Commit MetaInfo

Revision1397 (tree)
Zeit2017-02-15 19:10:35
Autortakahashi_m

Log Message

(empty log message)

Ändern Zusammenfassung

Diff

--- trunk/opengionV5/uap/webapps/ge/jsp/common/eventScript.js (revision 1396)
+++ trunk/opengionV5/uap/webapps/ge/jsp/common/eventScript.js (revision 1397)
@@ -1 +1 @@
1-var orgFldCls=null;$(function(){if(USE_FOCUS_HILIGHT){setEvent('textarea,select,input[type="text"]',"focusin",function(){doFocus2(this)});setEvent('textarea,select,input[type="text"]',"focusout",function(){doBlur2(this)})}});function doFocus2(a){if(a!=null){if(a.className==null||a.className.indexOf("must")<0){if(a.tagName=="SELECT"){a.orgBgColor=a.style.backgroundColor;a.style.backgroundColor="#ffcccc"}else{orgFldCls=a.className;a.className="focusField "+orgFldCls}}}}function doBlur2(a){if(a!=null){if(a.className==null||a.className.indexOf("must")<0){if(a.tagName=="SELECT"){a.style.backgroundColor=a.orgBgColor}else{if(orgFldCls!=null){a.className=orgFldCls}else{a.className="notFocusField"}}}}}oldDoFocusFlag=true;function doFocus(a){if(oldDoFocusFlag){oldDoFocusFlag=false;setTimeout(alert("Old Script Error!!\ncustom/query_info.jsp,custom/result_info.jsp Please delete the following part.\n<script>Tag(Header fix and Focus) , BODY onLoad and oncontextmenu Attribute"),100)}}function doBlur(a){}$(function(){setEvent('textarea,select,input[type="text"]',"focusout",function(){convert(this)})});function convert(b){var c,a;c=b.value;a=b.className;if(c!=null&&a!=null){if(a.match(/XL/)&&!(a.match(/XLU/))){b.value=c.toLowerCase()}else{if((a.match(/XU/)&&!(a.match(/XUL/)))||a.match(/PN2/)){b.value=c.toUpperCase()}}}return true}var colMap;var notFireCols;var jH_evElm;$(function(){if(!(typeof(EC_NAME)=="undefined")){jH_evElm=$(".h_evElm");makeColMapping();setEvent('textarea,select,input[type="text"]',"change",function(){makeColumn(this)},".h_evCol",true,addEvColCls);setEvent("input[type=checkbox],input[type=radio]","click",function(){makeColumn(this)},".h_evCol",true)}});function makeColMapping(){var b,a,e,d,c;if(colMap){return}colMap=new Object();for(b=0;b<EC_EVCOL.length;b++){e=EC_EVCOL[b].split(",");for(a=0;a<e.length;a++){d=e[a];if(d.charAt(0)=="_"){d=d.substring(1);if(notFireCols){notFireCols+=","}notFireCols+=d}c=colMap[d];if(!c){c=new Array()}c[c.length]=EC_NAME[b];colMap[d]=c}}}function addEvColCls(){for(var a in colMap){$("#"+a+",[id^="+a+"__]").addClass("h_evCol")}}function makeColumn(e){var k,l,g,j,b,h,d,c,a,f;if(jH_evElm&&isEndInitEvent()){jH_evElm=null}k=$(e);l=k.attr("id");g=l.split("__")[0];j=colMap[g];if(!j){return}if(!isEndInitEvent()&&notFireCols&&notFireCols.indexOf(g)>=0){return}for(b=0;b<j.length;b++){h=(l==g?"":"__"+l.split("__")[1]);d=j[b]+h;c=d.split("__")[0];a=isEndInitEvent()?$(".h_evElm[h_evCid="+d+"]"):jH_evElm.filter("[h_evCid="+d+"]");f=a.attr("h_evWrtbl");eventColumn(k,a,d,c,h,f)}}function eventColumn(jEvCol,jTag,cid,cname,suffix,writable){var evVal,url,param,_pos1,_pos2,_repClm,_rep,_clm,noVal,columnFocus,jCol,val,renderer,editor,ATTRS,optAttrs,i,optAtt,vtype,isAdd;var callback;if(!jTag||jTag.length==0){alert("[SYSTEM_ERROR] : jTag is null. The element of the replacement object doesn't exist. ["+cname+"]");return}if(!isEndInitEvent()){evVal=jEvCol.get(0).value;if(!evVal||evVal==null||evVal==""){return}}try{url=eval("EC_"+cname+"_URL")}catch(e){alert("[SYSTEM_ERROR] : URL that processes the event is not specified. (variable undefinition). ["+cname+"]");return}if(!url||url==""){alert("[SYSTEM_ERROR] : URL that processes the event is not specified. ["+cname+"]");return}param="";try{param=(writable?eval("EC_"+cname+"_EDITPARAM"):eval("EC_"+cname+"_RENDPARAM"))}catch(e){}if(param!=null&&param!=""){url+="?";_pos1=0;_pos2=0;while((_pos1=param.indexOf("{@",_pos2))!=-1){_pos2=param.indexOf("}",_pos1);_clm=param.substring(_pos1+2,_pos2);if(_clm.indexOf(".")<0){_repClm="{@"+_clm+"}";_rep=suffix==""?$("#"+_clm).get(0).value:$("#"+_clm+suffix).get(0).value;_rep=(_rep==null?"":_rep);param=param.replace(_repClm,_rep);url+=_clm+"="+encodeURIComponent(_rep)+"&"}_pos2=_pos1+1}}noVal=function(){_firstOption=jCol.children("option").get(0);if(_firstOption==null||_firstOption.value!=""){return false}return true};columnFocus=function(){jCol.attr("isfocus","true")};if(cid!=null&&cid!=""){jCol=jTag.find("#"+cid)}else{jCol=new Array(0)}if(jCol.length>0&&isEndInitEvent()){jCol.bind("focus",columnFocus)}val="";if(jCol.length>0){if(isEndInitEvent()){val=(jCol.val()==null?"":jCol.val())}else{val=(jTag.attr("h_evVal")==null?"":jTag.attr("h_evVal"))}}renderer="";try{renderer=eval("EC_"+cname+"_RENDERER")}catch(e){}editor="";try{editor=eval("EC_"+cname+"_EDITOR")}catch(e){}ATTRS=["title","style","tabindex","readonly","disabled","onClick","onChange","onBlur","onFocus","ondblClick","onMouseDown","onMouseUp","onMouseMove","onMouseOut","onMouseOver","onSelect","onKeydown","onKeypress","onKeyup","eventCallBack","multiple"];optAttrs="";if(jCol.length>0){for(i=0;i<ATTRS.length;i++){optAtt=jCol.attr(ATTRS[i]);if(optAtt!=null){vtype=typeof(optAtt);isAdd=false;if(vtype=="function"){optAtt=optAtt.toString();isAdd=optAtt.length>0?true:false;optAtt="("+optAtt+")()"}else{if(vtype=="boolean"){isAdd=optAtt}else{isAdd=optAtt.length>0?true:false}}if(isAdd){optAttrs+=ATTRS[i]+"='"+optAtt+"' "}}}}$.ajax({url:url,data:{EC_CID:(cid==null?"":cid),EC_CNAME:(cname==null?"":cname),EC_RENDERER:renderer,EC_EDITOR:editor,EC_PARAM:param,EC_SQL:param,EC_WRITABLE:(writable==null?"":writable),EC_CVALUE:val,EC_NOVALUE:(jCol.length==0?"":noVal()),EC_CLASS:(jCol.length==0?"":jCol.attr("class")),EC_SIZE:(jCol.length==0?"":jCol.attr("size")),EC_MAXLENGTH:(jCol.length==0?"":jCol.attr("maxlength")),EC_OPTATTRS:optAttrs,EC_PNAME:jEvCol.attr("id")==null?"":jEvCol.attr("id").split("__")[0],EC_PVALUE:jEvCol.get(0).value==null?"":jEvCol.get(0).value,EC_USESLBL:(suffix==null||suffix=="")?"false":"true"},type:"POST",dataType:"html",async:isEndInitEvent(),error:function(r,s,e){if(url.indexOf(".htm")<0){alert("EventColumnError:"+r+":"+s+":"+e+":"+cname)}},success:function(data,status){var jNewCol=$(data);if(jCol.length>0){if(isEndInitEvent()){jCol.unbind("focus",columnFocus)}bindOldEvents(jNewCol.get(0),jQuery.data(jCol.clone(true).get(0),"events"))}jTag.empty().append(jNewCol);if(jCol.length>0){jTag.find("input,select,textarea").attr("name",cid).attr("id",cid);if(isEndInitEvent()){if(jCol.attr("isfocus")){jNewCol.get(0).focus();if($.browser.msie){jNewCol.get(0).focus()}}}if(!isEndInitEvent()){jNewCol.change()}if(jCol.attr("eventCallback")){callback=function(){eval(jCol.attr("eventCallback")+"(arguments);")};callback(cid,jNewCol.val(),jCol.get(0).value)}}if(suffix!=null&&suffix!=""){if(isEndInitEvent()){$("table#viewTable").resizeView()}}}})}function bindOldEvents(d,a){var c,b;for(c in a){for(b in a[c]){jQuery.event.add(d,c,a[c][b],a[c][b].data)}}}var isShowTip=false;$(function(){if(USE_REAL_TIME_CHECK){setEvent('textarea,select,input[type="text"]',"focusout",function(){var b=RegExp(/jsp/);var a=location.pathname.match(b);check(this,RegExp.leftContext+"jsp/common/realtimecheck.jsp")});$("table#viewTable").parent().parent().scroll(function(){if(isShowTip){isShowTip=false;$(".tipErr").remove()}})}});function check(f,b){var c,d,h,g,e,j,a,i;c=f.name;if(typeof jQuery!="undefined"&&c.indexOf("h_")!=0){d=f.value;if(f.rtOption!="null"&&f.rtOption!="undefined"){i=f.rtOption}h=c.split("__");g=(2==h.length);e="command=RENEW&checkType="+(g?"ENTRY":"NEW")+(g?"&h_rowSel="+h[1]:"")+"&column="+h[0]+"&"+c+"="+encodeURIComponent(d)+(i?"&"+i:"");j={dataType:"html",type:"POST",url:b,data:e};j.error=function(){};j.success=function(k){a=$(f).data("tipId");$("#"+a).remove();if($.trim(k).indexOf("row_error")>=0){showCheckTip(f,k);isShowTip=true}};$.ajax(j)}return true}function showCheckTip(a,c){var j,i,k,g,e,h,f,d,b;j=$(a);i=j.offset();if(i.top>=30){e="<div class='tipErr'><div id='tipArrowBottom'></div><div>"+c+"</div></div>";h=$(e).appendTo(document.body);f=i.left;d=i.top+(-11-h[0].offsetHeight)}else{e="<div class='tipErr'><div id='tipArrowTop'></div><div>"+c+"</div></div>";h=$(e).appendTo(document.body);f=i.left;d=i.top+11+h[0].offsetHeight}b=(new Date()).getTime();$(a).data("tipId",b);h.css({left:f+"px",top:d+"px"}).attr("id",b).click(function(){$(this).remove()}).show()}$(function(){bindEvents()});$.fn.simpleColorPickerOg=function(a){var c={colorsPerLine:8,colors:["#000000","#444444","#666666","#999999","#cccccc","#eeeeee","#f3f3f3","#ffffff","#ff0000","#ff9900","#ffff00","#00ff00","#00ffff","#0000ff","#9900ff","#ff00ff","#f4cccc","#fce5cd","#fff2cc","#d9ead3","#d0e0e3","#cfe2f3","#d9d2e9","#ead1dc","#ea9999","#f9cb9c","#ffe599","#b6d7a8","#a2c4c9","#9fc5e8","#b4a7d6","#d5a6bd","#e06666","#f6b26b","#ffd966","#93c47d","#76a5af","#6fa8dc","#8e7cc3","#c27ba0","#cc0000","#e69138","#f1c232","#6aa84f","#45818e","#3d85c6","#674ea7","#a64d79","#990000","#b45f06","#bf9000","#38761d","#134f5c","#0b5394","#351c75","#741b47","#660000","#783f04","#7f6000","#274e13","#0c343d","#073763","#20124d","#4C1130"],showEffect:"",hideEffect:"",onChangeColor:false};var b=$.extend(c,a);return this.each(function(){var g=$(this);var l="";var j=g.attr("id").replace(/-/g,"")+"_";for(var f=0;f<b.colors.length;f++){var m=b.colors[f];var k="";if(f%b.colorsPerLine==0){k="clear: both; "}if(f>0&&k&&$.browser&&$.browser.msie&&$.browser.version<=7){k="";l+='<li style="float: none; clear: both; overflow: hidden; background-color: #fff; display: block; height: 1px; line-height: 1px; font-size: 1px; margin-bottom: -2px;"></li>'}l+='<li id="'+j+"color-"+f+'" class="color-box" style="'+k+"background-color: "+m+'" title="'+m+'"></li>'}k="clear: both; ";l+='<li id="'+j+'color-default" class="color-box" style="width:80px; text-align:center; '+k+'background-color:white;" title="clear">clear</li>';var h=$('<div id="'+j+'color-picker" class="color-picker" style="position: absolute; left: 0px; top: 0px;"><ul>'+l+'</ul><div style="clear: both;"></div></div>');$("body").append(h);h.hide();h.find("li.color-box").click(function(){var i=isNaN(this.id.substr(this.id.indexOf("-")+1))?"":b.colors[this.id.substr(this.id.indexOf("-")+1)];if(!g.is("input")){g.val(i);g.blur()}if($.isFunction(c.onChangeColor)){c.onChangeColor.call(g,i)}d(h)});$("body").live("click",function(){d(h)});h.click(function(i){i.stopPropagation()});var e=function(i){var p=g.offset();var o=p.left+g.outerWidth()-i.outerWidth();if(o<p.left){o=p.left}i.css({left:o,top:(p.top+g.outerHeight())});n(i)};g.click(function(i){g=$(this);i.stopPropagation();if(!g.is("input")){e(h)}});g.change(function(i){if(g.val()!=g.css("background-color")){g.css("background-color",g.val()).css("color",g.val())}});g.focus(function(){e(h)});function d(i){if(b.hideEffect=="fade"){i.fadeOut()}else{if(b.hideEffect=="slide"){i.slideUp()}else{i.hide()}}}function n(i){if(b.showEffect=="fade"){i.fadeIn()}else{if(b.showEffect=="slide"){i.slideDown()}else{i.show()}}}})};$(function(){if($.fn.simpleColorPickerOg){$("input.colorPicker").simpleColorPickerOg({onChangeColor:function(a){$(this).val(a).css("background-color",a).css("color",a).change()}})}});jQuery.fn.ogClockpicker=function(options,callback){var org_settings={starthour:6,endhour:20,showminutes:"true",minutedivisions:4,military:true,event:"click",layout:"vertical",valuefield:null,useBgiframe:false,hoursopacity:1,minutesopacity:1,second:""};if(options){jQuery.extend(org_settings,options)}var callback=callback||function(){},v=(org_settings.layout=="vertical");errorcheck(org_settings);jQuery(this)[org_settings.event](function(e){var self=this,$self=jQuery(this),$body=jQuery("body");var settings=jQuery.extend(true,{},org_settings);if($self.attr("valuefield")){settings.valuefield=$self.attr("valuefield")}if($self.attr("starthour")){settings.starthour=$self.attr("starthour")}if($self.attr("endhour")){settings.endhour=$self.attr("endhour")}if($self.attr("minutedivisions")){settings.minutedivisions=$self.attr("minutedivisions")}if($self.attr("military")){settings.military=$self.attr("military")}if($self.attr("showminutes")){settings.showminutes=$self.attr("showminutes")}if($self.attr("usesecond")=="true"){settings.second="00"}errorcheck(settings);if(!settings.valuefield){$self.unbind("keydown").bind("keydown",keyhandler)}else{var inputfield=jQuery("[name="+settings.valuefield+"]");inputfield.unbind("keydown").bind("keydown",keyhandler)[0].focus();inputfield.bind("click",function(){inputfield.unbind("keydown")})}jQuery("#CP_hourcont,#CP_minutecont").remove();var $hourcont=jQuery("<div id='CP_hourcont' class='CP' />").appendTo($body);!settings.useBgiframe?$hourcont.css("opacity",settings.hoursopacity):null;binder($hourcont);var $hourcol1=jQuery("<div class='CP_hourcol' id='hourcol1' />").appendTo($body);var $hourcol2=jQuery("<div class='CP_hourcol' id='hourcol2' />").appendTo($body);if(settings.showminutes=="true"){var $mc=jQuery("<div id='CP_minutecont' class='CP' />").appendTo($body);!settings.useBgiframe?$mc.css("opacity",settings.minutesopacity):null;binder($mc)}if(!v){$hourcont.css("width","auto");if(settings.showminutes=="true"){$mc.css("width","auto")}}else{$hourcol1.addClass("floatleft");$hourcol2.addClass("floatleft")}renderhours();putcontainer();function renderhours(){var c=1;for(var h=settings.starthour;h<=settings.endhour;h++){if(h==12){c=1}var displayhours=((!settings.military&&h>12)?h-12:h);var valuehouers=h;if(!settings.military&&h==0){}else{if(!settings.military&&h==12){displayhours="0"}}if(settings.military&&h<10){displayhours="0"+displayhours}if(h<10){valuehouers="0"+valuehouers}var $hd=jQuery("<div class='CP_hour' id='hr_"+h+"_"+c+"' value='"+valuehouers+"' >"+displayhours+set_tt(h)+"</div>");if(settings.military){$hd.width(20)}binder($hd);if(!v){$hd.css("float","left")}(h<12)?$hourcol1.append($hd):$hourcol2.append($hd);c++}$hourcont.append($hourcol1);!v?$hourcont.append("<div style='clear:left' />"):"";$hourcont.append($hourcol2)}function renderminutes(h){var realhours=h;var displayhours=(!settings.military&&h>12)?h-12:h;var valuehouers=h;if(!settings.military&&h==0){}else{if(!settings.military&&h==12){displayhours="0"}}if(settings.military&&h<10){displayhours="0"+displayhours}if(h<10){valuehouers="0"+valuehouers}$mc.empty();var n=60/settings.minutedivisions,tt=set_tt(realhours),counter=1;for(var m=0;m<60;m=m+n){$md=jQuery("<div class='CP_minute' id='"+realhours+"_"+m+"' value='"+valuehouers+((m<10)?"0":"")+m+"'>"+displayhours+":"+((m<10)?"0":"")+m+tt+"</div>");if(!v){$md.css("float","left");if(settings.minutedivisions>6&&counter==settings.minutedivisions/2+1){$mc.append("<div style='clear:left' />")}}$mc.append($md);binder($md);counter++}}function set_tt(realhours){if(!settings.military){return(realhours>=12)?" PM":" AM"}else{return""}}function putcontainer(){if(e.type!="focus"){$hourcont[0].style.left=e.pageX-5+"px";$hourcont[0].style.top=e.pageY-(Math.floor($hourcont.height()/2))+"px";rectify($hourcont)}else{$self.after($hourcont)}$hourcont.slideDown("fast");if(settings.useBgiframe){bgi($hourcont)}}function rectify($obj){var ph=document.documentElement.clientHeight?document.documentElement.clientHeight:document.body.clientHeight;var pw=document.documentElement.clientWidth?document.documentElement.clientWidth:document.body.clientWidth;var t=parseInt($obj[0].style.top);var l=parseInt($obj[0].style.left);var st=document.documentElement.scrollTop?document.documentElement.scrollTop:document.body.scrollTop;if(t<=st&&!$obj.is("#CP_minutecont")){$obj.css("top",st+10+"px")}else{if(t+$obj.height()-st>ph){$obj.css("top",st+ph-$obj.height()-10+"px")}}if(l<=0){$obj.css("left","10px")}}function bgi(ob){if(typeof jQuery.fn.bgIframe=="function"){ob.bgIframe()}else{alert("bgIframe plugin not loaded.")}}function binder($obj){if($obj.attr("id")=="CP_hourcont"){$obj.mouseout(function(e){hourcont_out(e)})}else{if($obj.attr("id")=="CP_minutecont"){$obj.mouseout(function(e){minutecont_out(e)})}else{if($obj.attr("class")=="CP_hour"){$obj.mouseover(function(e){hourdiv_over($obj,e)});$obj.mouseout(function(){hourdiv_out($obj)});$obj.click(function(){hourdiv_click($obj)})}else{if($obj.attr("class")=="CP_minute"){$obj.mouseover(function(){minutediv_over($obj)});$obj.mouseout(function(){minutediv_out($obj)});$obj.click(function(){minutediv_click($obj)})}}}}}function hourcont_out(e){try{var t=(e.toElement)?e.toElement:e.relatedTarget;if(!(jQuery(t).is("div[class^=CP], iframe"))){cleardivs()}}catch(e){cleardivs()}}function minutecont_out(e){try{var t=(e.toElement)?e.toElement:e.relatedTarget;if(!(jQuery(t).is("div[class^=CP], iframe"))){cleardivs()}}catch(e){cleardivs()}}function hourdiv_over($obj,e){var h=$obj.attr("id").split("_")[1],i=$obj.attr("id").split("_")[2],l,t;$obj.addClass("CP_over");if(settings.showminutes=="true"){$mc.hide();renderminutes(h);if(v){t=e.type=="mouseover"?e.pageY-15:$hourcont.offset().top+2+($obj.height()*i);if(h<12){l=$hourcont.offset().left-$mc.width()-2}else{l=$hourcont.offset().left+$hourcont.width()+2}}else{l=(e.type=="mouseover")?e.pageX-10:$hourcont.offset().left+($obj.width()-5)*i;if(h<12){t=$hourcont.offset().top-$mc.height()-2}else{t=$hourcont.offset().top+$hourcont.height()}}$mc.css("left",l+"px").css("top",t+"px");rectify($mc);$mc.show();if(settings.useBgiframe){bgi($mc)}}return false}function hourdiv_out($obj){$obj.removeClass("CP_over");return false}function hourdiv_click($obj){var h=$obj.attr("id").split("_")[1],tt=set_tt(h),str=$obj.attr("value");if(str.indexOf(" ")!=-1){var cleanstr=str.substring(0,str.indexOf(" "))}else{var cleanstr=str}$obj.text(cleanstr+"00"+settings.second);setval($obj);cleardivs()}function minutediv_over($obj){$obj.addClass("CP_over");return false}function minutediv_out($obj){$obj.removeClass("CP_over");return false}function minutediv_click($obj){$obj.text($obj.attr("value")+settings.second);setval($obj);cleardivs()}function setval($obj){if(!settings.valuefield){self.value=$obj.text()}else{jQuery("input[name="+settings.valuefield+"]").val($obj.text()).change()}callback.apply($self,[$obj.text()]);$self.unbind("keydown",keyhandler)}function cleardivs(){if(settings.showminutes=="true"){$mc.hide()}$hourcont.slideUp("fast");$self.unbind("keydown",keyhandler)}function keyhandler(e){var $obj=$("div.CP_over").size()?$("div.CP_over"):$("div.CP_hour:first"),divtype=$obj.is(".CP_hour")?"hour":"minute",hi=(divtype=="hour")?$obj[0].id.split("_")[2]:0,h=(divtype=="minute")?$obj[0].id.split("_")[0]:$obj[0].id.split("_")[1];if(divtype=="minute"){var curloc=h<12?"m1":"m2"}else{var curloc=h<12?"h1":"h2"}function divprev($obj){if($obj.prev().size()){eval(divtype+"div_out($obj)");eval(divtype+"div_over($obj.prev(), e)")}else{return false}}function divnext($obj){if($obj.next().size()){eval(divtype+"div_out($obj)");eval(divtype+"div_over($obj.next(), e)")}else{return false}}function hourtohour($obj){var ctx=h>=12?"#hourcol1":"#hourcol2";$newobj=jQuery(".CP_hour[id$=_"+hi+"]",ctx);if($newobj.size()){hourdiv_out($obj);hourdiv_over($newobj,e)}else{return false}}function hourtominute($obj){hourdiv_out($obj);minutediv_over($(".CP_minute:first"))}function minutetohour($obj){minutediv_out($obj);var ctx=h>=12?"#hourcol2":"#hourcol1";var $newobj=jQuery(".CP_hour[id^=hr_"+h+"]",ctx);hourdiv_over($newobj,e)}switch(e.keyCode){case 37:if(v){switch(curloc){case"m1":return false;break;case"m2":minutetohour($obj);break;case"h1":hourtominute($obj);break;case"h2":hourtohour($obj);break}}else{divprev($obj)}break;case 38:if(v){divprev($obj)}else{switch(curloc){case"m1":return false;break;case"m2":minutetohour($obj);break;case"h1":hourtominute($obj);break;case"h2":hourtohour($obj);break}}break;case 39:if(v){switch(curloc){case"m1":minutetohour($obj);break;case"m2":return false;break;case"h1":hourtohour($obj);break;case"h2":hourtominute($obj);break}}else{divnext($obj)}break;case 40:if(v){divnext($obj)}else{switch(curloc){case"m1":minutetohour($obj);break;case"m2":return false;break;case"h1":hourtohour($obj);break;case"h2":hourtominute($obj);break}}break;case 13:eval(divtype+"div_click($obj)");break;default:return true}return false}return false});function errorcheck(settings){if(settings.starthour>=settings.endhour){alert("Error - start hour must be less than end hour.");return false}else{if(60%settings.minutedivisions!=0){alert("Error - param minutedivisions must divide evenly into 60.");return false}}}return this};$(function(){if($.fn.ogClockpicker){$(document).ready(function(){$(".clockpick").ogClockpicker()})}});function likeComp(c){var b=c.substring(6);var d=$("#"+c).attr("aimaiType");var a=$("#"+b).val();a=a.replace(/^%+|%+$/g,"");if(a!=""){switch(d){case"1":a=a+"%";break;case"2":a="%"+a;break;case"3":a="%"+a+"%";break}}$("#"+b).val(a)}$(function(){$("form").submit(function(){$("[id^='AIMAI_']").each(function(){likeComp(this.id)})})});$.fn.aimaiPickerOg=function(a){var c={texts:[" V "," V*","*V ","*V*"],titls:["完全一致","前方一致","後方一致","前後曖昧"]};var b=$.extend(c,a);return this.each(function(){var g=$(this);var j="PIC_"+g.attr("id").replace(/-/g,"")+"_";var l="";for(var f=0;f<b.texts.length;f++){var m=b.texts[f];var k=b.titls[f];l+='<span id="'+j+"text-"+f+'" class="text-box"" title="'+k+'">('+m+") </span>"}var h=$('<div id="'+j+'aimai-picker" class="aimai-picker" style="position: absolute; left: 0px; top: 0px;">'+l+'<div style="clear: both;"></div></div>');$("body").append(h);h.hide();h.find("span.text-box").click(function(){var i=this.id.substr(this.id.indexOf("-")+1);g.attr("aimaiType",i);g.attr("title",b.titls[i]);g.text(b.texts[i]);g.blur();d(h)});$("body").live("click",function(){d(h)});h.click(function(i){i.stopPropagation()});var e=function(i){var p=g.offset();var o=p.left+g.outerWidth()-i.outerWidth();if(o<p.left){o=p.left}i.css({left:o,top:(p.top+g.outerHeight())});n(i)};g.click(function(i){i.stopPropagation();if(!g.is("input")){e(h)}});g.focus(function(){e(h)});function d(i){if(b.hideEffect=="fade"){i.fadeOut()}else{if(b.hideEffect=="slide"){i.slideUp()}else{i.hide()}}}function n(i){if(b.showEffect=="fade"){i.fadeIn()}else{if(b.showEffect=="slide"){i.slideDown()}else{i.show()}}}})};$(function(){if($.fn.aimaiPickerOg){$(".aimaiClm").aimaiPickerOg()}});(function(){$.fn.glDatePicker=function(options){var pluginName="glDatePicker";var instance=this.data(pluginName);if(!instance){return this.each(function(){return $(this).data(pluginName,new glDatePicker(this,options))})}return(options===true)?instance:this};$.fn.glDatePicker.defaults={cssName:"default",zIndex:1000,borderSize:1,calendarOffset:{x:0,y:1},showAlways:false,hideOnClick:true,allowMonthSelect:true,allowYearSelect:true,todayDate:new Date(),selectedDate:null,prevArrow:"\u25c4",nextArrow:"\u25ba",selectableDates:null,selectableDateRange:null,specialDates:null,selectableMonths:null,selectableYears:null,selectableDOW:null,monthNames:null,dowNames:null,dowOffset:(HYBS_CAL_START_MON==true?1:0),onClick:(function(el,cell,date,data){var tgt=el;if(el[0].tagName.toUpperCase()!="INPUT"){var _targetId=el.attr("targetId");if(_targetId!=null){tgt=$("#"+_targetId)}}var year=date.getFullYear();var month=date.getMonth()+1;var day=date.getDate();if(month<10){month="0"+month}if(day<10){day="0"+day}var str=year+""+month+""+day;tgt.val(str)}),onHover:function(el,cell,date,data){},onShow:function(calendar){calendar.show()},onHide:function(calendar){calendar.hide()},firstDate:null};var glDatePicker=(function(){function glDatePicker(element,userOptions){var self=this;self.el=$(element);var el=self.el;self.options=$.extend(true,{},$.fn.glDatePicker.defaults,userOptions);var options=self.options;self.calendar=$($.find("[gldp-el="+el.attr("gldp-id")+" ]"));options.selectedDate=options.selectedDate||options.todayDate;options.firstDate=(new Date((options.firstDate||options.selectedDate)))._first();if(!(el.attr("gldp-id")||"").length){el.attr("gldp-id","gldp-"+Math.round(Math.random()*10000000000))}el.addClass("gldp-el").bind("click",function(e){self.show(e)});if(self.calendar.length&&!options.showAlways){self.calendar.hide()}$(document).bind("mouseup",function(e){var target=e.target;var calendar=self.calendar;if(!el.is(target)&&!calendar.is(target)&&calendar.has(target).length===0&&calendar.is(":visible")){self.hide()}})}glDatePicker.prototype={show:function(){this.render();$.each($(".gldp-el").not(this.el),function(i,o){if(o.length){o.options.onHide(o.calendar)}});this.options.onShow(this.calendar)},hide:function(){if(this.options&&!this.options.showAlways){this.options.onHide(this.calendar)}},render:function(renderCalback){var self=this;var el=self.el;var options=self.options;var calendar=self.calendar;var coreClass=" core border ";var cssName="gldp-"+options.cssName;var todayVal=options.todayDate._val();var todayTime=todayVal.time;var maxRow=6;var maxCol=7;var borderSize=options.borderSize+"px";var getSelectableList=function(min,max,userList){var resultList=[];for(var i=min;i<=max;i++){resultList.push(i)}if(userList){var newList=[];$.each(userList,function(i,v){if(v>=min&&v<=max&&newList._indexOf(v)<0){newList.push(v)}});resultList=newList.length?newList:resultList}resultList.sort();return resultList};var selectableMonths=getSelectableList(0,11,options.selectableMonths);var selectableYears=getSelectableList(todayVal.year-5,todayVal.year+5,options.selectableYears);var selectableDOW=getSelectableList(0,6,options.selectableDOW);var dowNames=options.dowNames||["日","月","火","水","木","金","土"];var monthNames=options.monthNames||["1月","2月","3月","4月","5月","6月","7月","8月","9月","10月","11月","12月"];var containerSize=window.innerHeight?window.innerHeight:180;if(containerSize<180){containerSize=(containerSize>135?containerSize:135)}else{containerSize=180}var containerWidth=options.conainerWidth||containerSize;var containerHeight=containerWidth;var getCellSize=function(_size,_count){return(_size/_count)+((options.borderSize/_count)*(_count-1))-1};var cellWidth=getCellSize(containerWidth,maxCol);var cellHeight=getCellSize(containerHeight,maxRow+2);if(!calendar.length){self.calendar=calendar=$("<div/>").attr("gldp-el",el.attr("gldp-id")).data("is",true).css({display:(options.showAlways?undefined:"none"),zIndex:options.zIndex,width:((cellWidth+1)*maxCol)+"px"});$("body").append(calendar)}else{if(!eval(calendar.data("is"))){containerWidth=calendar.outerWidth();containerHeight=calendar.outerHeight();cellWidth=getCellSize(containerWidth,maxCol);cellHeight=getCellSize(containerHeight,maxRow+2)}self.calendar.css({width:((cellWidth+1)*maxCol)+"px"})}if(!el.is(":visible")){calendar.hide()}calendar.removeClass().addClass(cssName).children().remove();var onResize=function(){var elPos=el.offset();calPosTop=(elPos.top+el.outerHeight()+options.calendarOffset.y)-20;calPosLeft=(elPos.left+options.calendarOffset.x);if(calPosTop>$(window).height()-150){calPosTop-=130}if(calPosLeft>$(window).width()-150){calPosLeft-=150}if(calPosTop<0){calPosTop=0}if(calPosLeft<0){calPosLeft=0}calendar.css({top:calPosTop+"px",left:calPosLeft+"px"})};$(window).resize(onResize);onResize();var cellCSS={width:cellWidth+"px",height:cellHeight+"px",lineHeight:cellHeight+"px"};var setFirstDate=function(_date){if(_date){options.firstDate=_date;self.render()}};var getFirstDate=function(_offset){var _date=new Date(options.firstDate);_offset=_offset||0;while(true){_date.setMonth(_date.getMonth()+_offset);_date.setDate(Math.min(1,_date._max()));if(_offset==0){break}var dateVal=_date._val();var dateMonth=dateVal.month;var dateYear=dateVal.year;if(selectableMonths._indexOf(dateMonth)!=-1){if(selectableYears._indexOf(dateYear)!=-1){break}else{if(dateYear<selectableYears[0]||dateYear>selectableYears[selectableYears.length-1]){return null}}}}return _date};var prevFirstDate=getFirstDate(-1);var nextFirstDate=getFirstDate(1);var firstDate=(options.firstDate=getFirstDate());var firstDateVal=firstDate._val();var firstDateMonth=firstDateVal.month;var firstDateYear=firstDateVal.year;var startDate=new Date(firstDate);var dowOffset=Math.abs(Math.min(6,Math.max(0,options.dowOffset)));var startOffset=startDate.getDay()-dowOffset;startOffset=startOffset<1?-7-startOffset:-startOffset;dowNames=(dowNames.concat(dowNames)).slice(dowOffset,dowOffset+7);startDate._add(startOffset);var showPrev=(prevFirstDate);var showNext=(nextFirstDate);var monyearClass=coreClass+"monyear ";var prevCell=$("<div/>").addClass(monyearClass).css($.extend({},cellCSS,{borderWidth:borderSize+" 0 0 "+borderSize})).append($("<a/>").addClass("prev-arrow"+(showPrev?"":"-off")).html(options.prevArrow)).mousedown(function(){return false}).click(function(e){if(options.prevArrow!=""&&showPrev){e.stopPropagation();setFirstDate(prevFirstDate)}});var titleCellCount=maxCol-2;var titleWidth=(cellWidth*titleCellCount)-(titleCellCount*options.borderSize)+(options.borderSize);var titleCell=$("<div/>").addClass(monyearClass+"title").css($.extend({},cellCSS,{width:titleWidth+"px",borderTopWidth:borderSize,marginLeft:"-"+(borderSize)}));var nextCell=$("<div/>").addClass(monyearClass).css($.extend({},cellCSS,{marginLeft:"-"+(borderSize),borderWidth:borderSize+" "+borderSize+" 0 0"})).append($("<a/>").addClass("next-arrow"+(showNext?"":"-off")).html(options.nextArrow)).mousedown(function(){return false}).click(function(e){if(options.nextArrow!=""&&showNext){e.stopPropagation();setFirstDate(nextFirstDate)}});calendar.append(prevCell).append(titleCell).append(nextCell);for(var row=0,cellIndex=0;row<maxRow+1;row++){for(var col=0;col<maxCol;col++,cellIndex++){var cellDate=new Date(startDate);var cellClass="day";var cellZIndex=options.zIndex+(cellIndex);var cell=$("<div/>");if(!row){cellClass="dow";cell.html(dowNames[col]);cellDate=null}else{cellDate._add(col+((row-1)*maxCol));var cellDateVal=cellDate._val();var cellDateTime=cellDateVal.time;var specialData=null;var isSelectable=true;var getRepeatDate=function(v,date){if(v.repeatYear===true){date.setYear(cellDateVal.year)}if(v.repeatMonth===true){date.setMonth(cellDateVal.month)}return date._val()};cell.html(cellDateVal.date);if(options.selectableDateRange){isSelectable=false;$.each(options.selectableDateRange,function(i,v){var dateFrom=v.from;var dateTo=(v.to||null);dateTo=dateTo||new Date(v.from.getFullYear(),v.from.getMonth(),v.from._max());dateFrom=getRepeatDate(v,dateFrom);dateTo=getRepeatDate(v,dateTo);if(cellDateTime>=dateFrom.time&&cellDateTime<=dateTo.time){isSelectable=true;return true}})}if(options.selectableDates){if((options.selectableDateRange&&!isSelectable)||(isSelectable&&!options.selectableDateRange)){isSelectable=false}$.each(options.selectableDates,function(i,v){var vDate=getRepeatDate(v,v.date);if(vDate.time==cellDateTime){return(isSelectable=true)}})}if(!isSelectable||selectableYears._indexOf(cellDateVal.year)<0||selectableMonths._indexOf(cellDateVal.month)<0||selectableDOW._indexOf(cellDateVal.day)<0){cellClass="noday"}else{cellClass=(["sun","mon","tue","wed","thu","fri","sat"])[cellDateVal.day];if(firstDateMonth!=cellDateVal.month){cellClass+=" outday"}if(todayTime==cellDateTime){cellClass="today";cellZIndex+=50}if(options.selectedDate._time()==cellDateTime){cellClass="selected";cellZIndex+=51}if(options.specialDates){$.each(options.specialDates,function(i,v){var vDate=getRepeatDate(v,v.date);if(vDate.time==cellDateTime){cellClass=(v.cssClass||"special");cellZIndex+=52;specialData=v.data}})}cell.mousedown(function(){return false}).hover(function(e){e.stopPropagation();var hoverData=$(this).data("data");options.onHover(el,cell,hoverData.date,hoverData.data)}).click(function(e){e.stopPropagation();var clickedData=$(this).data("data");options.selectedDate=options.firstDate=clickedData.date;self.render(function(){if(!options.showAlways&&options.hideOnClick){self.hide()}});options.onClick(el,$(this),clickedData.date,clickedData.data)})}}$.extend(cellCSS,{borderTopWidth:borderSize,borderBottomWidth:borderSize,borderLeftWidth:(row>0||(!row&&!col))?borderSize:0,borderRightWidth:(row>0||(!row&&col==6))?borderSize:0,marginLeft:(col>0)?"-"+(borderSize):0,marginTop:(row>0)?"-"+(borderSize):0,zIndex:cellZIndex});cell.data("data",{date:cellDate,data:specialData}).addClass(coreClass+cellClass).css(cellCSS);calendar.append(cell)}}var toggleYearMonthSelect=function(showYear){var show="inline-block";var hide="none";if(options.allowMonthSelect){monthText.css({display:!showYear?hide:show});monthSelect.css({display:!showYear?show:hide})}if(options.allowYearSelect){yearText.css({display:showYear?hide:show});yearSelect.css({display:showYear?show:hide})}};var onYearMonthSelect=function(){options.firstDate=new Date(yearSelect.val(),monthSelect.val(),1);self.render()};var monthSelect=$("<select/>").hide().change(onYearMonthSelect);var yearSelect=$("<select/>").hide().change(onYearMonthSelect);var monthText=$("<span/>").html(monthNames[firstDateMonth]).mousedown(function(){return false}).click(function(e){e.stopPropagation();toggleYearMonthSelect(false)});var yearText=$("<span/>").html(firstDateYear).mousedown(function(){return false}).click(function(e){e.stopPropagation();toggleYearMonthSelect(true)});$.each(monthNames,function(i,v){if(options.allowMonthSelect&&selectableMonths._indexOf(i)!=-1){var o=$("<option/>").html(v).attr("value",i);if(i==firstDateMonth){o.attr("selected","selected")}monthSelect.append(o)}});$.each(selectableYears,function(i,v){if(options.allowYearSelect){var o=$("<option/>").html(v).attr("value",v);if(v==firstDateYear){o.attr("selected","selected")}yearSelect.append(o)}});var titleYearMonth=$("<div/>").append(monthText).append(monthSelect).append(yearText).append(yearSelect);titleCell.children().remove();titleCell.append(titleYearMonth);renderCalback=renderCalback||(function(){});renderCalback();var mousewheelevent="onwheel" in document?"wheel":"onmousewheel" in document?"mousewheel":"DOMMouseScroll";calendar.bind(mousewheelevent,function(e){e.preventDefault();var delta=e.originalEvent.deltaY?-(e.originalEvent.deltaY):e.originalEvent.wheelDelta?e.originalEvent.wheelDelta:-(e.originalEvent.detail);if(delta<0){nextCell.click()}else{prevCell.click()}})}};return glDatePicker})();(function(){Date.prototype._clear=function(){this.setHours(0);this.setMinutes(0);this.setSeconds(0);this.setMilliseconds(0);return this};Date.prototype._time=function(){return this._clear().getTime()};Date.prototype._max=function(){var isLeapYear=(new Date(this.getYear(),1,29).getMonth()==1)?1:0;var days=[31,28+isLeapYear,31,30,31,30,31,31,30,31,30,31];return days[this.getMonth()]};Date.prototype._add=function(days){this.setDate(this.getDate()+days)};Date.prototype._first=function(){var date=new Date(this);date.setDate(1);return date};Date.prototype._val=function(){this._clear();return{year:this.getFullYear(),month:this.getMonth(),date:this.getDate(),time:this.getTime(),day:this.getDay()}};Array.prototype._indexOf=function(value){return $.inArray(value,this)}})()})();$(function(){if($.fn.glDatePicker){$(".calPic").glDatePicker()}});function selectScroll(a){var d=4;if(a.getAttribute("size")){d=a.getAttribute("size")}var e=a.options;for(var c=0;c<e.length;c++){if(e[c].selected){if(e[c].parentNode.tagName.toUpperCase()=="OPTGROUP"){c+=$(e[c].parentNode).prev().length}var b=c*($(a).height()/d);break}}$(a).scrollTop(b)}$(function(){$("select[multiple]").each(function(){selectScroll(this)})});
\ No newline at end of file
1+var orgFldCls=null;$(function(){if(USE_FOCUS_HILIGHT){setEvent('textarea,select,input[type="text"]',"focusin",function(){doFocus2(this)});setEvent('textarea,select,input[type="text"]',"focusout",function(){doBlur2(this)})}});function doFocus2(a){if(a!=null){if(a.className==null||a.className.indexOf("must")<0){if(a.tagName=="SELECT"){a.orgBgColor=a.style.backgroundColor;a.style.backgroundColor="#ffcccc"}else{orgFldCls=a.className;a.className="focusField "+orgFldCls}}}}function doBlur2(a){if(a!=null){if(a.className==null||a.className.indexOf("must")<0){if(a.tagName=="SELECT"){a.style.backgroundColor=a.orgBgColor}else{if(orgFldCls!=null){a.className=orgFldCls}else{a.className="notFocusField"}}}}}oldDoFocusFlag=true;function doFocus(a){if(oldDoFocusFlag){oldDoFocusFlag=false;setTimeout(alert("Old Script Error!!\ncustom/query_info.jsp,custom/result_info.jsp Please delete the following part.\n<script>Tag(Header fix and Focus) , BODY onLoad and oncontextmenu Attribute"),100)}}function doBlur(a){}$(function(){setEvent('textarea,select,input[type="text"]',"focusout",function(){convert(this)})});function convert(b){var c,a;c=b.value;a=b.className;if(c!=null&&a!=null){if(a.match(/XL/)&&!(a.match(/XLU/))){b.value=c.toLowerCase()}else{if((a.match(/XU/)&&!(a.match(/XUL/)))||a.match(/PN2/)){b.value=c.toUpperCase()}}}return true}var colMap;var notFireCols;var jH_evElm;$(function(){if(!(typeof(EC_NAME)=="undefined")){jH_evElm=$(".h_evElm");makeColMapping();setEvent('textarea,select,input[type="text"]',"change",function(){makeColumn(this)},".h_evCol",true,addEvColCls);setEvent("input[type=checkbox],input[type=radio]","click",function(){makeColumn(this)},".h_evCol",true)}});function makeColMapping(){var b,a,e,d,c;if(colMap){return}colMap=new Object();for(b=0;b<EC_EVCOL.length;b++){e=EC_EVCOL[b].split(",");for(a=0;a<e.length;a++){d=e[a];if(d.charAt(0)=="_"){d=d.substring(1);if(notFireCols){notFireCols+=","}notFireCols+=d}c=colMap[d];if(!c){c=new Array()}c[c.length]=EC_NAME[b];colMap[d]=c}}}function addEvColCls(){for(var a in colMap){$("#"+a+",[id^="+a+"__]").addClass("h_evCol")}}function makeColumn(e){var k,l,g,j,b,h,d,c,a,f;if(jH_evElm&&isEndInitEvent()){jH_evElm=null}k=$(e);l=k.attr("id");g=l.split("__")[0];j=colMap[g];if(!j){return}if(!isEndInitEvent()&&notFireCols&&notFireCols.indexOf(g)>=0){return}for(b=0;b<j.length;b++){h=(l==g?"":"__"+l.split("__")[1]);d=j[b]+h;c=d.split("__")[0];a=isEndInitEvent()?$(".h_evElm[h_evCid="+d+"]"):jH_evElm.filter("[h_evCid="+d+"]");f=a.attr("h_evWrtbl");eventColumn(k,a,d,c,h,f)}}function eventColumn(jEvCol,jTag,cid,cname,suffix,writable){var evVal,url,param,_pos1,_pos2,_repClm,_rep,_clm,noVal,columnFocus,jCol,val,renderer,editor,ATTRS,optAttrs,i,optAtt,vtype,isAdd;var callback;if(!jTag||jTag.length==0){alert("[SYSTEM_ERROR] : jTag is null. The element of the replacement object doesn't exist. ["+cname+"]");return}if(!isEndInitEvent()){evVal=jEvCol.get(0).value;if(!evVal||evVal==null||evVal==""){return}}try{url=eval("EC_"+cname+"_URL")}catch(e){alert("[SYSTEM_ERROR] : URL that processes the event is not specified. (variable undefinition). ["+cname+"]");return}if(!url||url==""){alert("[SYSTEM_ERROR] : URL that processes the event is not specified. ["+cname+"]");return}param="";try{param=(writable?eval("EC_"+cname+"_EDITPARAM"):eval("EC_"+cname+"_RENDPARAM"))}catch(e){}if(param!=null&&param!=""){url+="?";_pos1=0;_pos2=0;while((_pos1=param.indexOf("{@",_pos2))!=-1){_pos2=param.indexOf("}",_pos1);_clm=param.substring(_pos1+2,_pos2);if(_clm.indexOf(".")<0){_repClm="{@"+_clm+"}";_rep=suffix==""?$("#"+_clm).get(0).value:$("#"+_clm+suffix).get(0).value;_rep=(_rep==null?"":_rep);param=param.replace(_repClm,_rep);url+=_clm+"="+encodeURIComponent(_rep)+"&"}_pos2=_pos1+1}}noVal=function(){_firstOption=jCol.children("option").get(0);if(_firstOption==null||_firstOption.value!=""){return false}return true};columnFocus=function(){jCol.attr("isfocus","true")};if(cid!=null&&cid!=""){jCol=jTag.find("#"+cid)}else{jCol=new Array(0)}if(jCol.length>0&&isEndInitEvent()){jCol.bind("focus",columnFocus)}val="";if(jCol.length>0){if(isEndInitEvent()){val=(jCol.val()==null?"":jCol.val())}else{val=(jTag.attr("h_evVal")==null?"":jTag.attr("h_evVal"))}}renderer="";try{renderer=eval("EC_"+cname+"_RENDERER")}catch(e){}editor="";try{editor=eval("EC_"+cname+"_EDITOR")}catch(e){}ATTRS=["title","style","tabindex","readonly","disabled","onClick","onChange","onBlur","onFocus","ondblClick","onMouseDown","onMouseUp","onMouseMove","onMouseOut","onMouseOver","onSelect","onKeydown","onKeypress","onKeyup","eventCallBack","multiple"];optAttrs="";if(jCol.length>0){for(i=0;i<ATTRS.length;i++){optAtt=jCol.attr(ATTRS[i]);if(optAtt!=null){vtype=typeof(optAtt);isAdd=false;if(vtype=="function"){optAtt=optAtt.toString();isAdd=optAtt.length>0?true:false;optAtt="("+optAtt+")()"}else{if(vtype=="boolean"){isAdd=optAtt}else{isAdd=optAtt.length>0?true:false}}if(isAdd){optAttrs+=ATTRS[i]+"='"+optAtt+"' "}}}}$.ajax({url:url,data:{EC_CID:(cid==null?"":cid),EC_CNAME:(cname==null?"":cname),EC_RENDERER:renderer,EC_EDITOR:editor,EC_PARAM:param,EC_SQL:param,EC_WRITABLE:(writable==null?"":writable),EC_CVALUE:val,EC_NOVALUE:(jCol.length==0?"":noVal()),EC_CLASS:(jCol.length==0?"":jCol.attr("class")),EC_SIZE:(jCol.length==0?"":jCol.attr("size")),EC_MAXLENGTH:(jCol.length==0?"":jCol.attr("maxlength")),EC_OPTATTRS:optAttrs,EC_PNAME:jEvCol.attr("id")==null?"":jEvCol.attr("id").split("__")[0],EC_PVALUE:jEvCol.get(0).value==null?"":jEvCol.get(0).value,EC_USESLBL:(suffix==null||suffix=="")?"false":"true"},type:"POST",dataType:"html",async:isEndInitEvent(),error:function(r,s,e){if(url.indexOf(".htm")<0){alert("EventColumnError:"+r+":"+s+":"+e+":"+cname)}},success:function(data,status){var jNewCol=$(data);if(jCol.length>0){if(isEndInitEvent()){jCol.unbind("focus",columnFocus)}bindOldEvents(jNewCol.get(0),jQuery.data(jCol.clone(true).get(0),"events"))}jTag.empty().append(jNewCol);if(jCol.length>0){jTag.find("input,select,textarea").attr("name",cid).attr("id",cid);if(isEndInitEvent()){if(jCol.attr("isfocus")){jNewCol.get(0).focus();if($.browser.msie){jNewCol.get(0).focus()}}}if(!isEndInitEvent()){jNewCol.change()}if(jCol.attr("eventCallback")){callback=function(){eval(jCol.attr("eventCallback")+"(arguments);")};callback(cid,jNewCol.val(),jCol.get(0).value)}}if(suffix!=null&&suffix!=""){if(isEndInitEvent()){$("table#viewTable").resizeView()}}}})}function bindOldEvents(d,a){var c,b;for(c in a){for(b in a[c]){jQuery.event.add(d,c,a[c][b],a[c][b].data)}}}var isShowTip=false;$(function(){if(USE_REAL_TIME_CHECK){setEvent('textarea,select,input[type="text"]',"focusout",function(){var b=RegExp(/jsp/);var a=location.pathname.match(b);check(this,RegExp.leftContext+"jsp/common/realtimecheck.jsp")});$("table#viewTable").parent().parent().scroll(function(){if(isShowTip){isShowTip=false;$(".tipErr").remove()}})}});function check(f,b){var c,d,h,g,e,j,a,i;c=f.name;if(typeof jQuery!="undefined"&&c.indexOf("h_")!=0){d=f.value;if(f.rtOption!="null"&&f.rtOption!="undefined"){i=f.rtOption}h=c.split("__");g=(2==h.length);e="command=RENEW&checkType="+(g?"ENTRY":"NEW")+(g?"&h_rowSel="+h[1]:"")+"&column="+h[0]+"&"+c+"="+encodeURIComponent(d)+(i?"&"+i:"");j={dataType:"html",type:"POST",url:b,data:e};j.error=function(){};j.success=function(k){a=$(f).data("tipId");$("#"+a).remove();if($.trim(k).indexOf("row_error")>=0){showCheckTip(f,k);isShowTip=true}};$.ajax(j)}return true}function showCheckTip(a,c){var j,i,k,g,e,h,f,d,b;j=$(a);i=j.offset();if(i.top>=30){e="<div class='tipErr'><div id='tipArrowBottom'></div><div>"+c+"</div></div>";h=$(e).appendTo(document.body);f=i.left;d=i.top+(-11-h[0].offsetHeight)}else{e="<div class='tipErr'><div id='tipArrowTop'></div><div>"+c+"</div></div>";h=$(e).appendTo(document.body);f=i.left;d=i.top+11+h[0].offsetHeight}b=(new Date()).getTime();$(a).data("tipId",b);h.css({left:f+"px",top:d+"px"}).attr("id",b).click(function(){$(this).remove()}).show()}$(function(){bindEvents()});$.fn.simpleColorPickerOg=function(a){var c={colorsPerLine:8,colors:["#000000","#444444","#666666","#999999","#cccccc","#eeeeee","#f3f3f3","#ffffff","#ff0000","#ff9900","#ffff00","#00ff00","#00ffff","#0000ff","#9900ff","#ff00ff","#f4cccc","#fce5cd","#fff2cc","#d9ead3","#d0e0e3","#cfe2f3","#d9d2e9","#ead1dc","#ea9999","#f9cb9c","#ffe599","#b6d7a8","#a2c4c9","#9fc5e8","#b4a7d6","#d5a6bd","#e06666","#f6b26b","#ffd966","#93c47d","#76a5af","#6fa8dc","#8e7cc3","#c27ba0","#cc0000","#e69138","#f1c232","#6aa84f","#45818e","#3d85c6","#674ea7","#a64d79","#990000","#b45f06","#bf9000","#38761d","#134f5c","#0b5394","#351c75","#741b47","#660000","#783f04","#7f6000","#274e13","#0c343d","#073763","#20124d","#4C1130"],showEffect:"",hideEffect:"",onChangeColor:false};var b=$.extend(c,a);return this.each(function(){var g=$(this);var l="";var j=g.attr("id").replace(/-/g,"")+"_";for(var f=0;f<b.colors.length;f++){var m=b.colors[f];var k="";if(f%b.colorsPerLine==0){k="clear: both; "}if(f>0&&k&&$.browser&&$.browser.msie&&$.browser.version<=7){k="";l+='<li style="float: none; clear: both; overflow: hidden; background-color: #fff; display: block; height: 1px; line-height: 1px; font-size: 1px; margin-bottom: -2px;"></li>'}l+='<li id="'+j+"color-"+f+'" class="color-box" style="'+k+"background-color: "+m+'" title="'+m+'"></li>'}k="clear: both; ";l+='<li id="'+j+'color-default" class="color-box" style="width:80px; text-align:center; '+k+'background-color:white;" title="clear">clear</li>';var h=$('<div id="'+j+'color-picker" class="color-picker" style="position: absolute; left: 0px; top: 0px;"><ul>'+l+'</ul><div style="clear: both;"></div></div>');$("body").append(h);h.hide();h.find("li.color-box").click(function(){var i=isNaN(this.id.substr(this.id.indexOf("-")+1))?"":b.colors[this.id.substr(this.id.indexOf("-")+1)];if(!g.is("input")){g.val(i);g.blur()}if($.isFunction(c.onChangeColor)){c.onChangeColor.call(g,i)}d(h)});$("body").live("click",function(){d(h)});h.click(function(i){i.stopPropagation()});var e=function(i){var p=g.offset();var o=p.left+g.outerWidth()-i.outerWidth();if(o<p.left){o=p.left}i.css({left:o,top:(p.top+g.outerHeight())});n(i)};g.click(function(i){g=$(this);i.stopPropagation();if(!g.is("input")){e(h)}});g.change(function(i){if(g.val()!=g.css("background-color")){g.css("background-color",g.val()).css("color",g.val())}});g.focus(function(){e(h)});function d(i){if(b.hideEffect=="fade"){i.fadeOut()}else{if(b.hideEffect=="slide"){i.slideUp()}else{i.hide()}}}function n(i){if(b.showEffect=="fade"){i.fadeIn()}else{if(b.showEffect=="slide"){i.slideDown()}else{i.show()}}}})};$(function(){if($.fn.simpleColorPickerOg){$("input.colorPicker").simpleColorPickerOg({onChangeColor:function(a){$(this).val(a).css("background-color",a).css("color",a).change()}})}});jQuery.fn.ogClockpicker=function(options,callback){var org_settings={starthour:6,endhour:20,showminutes:"true",minutedivisions:4,military:true,event:"click",layout:"vertical",valuefield:null,useBgiframe:false,hoursopacity:1,minutesopacity:1,second:""};if(options){jQuery.extend(org_settings,options)}var callback=callback||function(){},v=(org_settings.layout=="vertical");errorcheck(org_settings);jQuery(this)[org_settings.event](function(e){var self=this,$self=jQuery(this),$body=jQuery("body");var settings=jQuery.extend(true,{},org_settings);if($self.attr("valuefield")){settings.valuefield=$self.attr("valuefield")}if($self.attr("starthour")){settings.starthour=parseInt($self.attr("starthour"))}if($self.attr("endhour")){settings.endhour=parseInt($self.attr("endhour"))}if($self.attr("minutedivisions")){settings.minutedivisions=parseInt($self.attr("minutedivisions"))}if($self.attr("military")){settings.military=$self.attr("military")}if($self.attr("showminutes")){settings.showminutes=$self.attr("showminutes")}if($self.attr("usesecond")=="true"){settings.second="00"}if($self.attr("layout")){settings.layout=$self.attr("layout");org_settings.layout=settings.layout;v=(settings.layout=="vertical")}errorcheck(settings);if(!settings.valuefield){$self.unbind("keydown").bind("keydown",keyhandler)}else{var inputfield=jQuery("[name="+settings.valuefield+"]");inputfield.unbind("keydown").bind("keydown",keyhandler)[0].focus();inputfield.bind("click",function(){inputfield.unbind("keydown")})}jQuery("#CP_hourcont,#CP_minutecont").remove();var $hourcont=jQuery("<div id='CP_hourcont' class='CP' />").appendTo($body);!settings.useBgiframe?$hourcont.css("opacity",settings.hoursopacity):null;binder($hourcont);var $hourcol1=jQuery("<div class='CP_hourcol' id='hourcol1' />").appendTo($body);var $hourcol2=jQuery("<div class='CP_hourcol' id='hourcol2' />").appendTo($body);if(settings.showminutes=="true"){var $mc=jQuery("<div id='CP_minutecont' class='CP' />").appendTo($body);!settings.useBgiframe?$mc.css("opacity",settings.minutesopacity):null;binder($mc)}if(!v){$hourcont.css("width","auto");if(settings.showminutes=="true"){$mc.css("width","auto")}}else{$hourcol1.addClass("floatleft");$hourcol2.addClass("floatleft")}renderhours();putcontainer();function renderhours(){var c=1;for(var h=settings.starthour;h<=settings.endhour;h++){if(h==12){c=1}var displayhours=((!settings.military&&h>12)?h-12:h);var valuehouers=h;if(!settings.military&&h==0){}else{if(!settings.military&&h==12){displayhours="0"}}if(settings.military&&h<10){displayhours="0"+displayhours}if(h<10){valuehouers="0"+valuehouers}var $hd=jQuery("<div class='CP_hour' id='hr_"+h+"_"+c+"' value='"+valuehouers+"' >"+displayhours+set_tt(h)+"</div>");if(settings.military){$hd.width(20)}binder($hd);if(!v){$hd.css("float","left")}(h<12)?$hourcol1.append($hd):$hourcol2.append($hd);c++}$hourcont.append($hourcol1);!v?$hourcont.append("<div style='clear:left' />"):"";$hourcont.append($hourcol2)}function renderminutes(h){var realhours=h;var displayhours=(!settings.military&&h>12)?h-12:h;var valuehouers=h;if(!settings.military&&h==0){}else{if(!settings.military&&h==12){displayhours="0"}}if(settings.military&&h<10){displayhours="0"+displayhours}if(h<10){valuehouers="0"+valuehouers}$mc.empty();var n=60/settings.minutedivisions,tt=set_tt(realhours),counter=1;for(var m=0;m<60;m=m+n){$md=jQuery("<div class='CP_minute' id='"+realhours+"_"+m+"' value='"+valuehouers+((m<10)?"0":"")+m+"'>"+displayhours+":"+((m<10)?"0":"")+m+tt+"</div>");if(!v){$md.css("float","left");if(settings.minutedivisions>6&&counter==settings.minutedivisions/2+1){$mc.append("<div style='clear:left' />")}}$mc.append($md);binder($md);counter++}}function set_tt(realhours){if(!settings.military){return(realhours>=12)?" PM":" AM"}else{return""}}function putcontainer(){if(e.type!="focus"){$hourcont[0].style.left=e.pageX-5+"px";$hourcont[0].style.top=e.pageY-(Math.floor($hourcont.height()/2))+"px";rectify($hourcont)}else{$self.after($hourcont)}$hourcont.slideDown("fast");if(settings.useBgiframe){bgi($hourcont)}}function rectify($obj){var ph=document.documentElement.clientHeight?document.documentElement.clientHeight:document.body.clientHeight;var pw=document.documentElement.clientWidth?document.documentElement.clientWidth:document.body.clientWidth;var t=parseInt($obj[0].style.top);var l=parseInt($obj[0].style.left);var st=document.documentElement.scrollTop?document.documentElement.scrollTop:document.body.scrollTop;if(t<=st&&!$obj.is("#CP_minutecont")){$obj.css("top",st+10+"px")}else{if(t+$obj.height()-st>ph){$obj.css("top",st+ph-$obj.height()-10+"px")}}if(l<=0){$obj.css("left","10px")}}function bgi(ob){if(typeof jQuery.fn.bgIframe=="function"){ob.bgIframe()}else{alert("bgIframe plugin not loaded.")}}function binder($obj){if($obj.attr("id")=="CP_hourcont"){$obj.mouseout(function(e){hourcont_out(e)})}else{if($obj.attr("id")=="CP_minutecont"){$obj.mouseout(function(e){minutecont_out(e)})}else{if($obj.attr("class")=="CP_hour"){$obj.mouseover(function(e){hourdiv_over($obj,e)});$obj.mouseout(function(){hourdiv_out($obj)});$obj.click(function(){hourdiv_click($obj)})}else{if($obj.attr("class")=="CP_minute"){$obj.mouseover(function(){minutediv_over($obj)});$obj.mouseout(function(){minutediv_out($obj)});$obj.click(function(){minutediv_click($obj)})}}}}}function hourcont_out(e){try{var t=(e.toElement)?e.toElement:e.relatedTarget;if(!(jQuery(t).is("div[class^=CP], iframe"))){cleardivs()}}catch(e){cleardivs()}}function minutecont_out(e){try{var t=(e.toElement)?e.toElement:e.relatedTarget;if(!(jQuery(t).is("div[class^=CP], iframe"))){cleardivs()}}catch(e){cleardivs()}}function hourdiv_over($obj,e){var h=$obj.attr("id").split("_")[1],i=$obj.attr("id").split("_")[2],l,t;$obj.addClass("CP_over");if(settings.showminutes=="true"){$mc.hide();renderminutes(h);if(v){t=e.type=="mouseover"?e.pageY-15:$hourcont.offset().top+2+($obj.height()*i);if(h<12){l=$hourcont.offset().left-$mc.width()-2}else{l=$hourcont.offset().left+$hourcont.width()+2}}else{l=(e.type=="mouseover")?e.pageX-10:$hourcont.offset().left+($obj.width()-5)*i;if(h<12){t=$hourcont.offset().top-$mc.height()-2}else{t=$hourcont.offset().top+$hourcont.height()}}$mc.css("left",l+"px").css("top",t+"px");rectify($mc);$mc.show();if(settings.useBgiframe){bgi($mc)}}return false}function hourdiv_out($obj){$obj.removeClass("CP_over");return false}function hourdiv_click($obj){var h=$obj.attr("id").split("_")[1],tt=set_tt(h),str=$obj.attr("value");if(str.indexOf(" ")!=-1){var cleanstr=str.substring(0,str.indexOf(" "))}else{var cleanstr=str}$obj.text(cleanstr+"00"+settings.second);setval($obj);cleardivs()}function minutediv_over($obj){$obj.addClass("CP_over");return false}function minutediv_out($obj){$obj.removeClass("CP_over");return false}function minutediv_click($obj){$obj.text($obj.attr("value")+settings.second);setval($obj);cleardivs()}function setval($obj){if(!settings.valuefield){self.value=$obj.text()}else{jQuery("input[name="+settings.valuefield+"]").val($obj.text()).change()}callback.apply($self,[$obj.text()]);$self.unbind("keydown",keyhandler)}function cleardivs(){if(settings.showminutes=="true"){$mc.hide()}$hourcont.slideUp("fast");$self.unbind("keydown",keyhandler)}function keyhandler(e){var $obj=$("div.CP_over").size()?$("div.CP_over"):$("div.CP_hour:first"),divtype=$obj.is(".CP_hour")?"hour":"minute",hi=(divtype=="hour")?$obj[0].id.split("_")[2]:0,h=(divtype=="minute")?$obj[0].id.split("_")[0]:$obj[0].id.split("_")[1];if(divtype=="minute"){var curloc=h<12?"m1":"m2"}else{var curloc=h<12?"h1":"h2"}function divprev($obj){if($obj.prev().size()){eval(divtype+"div_out($obj)");eval(divtype+"div_over($obj.prev(), e)")}else{return false}}function divnext($obj){if($obj.next().size()){eval(divtype+"div_out($obj)");eval(divtype+"div_over($obj.next(), e)")}else{return false}}function hourtohour($obj){var ctx=h>=12?"#hourcol1":"#hourcol2";$newobj=jQuery(".CP_hour[id$=_"+hi+"]",ctx);if($newobj.size()){hourdiv_out($obj);hourdiv_over($newobj,e)}else{return false}}function hourtominute($obj){hourdiv_out($obj);minutediv_over($(".CP_minute:first"))}function minutetohour($obj){minutediv_out($obj);var ctx=h>=12?"#hourcol2":"#hourcol1";var $newobj=jQuery(".CP_hour[id^=hr_"+h+"]",ctx);hourdiv_over($newobj,e)}switch(e.keyCode){case 37:if(v){switch(curloc){case"m1":return false;break;case"m2":minutetohour($obj);break;case"h1":hourtominute($obj);break;case"h2":hourtohour($obj);break}}else{divprev($obj)}break;case 38:if(v){divprev($obj)}else{switch(curloc){case"m1":return false;break;case"m2":minutetohour($obj);break;case"h1":hourtominute($obj);break;case"h2":hourtohour($obj);break}}break;case 39:if(v){switch(curloc){case"m1":minutetohour($obj);break;case"m2":return false;break;case"h1":hourtohour($obj);break;case"h2":hourtominute($obj);break}}else{divnext($obj)}break;case 40:if(v){divnext($obj)}else{switch(curloc){case"m1":minutetohour($obj);break;case"m2":return false;break;case"h1":hourtohour($obj);break;case"h2":hourtominute($obj);break}}break;case 13:eval(divtype+"div_click($obj)");break;default:return true}return false}return false});function errorcheck(settings){if(settings.starthour>=settings.endhour){alert("Error - start hour must be less than end hour.");return false}else{if(60%settings.minutedivisions!=0){alert("Error - param minutedivisions must divide evenly into 60.");return false}}}return this};$(function(){if($.fn.ogClockpicker){$(document).ready(function(){$(".clockpick").ogClockpicker()})}});function likeComp(c){var b=c.substring(6);var d=$("#"+c).attr("aimaiType");var a=$("#"+b).val();a=a.replace(/^%+|%+$/g,"");if(a!=""){switch(d){case"1":a=a+"%";break;case"2":a="%"+a;break;case"3":a="%"+a+"%";break}}$("#"+b).val(a)}$(function(){$("form").submit(function(){$("[id^='AIMAI_']").each(function(){likeComp(this.id)})})});$.fn.aimaiPickerOg=function(a){var c={texts:[" V "," V*","*V ","*V*"],titls:["完全一致","前方一致","後方一致","前後曖昧"]};var b=$.extend(c,a);return this.each(function(){var g=$(this);var j="PIC_"+g.attr("id").replace(/-/g,"")+"_";var l="";for(var f=0;f<b.texts.length;f++){var m=b.texts[f];var k=b.titls[f];l+='<span id="'+j+"text-"+f+'" class="text-box"" title="'+k+'">('+m+") </span>"}var h=$('<div id="'+j+'aimai-picker" class="aimai-picker" style="position: absolute; left: 0px; top: 0px;">'+l+'<div style="clear: both;"></div></div>');$("body").append(h);h.hide();h.find("span.text-box").click(function(){var i=this.id.substr(this.id.indexOf("-")+1);g.attr("aimaiType",i);g.attr("title",b.titls[i]);g.text(b.texts[i]);g.blur();d(h)});$("body").live("click",function(){d(h)});h.click(function(i){i.stopPropagation()});var e=function(i){var p=g.offset();var o=p.left+g.outerWidth()-i.outerWidth();if(o<p.left){o=p.left}i.css({left:o,top:(p.top+g.outerHeight())});n(i)};g.click(function(i){i.stopPropagation();if(!g.is("input")){e(h)}});g.focus(function(){e(h)});function d(i){if(b.hideEffect=="fade"){i.fadeOut()}else{if(b.hideEffect=="slide"){i.slideUp()}else{i.hide()}}}function n(i){if(b.showEffect=="fade"){i.fadeIn()}else{if(b.showEffect=="slide"){i.slideDown()}else{i.show()}}}})};$(function(){if($.fn.aimaiPickerOg){$(".aimaiClm").aimaiPickerOg()}});(function(){$.fn.glDatePicker=function(options){var pluginName="glDatePicker";var instance=this.data(pluginName);if(!instance){return this.each(function(){return $(this).data(pluginName,new glDatePicker(this,options))})}return(options===true)?instance:this};$.fn.glDatePicker.defaults={cssName:"default",zIndex:1000,borderSize:1,calendarOffset:{x:0,y:1},showAlways:false,hideOnClick:true,allowMonthSelect:true,allowYearSelect:true,todayDate:new Date(),selectedDate:null,prevArrow:"\u25c4",nextArrow:"\u25ba",selectableDates:null,selectableDateRange:null,specialDates:null,selectableMonths:null,selectableYears:null,selectableDOW:null,monthNames:null,dowNames:null,dowOffset:(HYBS_CAL_START_MON==true?1:0),onClick:(function(el,cell,date,data){var tgt=el;if(el[0].tagName.toUpperCase()!="INPUT"){var _targetId=el.attr("targetId");if(_targetId!=null){tgt=$("#"+_targetId)}}var year=date.getFullYear();var month=date.getMonth()+1;var day=date.getDate();if(month<10){month="0"+month}if(day<10){day="0"+day}var str=year+""+month+""+day;tgt.val(str)}),onHover:function(el,cell,date,data){},onShow:function(calendar){calendar.show()},onHide:function(calendar){calendar.hide()},firstDate:null};var glDatePicker=(function(){function glDatePicker(element,userOptions){var self=this;self.el=$(element);var el=self.el;self.options=$.extend(true,{},$.fn.glDatePicker.defaults,userOptions);var options=self.options;var _tgt=el;if(el[0].tagName.toUpperCase()!="INPUT"){if(el.attr("targetId")){_tgt=$("#"+el.attr("targetId"))}}var _inputDate=_tgt.val();if(_inputDate!=null){_inputDate=_inputDate.replace(/\u002f/g,"");try{_inputDate=_inputDate.substr(0,4)+"/"+_inputDate.substr(4,2)+"/"+_inputDate.substr(6,2)}catch(e){_inputDate=null}}self.calendar=$($.find("[gldp-el="+el.attr("gldp-id")+" ]"));options.selectedDate=(options.selectedDate||new Date(_inputDate))||options.todayDate;options.firstDate=(new Date((options.firstDate||options.selectedDate)))._first();if(!(el.attr("gldp-id")||"").length){el.attr("gldp-id","gldp-"+Math.round(Math.random()*10000000000))}el.addClass("gldp-el").bind("click",function(e){self.show(e)});if(self.calendar.length&&!options.showAlways){self.calendar.hide()}$(document).bind("mouseup",function(e){var target=e.target;var calendar=self.calendar;if(!el.is(target)&&!calendar.is(target)&&calendar.has(target).length===0&&calendar.is(":visible")){self.hide()}})}glDatePicker.prototype={show:function(){this.render();$.each($(".gldp-el").not(this.el),function(i,o){if(o.length){o.options.onHide(o.calendar)}});this.options.onShow(this.calendar)},hide:function(){if(this.options&&!this.options.showAlways){this.options.onHide(this.calendar)}},render:function(renderCalback){var self=this;var el=self.el;var options=self.options;var calendar=self.calendar;var coreClass=" core border ";var cssName="gldp-"+options.cssName;var todayVal=options.todayDate._val();var todayTime=todayVal.time;var maxRow=6;var maxCol=7;var borderSize=options.borderSize+"px";var getSelectableList=function(min,max,userList){var resultList=[];for(var i=min;i<=max;i++){resultList.push(i)}if(userList){var newList=[];$.each(userList,function(i,v){if(v>=min&&v<=max&&newList._indexOf(v)<0){newList.push(v)}});resultList=newList.length?newList:resultList}resultList.sort();return resultList};var selectableMonths=getSelectableList(0,11,options.selectableMonths);var selectableYears=getSelectableList(todayVal.year-5,todayVal.year+5,options.selectableYears);var selectableDOW=getSelectableList(0,6,options.selectableDOW);var dowNames=options.dowNames||["日","月","火","水","木","金","土"];var monthNames=options.monthNames||["1月","2月","3月","4月","5月","6月","7月","8月","9月","10月","11月","12月"];var containerSize=window.innerHeight?window.innerHeight:180;if(containerSize<180){containerSize=(containerSize>135?containerSize:135)}else{containerSize=180}var containerWidth=options.conainerWidth||containerSize;var containerHeight=containerWidth;var getCellSize=function(_size,_count){return(_size/_count)+((options.borderSize/_count)*(_count-1))-1};var cellWidth=getCellSize(containerWidth,maxCol);var cellHeight=getCellSize(containerHeight,maxRow+2);if(!calendar.length){self.calendar=calendar=$("<div/>").attr("gldp-el",el.attr("gldp-id")).data("is",true).css({display:(options.showAlways?undefined:"none"),zIndex:options.zIndex,width:((cellWidth+1)*maxCol)+"px"});$("body").append(calendar)}else{if(!eval(calendar.data("is"))){containerWidth=calendar.outerWidth();containerHeight=calendar.outerHeight();cellWidth=getCellSize(containerWidth,maxCol);cellHeight=getCellSize(containerHeight,maxRow+2)}self.calendar.css({width:((cellWidth+1)*maxCol)+"px"})}if(!el.is(":visible")){calendar.hide()}calendar.removeClass().addClass(cssName).children().remove();var onResize=function(){var elPos=el.offset();calPosTop=(elPos.top+el.outerHeight()+options.calendarOffset.y)-20;calPosLeft=(elPos.left+options.calendarOffset.x);if(calPosTop>$(window).height()-150){calPosTop-=130}if(calPosLeft>$(window).width()-150){calPosLeft-=150}if(calPosTop<0){calPosTop=0}if(calPosLeft<0){calPosLeft=0}calendar.css({top:calPosTop+"px",left:calPosLeft+"px"})};$(window).resize(onResize);onResize();var cellCSS={width:cellWidth+"px",height:cellHeight+"px",lineHeight:cellHeight+"px"};var setFirstDate=function(_date){if(_date){options.firstDate=_date;self.render()}};var getFirstDate=function(_offset){var _date=new Date(options.firstDate);_offset=_offset||0;while(true){_date.setMonth(_date.getMonth()+_offset);_date.setDate(Math.min(1,_date._max()));if(_offset==0){break}var dateVal=_date._val();var dateMonth=dateVal.month;var dateYear=dateVal.year;if(selectableMonths._indexOf(dateMonth)!=-1){if(selectableYears._indexOf(dateYear)!=-1){break}else{if(dateYear<selectableYears[0]||dateYear>selectableYears[selectableYears.length-1]){return null}}}}return _date};var prevFirstDate=getFirstDate(-1);var nextFirstDate=getFirstDate(1);var firstDate=(options.firstDate=getFirstDate());var firstDateVal=firstDate._val();var firstDateMonth=firstDateVal.month;var firstDateYear=firstDateVal.year;var startDate=new Date(firstDate);var dowOffset=Math.abs(Math.min(6,Math.max(0,options.dowOffset)));var startOffset=startDate.getDay()-dowOffset;startOffset=startOffset<1?-7-startOffset:-startOffset;dowNames=(dowNames.concat(dowNames)).slice(dowOffset,dowOffset+7);startDate._add(startOffset);var showPrev=(prevFirstDate);var showNext=(nextFirstDate);var monyearClass=coreClass+"monyear ";var prevCell=$("<div/>").addClass(monyearClass).css($.extend({},cellCSS,{borderWidth:borderSize+" 0 0 "+borderSize})).append($("<a/>").addClass("prev-arrow"+(showPrev?"":"-off")).html(options.prevArrow)).mousedown(function(){return false}).click(function(e){if(options.prevArrow!=""&&showPrev){e.stopPropagation();setFirstDate(prevFirstDate)}});var titleCellCount=maxCol-2;var titleWidth=(cellWidth*titleCellCount)-(titleCellCount*options.borderSize)+(options.borderSize);var titleCell=$("<div/>").addClass(monyearClass+"title").css($.extend({},cellCSS,{width:titleWidth+"px",borderTopWidth:borderSize,marginLeft:"-"+(borderSize)}));var nextCell=$("<div/>").addClass(monyearClass).css($.extend({},cellCSS,{marginLeft:"-"+(borderSize),borderWidth:borderSize+" "+borderSize+" 0 0"})).append($("<a/>").addClass("next-arrow"+(showNext?"":"-off")).html(options.nextArrow)).mousedown(function(){return false}).click(function(e){if(options.nextArrow!=""&&showNext){e.stopPropagation();setFirstDate(nextFirstDate)}});calendar.append(prevCell).append(titleCell).append(nextCell);for(var row=0,cellIndex=0;row<maxRow+1;row++){for(var col=0;col<maxCol;col++,cellIndex++){var cellDate=new Date(startDate);var cellClass="day";var cellZIndex=options.zIndex+(cellIndex);var cell=$("<div/>");if(!row){cellClass="dow";cell.html(dowNames[col]);cellDate=null}else{cellDate._add(col+((row-1)*maxCol));var cellDateVal=cellDate._val();var cellDateTime=cellDateVal.time;var specialData=null;var isSelectable=true;var getRepeatDate=function(v,date){if(v.repeatYear===true){date.setYear(cellDateVal.year)}if(v.repeatMonth===true){date.setMonth(cellDateVal.month)}return date._val()};cell.html(cellDateVal.date);if(options.selectableDateRange){isSelectable=false;$.each(options.selectableDateRange,function(i,v){var dateFrom=v.from;var dateTo=(v.to||null);dateTo=dateTo||new Date(v.from.getFullYear(),v.from.getMonth(),v.from._max());dateFrom=getRepeatDate(v,dateFrom);dateTo=getRepeatDate(v,dateTo);if(cellDateTime>=dateFrom.time&&cellDateTime<=dateTo.time){isSelectable=true;return true}})}if(options.selectableDates){if((options.selectableDateRange&&!isSelectable)||(isSelectable&&!options.selectableDateRange)){isSelectable=false}$.each(options.selectableDates,function(i,v){var vDate=getRepeatDate(v,v.date);if(vDate.time==cellDateTime){return(isSelectable=true)}})}if(!isSelectable||selectableYears._indexOf(cellDateVal.year)<0||selectableMonths._indexOf(cellDateVal.month)<0||selectableDOW._indexOf(cellDateVal.day)<0){cellClass="noday"}else{cellClass=(["sun","mon","tue","wed","thu","fri","sat"])[cellDateVal.day];if(firstDateMonth!=cellDateVal.month){cellClass+=" outday"}if(todayTime==cellDateTime){cellClass="today";cellZIndex+=50}if(options.selectedDate._time()==cellDateTime){cellClass="selected";cellZIndex+=51}if(options.specialDates){$.each(options.specialDates,function(i,v){var vDate=getRepeatDate(v,v.date);if(vDate.time==cellDateTime){cellClass=(v.cssClass||"special");cellZIndex+=52;specialData=v.data}})}cell.mousedown(function(){return false}).hover(function(e){e.stopPropagation();var hoverData=$(this).data("data");options.onHover(el,cell,hoverData.date,hoverData.data)}).click(function(e){e.stopPropagation();var clickedData=$(this).data("data");options.selectedDate=options.firstDate=clickedData.date;self.render(function(){if(!options.showAlways&&options.hideOnClick){self.hide()}});options.onClick(el,$(this),clickedData.date,clickedData.data)})}}$.extend(cellCSS,{borderTopWidth:borderSize,borderBottomWidth:borderSize,borderLeftWidth:(row>0||(!row&&!col))?borderSize:0,borderRightWidth:(row>0||(!row&&col==6))?borderSize:0,marginLeft:(col>0)?"-"+(borderSize):0,marginTop:(row>0)?"-"+(borderSize):0,zIndex:cellZIndex});cell.data("data",{date:cellDate,data:specialData}).addClass(coreClass+cellClass).css(cellCSS);calendar.append(cell)}}var toggleYearMonthSelect=function(showYear){var show="inline-block";var hide="none";if(options.allowMonthSelect){monthText.css({display:!showYear?hide:show});monthSelect.css({display:!showYear?show:hide})}if(options.allowYearSelect){yearText.css({display:showYear?hide:show});yearSelect.css({display:showYear?show:hide})}};var onYearMonthSelect=function(){options.firstDate=new Date(yearSelect.val(),monthSelect.val(),1);self.render()};var monthSelect=$("<select/>").hide().change(onYearMonthSelect);var yearSelect=$("<select/>").hide().change(onYearMonthSelect);var monthText=$("<span/>").html(monthNames[firstDateMonth]).mousedown(function(){return false}).click(function(e){e.stopPropagation();toggleYearMonthSelect(false)});var yearText=$("<span/>").html(firstDateYear).mousedown(function(){return false}).click(function(e){e.stopPropagation();toggleYearMonthSelect(true)});$.each(monthNames,function(i,v){if(options.allowMonthSelect&&selectableMonths._indexOf(i)!=-1){var o=$("<option/>").html(v).attr("value",i);if(i==firstDateMonth){o.attr("selected","selected")}monthSelect.append(o)}});$.each(selectableYears,function(i,v){if(options.allowYearSelect){var o=$("<option/>").html(v).attr("value",v);if(v==firstDateYear){o.attr("selected","selected")}yearSelect.append(o)}});var titleYearMonth=$("<div/>").append(monthText).append(monthSelect).append(yearText).append(yearSelect);titleCell.children().remove();titleCell.append(titleYearMonth);renderCalback=renderCalback||(function(){});renderCalback();var mousewheelevent="onwheel" in document?"wheel":"onmousewheel" in document?"mousewheel":"DOMMouseScroll";calendar.bind(mousewheelevent,function(e){e.preventDefault();var delta=e.originalEvent.deltaY?-(e.originalEvent.deltaY):e.originalEvent.wheelDelta?e.originalEvent.wheelDelta:-(e.originalEvent.detail);if(delta<0){nextCell.click()}else{prevCell.click()}})}};return glDatePicker})();(function(){Date.prototype._clear=function(){this.setHours(0);this.setMinutes(0);this.setSeconds(0);this.setMilliseconds(0);return this};Date.prototype._time=function(){return this._clear().getTime()};Date.prototype._max=function(){var isLeapYear=(new Date(this.getYear(),1,29).getMonth()==1)?1:0;var days=[31,28+isLeapYear,31,30,31,30,31,31,30,31,30,31];return days[this.getMonth()]};Date.prototype._add=function(days){this.setDate(this.getDate()+days)};Date.prototype._first=function(){var date=new Date(this);date.setDate(1);return date};Date.prototype._val=function(){this._clear();return{year:this.getFullYear(),month:this.getMonth(),date:this.getDate(),time:this.getTime(),day:this.getDay()}};Array.prototype._indexOf=function(value){return $.inArray(value,this)}})()})();$(function(){if($.fn.glDatePicker){$(".calPic").glDatePicker()}});function selectScroll(a){var d=4;if(a.getAttribute("size")){d=a.getAttribute("size")}var e=a.options;for(var c=0;c<e.length;c++){if(e[c].selected){if(e[c].parentNode.tagName.toUpperCase()=="OPTGROUP"){c+=$(e[c].parentNode).prev().length}var b=c*($(a).height()/d);break}}$(a).scrollTop(b)}$(function(){$("select[multiple]").each(function(){selectScroll(this)})});
\ No newline at end of file
--- trunk/opengionV5/uap/webapps/ge/jsp/common/quickReference.html (revision 1396)
+++ trunk/opengionV5/uap/webapps/ge/jsp/common/quickReference.html (revision 1397)
@@ -31,7 +31,7 @@
3131 <link rel="stylesheet" type="text/css" href="../custom/custom.css?v=1448508750682" />
3232 </head>
3333 <!-- DB検索 SQL文記述 debug="true" でSQL文を確認できます。-->
34-<div id="queryTime" value="62"></div>
34+<div id="queryTime" value="16"></div>
3535
3636 <!-- ColumnEditorTagを使用すると、登録画面の入力フィールドで、入力の必須状態を表したり(must="true"を使用)、 -->
3737 <!-- DBからの検索結果を、コンボボックスでプルダウン表示させる(editor="DBMENU"を使用)ことが可能となります。 -->
@@ -1219,11 +1219,11 @@
12191219 </tr>
12201220 </tbody>
12211221 </table>
1222-</div><input type="hidden" name="pageSize" value="100000" id="pageSize" /><input type="hidden" name="h_consisKey" value="1486709277484" id="h_consisKey" /><div id="viewTime" value="16"></div>
1222+</div><input type="hidden" name="pageSize" value="100000" id="pageSize" /><input type="hidden" name="h_consisKey" value="1487150022480" id="h_consisKey" /><div id="viewTime" value="2"></div>
12231223
12241224 <div style="page-break-before: always" ></div>
12251225
1226-<div id="queryTime" value="231"></div>
1226+<div id="queryTime" value="201"></div>
12271227
12281228
12291229
@@ -10724,11 +10724,11 @@
1072410724 <tr><td colspan="4"> </td></tr>
1072510725 </tbody>
1072610726 </table>
10727-</div><input type="hidden" name="pageSize" value="1000000" id="pageSize" /><input type="hidden" name="h_consisKey" value="1486709277717" id="h_consisKey" /><div id="viewTime" value="85"></div>
10727+</div><input type="hidden" name="pageSize" value="1000000" id="pageSize" /><input type="hidden" name="h_consisKey" value="1487150022633" id="h_consisKey" /><div id="viewTime" value="32"></div>
1072810728
1072910729 <div style="page-break-before: always" ></div>
1073010730
10731-<div id="queryTime" value="47"></div>
10731+<div id="queryTime" value="32"></div>
1073210732
1073310733
1073410734
@@ -13323,7 +13323,7 @@
1332313323 </tr>
1332413324 </tbody>
1332513325 </table>
13326-</div><input type="hidden" name="pageSize" value="1000" id="pageSize" /><input type="hidden" name="h_consisKey" value="1486709277900" id="h_consisKey" /><div id="viewTime" value="0"></div>
13326+</div><input type="hidden" name="pageSize" value="1000" id="pageSize" /><input type="hidden" name="h_consisKey" value="1487150022765" id="h_consisKey" /><div id="viewTime" value="0"></div>
1332713327
1332813328
1332913329
--- trunk/opengionV5/uap/webapps/gf/doc/RELEASE-NOTES.txt (revision 1396)
+++ trunk/opengionV5/uap/webapps/gf/doc/RELEASE-NOTES.txt (revision 1397)
@@ -16,8 +16,8 @@
1616 使い方はサンプルGF7222を参考としてください。
1717 必要なJSをロードするには、headタグでuseChartJSをtrueにセットします。
1818 gf/jsp/GF7222
19- gf/jsp/common/option/Chart.min.js (Ver.2.4)
20- gf/jsp/common/option/moment.min.js (Ver.2.3)
19+ jsp/common/option/Chart.min.js (Ver.2.4)
20+ jsp/common/option/moment.min.js (Ver.2.3)
2121 hayabusa.taglib.JsChartTag 新規
2222 hayabusa.taglib.JsChartDataTag 新規
2323 hayabusa.io.JsChartData 新規
@@ -25,6 +25,12 @@
2525 hayabusa.taglib.HeadTag#release2()
2626 hayabusa.taglib.HeadTag#doEndTag()
2727 hybs-taglib.tld
28+
29+ [時間ピッカーの縦横設定]
30+ ogClockpickerでは一部の属性をタグから拾えるようにしていましたが、layout設定も拾うようにします。
31+ この設定が初期値のverticalの場合は今まで通りですが、それ以外の場合は横向きになります。
32+ jsp/common/eventScript.js#ogClockpicker
33+ plugin.column.Editor_HM#createOptions( final String editPrm )
2834
2935 5.9.17.1 (2017/02/10)
3036 [JFreeChartの色指定修正]
--- trunk/opengionV5/uap/webapps/gf/src/script/common/eventScript.js (revision 1396)
+++ trunk/opengionV5/uap/webapps/gf/src/script/common/eventScript.js (revision 1397)
@@ -754,12 +754,14 @@
754754 param options[military] string use 24hr time if true(true/false)
755755 param options[valuefield] string field to insert time value, if not same as click field(name of input field)
756756 param options[showminutes] bool show minutes
757-param options[second] bool add second(00) //5.9.12.3
757+param options[second] bool add second(00) //5.9.12.3
758+param options[layout] string vertical or horizon //5.9.17.2
758759
759760 又、対象単位に設定値を持てるように対応。
760761 @og.rev 5.9.8.3 (2016/05/20) 標準をAMPMではなく24時間表記に変更、ピッカー選択時にchangeイベント発生させる
761762 @og.rev 5.9.12.3 (2015/09/23) 返す値に秒(00固定)を追加出来るようにする(useSecond)
762763 @og.rev 5.9.15.1 (2016/12/09) 数値変換不具合対応
764+@og.rev 5.9.17.2 (2017/02/15) layout指定追加
763765 ********************************************************************************************/
764766
765767 jQuery.fn.ogClockpicker = function(options, callback) {
@@ -819,6 +821,11 @@
819821 if( $self.attr('usesecond') == "true" ){ // 5.9.12.3 (2016/09/23)
820822 settings.second = "00";
821823 }
824+ if( $self.attr('layout') ){ // 5.9.17.2 (2017/02/17)
825+ settings.layout = $self.attr('layout');
826+ org_settings.layout = settings.layout; // overwrite
827+ v = (settings.layout == 'vertical');
828+ }
822829
823830 errorcheck(settings);
824831
--- trunk/opengionV5/uap/webapps/gf/src/org/opengion/plugin/column/Editor_HM.java (revision 1396)
+++ trunk/opengionV5/uap/webapps/gf/src/org/opengion/plugin/column/Editor_HM.java (revision 1397)
@@ -33,6 +33,7 @@
3333 * minutedivisions :単位「分」の分割数。4なら15分単位。(2-60)
3434 * showminutes :分ピッカーの表示(true/false)
3535 * usesecond : 秒付き(6桁、秒は00固定)で値を返すかどうか(true/false)
36+ * layout : 表示の縦横(vertical/horizon)
3637 *
3738 * このエディタはeventColumnに対応していません。
3839 *
@@ -41,6 +42,7 @@
4142 *
4243 * @og.rev 5.6.5.2 (2013/06/21) 新規作成
4344 * @og.rev 5.9.12.3 (2016/09/23) usesecond追加
45+ * @og.rev 5.9.17.2 (2017/02/17) layout追加
4446 * @og.group データ編集
4547 *
4648 * @version 5.0
@@ -59,6 +61,7 @@
5961 private static final String OPT3 = "minutedivisions=\"";
6062 private static final String OPT4 = "showminutes=\"";
6163 private static final String OPT5 = "usesecond=\""; // 5.9.12.3 (2016/09/23)
64+ private static final String OPT6 = "layout=\""; // 5.9.17.2 (2017/02/17)
6265 private static final String END_ATTR = "\" ";
6366
6467 private final String options;
@@ -155,6 +158,7 @@
155158 * 初期値は、starthour="6" endhour="20" minutedivisions="4" showminutes="true" です。
156159 *
157160 * @og.rev 5.9.12.3 (2016/09/23) usesecond対応
161+ * @og.rfv 5.9.17.2 (2017/02/15) layout対応
158162 *
159163 * @param editPrm 編集パラメータ
160164 *
@@ -168,8 +172,11 @@
168172 String step = (param.length > 2) ? param[2].trim() : "4" ;
169173 String min = (param.length > 3) ? param[3].trim() : "true" ;
170174 String sec = (param.length > 4) ? param[4].trim() : "false" ; // 5.9.12.3 (2016/09/23)
175+ String layout = (param.length > 5) ? param[5].trim() : "vertical" ; // 5.9.17.2 (2017/02/15)
171176
172177 // return OPT1 + start + END_ATTR + OPT2 + end + END_ATTR + OPT3 + step + END_ATTR + OPT4 + min + END_ATTR;
173- return OPT1 + start + END_ATTR + OPT2 + end + END_ATTR + OPT3 + step + END_ATTR + OPT4 + min + END_ATTR + OPT5 + sec + END_ATTR; // 5.9.12.3 (2016/09/23)
178+// return OPT1 + start + END_ATTR + OPT2 + end + END_ATTR + OPT3 + step + END_ATTR + OPT4 + min + END_ATTR + OPT5 + sec + END_ATTR; // 5.9.12.3 (2016/09/23)
179+ return OPT1 + start + END_ATTR + OPT2 + end + END_ATTR + OPT3 + step + END_ATTR + OPT4 + min + END_ATTR + OPT5 + sec + END_ATTR + OPT6 + layout + END_ATTR; // 5.9.12.3 (2016/09/23)
180+
174181 }
175182 }
--- trunk/opengionV5/uap/webapps/gf/jsp/common/eventScript.js (revision 1396)
+++ trunk/opengionV5/uap/webapps/gf/jsp/common/eventScript.js (revision 1397)
@@ -1 +1 @@
1-var orgFldCls=null;$(function(){if(USE_FOCUS_HILIGHT){setEvent('textarea,select,input[type="text"]',"focusin",function(){doFocus2(this)});setEvent('textarea,select,input[type="text"]',"focusout",function(){doBlur2(this)})}});function doFocus2(a){if(a!=null){if(a.className==null||a.className.indexOf("must")<0){if(a.tagName=="SELECT"){a.orgBgColor=a.style.backgroundColor;a.style.backgroundColor="#ffcccc"}else{orgFldCls=a.className;a.className="focusField "+orgFldCls}}}}function doBlur2(a){if(a!=null){if(a.className==null||a.className.indexOf("must")<0){if(a.tagName=="SELECT"){a.style.backgroundColor=a.orgBgColor}else{if(orgFldCls!=null){a.className=orgFldCls}else{a.className="notFocusField"}}}}}oldDoFocusFlag=true;function doFocus(a){if(oldDoFocusFlag){oldDoFocusFlag=false;setTimeout(alert("Old Script Error!!\ncustom/query_info.jsp,custom/result_info.jsp Please delete the following part.\n<script>Tag(Header fix and Focus) , BODY onLoad and oncontextmenu Attribute"),100)}}function doBlur(a){}$(function(){setEvent('textarea,select,input[type="text"]',"focusout",function(){convert(this)})});function convert(b){var c,a;c=b.value;a=b.className;if(c!=null&&a!=null){if(a.match(/XL/)&&!(a.match(/XLU/))){b.value=c.toLowerCase()}else{if((a.match(/XU/)&&!(a.match(/XUL/)))||a.match(/PN2/)){b.value=c.toUpperCase()}}}return true}var colMap;var notFireCols;var jH_evElm;$(function(){if(!(typeof(EC_NAME)=="undefined")){jH_evElm=$(".h_evElm");makeColMapping();setEvent('textarea,select,input[type="text"]',"change",function(){makeColumn(this)},".h_evCol",true,addEvColCls);setEvent("input[type=checkbox],input[type=radio]","click",function(){makeColumn(this)},".h_evCol",true)}});function makeColMapping(){var b,a,e,d,c;if(colMap){return}colMap=new Object();for(b=0;b<EC_EVCOL.length;b++){e=EC_EVCOL[b].split(",");for(a=0;a<e.length;a++){d=e[a];if(d.charAt(0)=="_"){d=d.substring(1);if(notFireCols){notFireCols+=","}notFireCols+=d}c=colMap[d];if(!c){c=new Array()}c[c.length]=EC_NAME[b];colMap[d]=c}}}function addEvColCls(){for(var a in colMap){$("#"+a+",[id^="+a+"__]").addClass("h_evCol")}}function makeColumn(e){var k,l,g,j,b,h,d,c,a,f;if(jH_evElm&&isEndInitEvent()){jH_evElm=null}k=$(e);l=k.attr("id");g=l.split("__")[0];j=colMap[g];if(!j){return}if(!isEndInitEvent()&&notFireCols&&notFireCols.indexOf(g)>=0){return}for(b=0;b<j.length;b++){h=(l==g?"":"__"+l.split("__")[1]);d=j[b]+h;c=d.split("__")[0];a=isEndInitEvent()?$(".h_evElm[h_evCid="+d+"]"):jH_evElm.filter("[h_evCid="+d+"]");f=a.attr("h_evWrtbl");eventColumn(k,a,d,c,h,f)}}function eventColumn(jEvCol,jTag,cid,cname,suffix,writable){var evVal,url,param,_pos1,_pos2,_repClm,_rep,_clm,noVal,columnFocus,jCol,val,renderer,editor,ATTRS,optAttrs,i,optAtt,vtype,isAdd;var callback;if(!jTag||jTag.length==0){alert("[SYSTEM_ERROR] : jTag is null. The element of the replacement object doesn't exist. ["+cname+"]");return}if(!isEndInitEvent()){evVal=jEvCol.get(0).value;if(!evVal||evVal==null||evVal==""){return}}try{url=eval("EC_"+cname+"_URL")}catch(e){alert("[SYSTEM_ERROR] : URL that processes the event is not specified. (variable undefinition). ["+cname+"]");return}if(!url||url==""){alert("[SYSTEM_ERROR] : URL that processes the event is not specified. ["+cname+"]");return}param="";try{param=(writable?eval("EC_"+cname+"_EDITPARAM"):eval("EC_"+cname+"_RENDPARAM"))}catch(e){}if(param!=null&&param!=""){url+="?";_pos1=0;_pos2=0;while((_pos1=param.indexOf("{@",_pos2))!=-1){_pos2=param.indexOf("}",_pos1);_clm=param.substring(_pos1+2,_pos2);if(_clm.indexOf(".")<0){_repClm="{@"+_clm+"}";_rep=suffix==""?$("#"+_clm).get(0).value:$("#"+_clm+suffix).get(0).value;_rep=(_rep==null?"":_rep);param=param.replace(_repClm,_rep);url+=_clm+"="+encodeURIComponent(_rep)+"&"}_pos2=_pos1+1}}noVal=function(){_firstOption=jCol.children("option").get(0);if(_firstOption==null||_firstOption.value!=""){return false}return true};columnFocus=function(){jCol.attr("isfocus","true")};if(cid!=null&&cid!=""){jCol=jTag.find("#"+cid)}else{jCol=new Array(0)}if(jCol.length>0&&isEndInitEvent()){jCol.bind("focus",columnFocus)}val="";if(jCol.length>0){if(isEndInitEvent()){val=(jCol.val()==null?"":jCol.val())}else{val=(jTag.attr("h_evVal")==null?"":jTag.attr("h_evVal"))}}renderer="";try{renderer=eval("EC_"+cname+"_RENDERER")}catch(e){}editor="";try{editor=eval("EC_"+cname+"_EDITOR")}catch(e){}ATTRS=["title","style","tabindex","readonly","disabled","onClick","onChange","onBlur","onFocus","ondblClick","onMouseDown","onMouseUp","onMouseMove","onMouseOut","onMouseOver","onSelect","onKeydown","onKeypress","onKeyup","eventCallBack","multiple"];optAttrs="";if(jCol.length>0){for(i=0;i<ATTRS.length;i++){optAtt=jCol.attr(ATTRS[i]);if(optAtt!=null){vtype=typeof(optAtt);isAdd=false;if(vtype=="function"){optAtt=optAtt.toString();isAdd=optAtt.length>0?true:false;optAtt="("+optAtt+")()"}else{if(vtype=="boolean"){isAdd=optAtt}else{isAdd=optAtt.length>0?true:false}}if(isAdd){optAttrs+=ATTRS[i]+"='"+optAtt+"' "}}}}$.ajax({url:url,data:{EC_CID:(cid==null?"":cid),EC_CNAME:(cname==null?"":cname),EC_RENDERER:renderer,EC_EDITOR:editor,EC_PARAM:param,EC_SQL:param,EC_WRITABLE:(writable==null?"":writable),EC_CVALUE:val,EC_NOVALUE:(jCol.length==0?"":noVal()),EC_CLASS:(jCol.length==0?"":jCol.attr("class")),EC_SIZE:(jCol.length==0?"":jCol.attr("size")),EC_MAXLENGTH:(jCol.length==0?"":jCol.attr("maxlength")),EC_OPTATTRS:optAttrs,EC_PNAME:jEvCol.attr("id")==null?"":jEvCol.attr("id").split("__")[0],EC_PVALUE:jEvCol.get(0).value==null?"":jEvCol.get(0).value,EC_USESLBL:(suffix==null||suffix=="")?"false":"true"},type:"POST",dataType:"html",async:isEndInitEvent(),error:function(r,s,e){if(url.indexOf(".htm")<0){alert("EventColumnError:"+r+":"+s+":"+e+":"+cname)}},success:function(data,status){var jNewCol=$(data);if(jCol.length>0){if(isEndInitEvent()){jCol.unbind("focus",columnFocus)}bindOldEvents(jNewCol.get(0),jQuery.data(jCol.clone(true).get(0),"events"))}jTag.empty().append(jNewCol);if(jCol.length>0){jTag.find("input,select,textarea").attr("name",cid).attr("id",cid);if(isEndInitEvent()){if(jCol.attr("isfocus")){jNewCol.get(0).focus();if($.browser.msie){jNewCol.get(0).focus()}}}if(!isEndInitEvent()){jNewCol.change()}if(jCol.attr("eventCallback")){callback=function(){eval(jCol.attr("eventCallback")+"(arguments);")};callback(cid,jNewCol.val(),jCol.get(0).value)}}if(suffix!=null&&suffix!=""){if(isEndInitEvent()){$("table#viewTable").resizeView()}}}})}function bindOldEvents(d,a){var c,b;for(c in a){for(b in a[c]){jQuery.event.add(d,c,a[c][b],a[c][b].data)}}}var isShowTip=false;$(function(){if(USE_REAL_TIME_CHECK){setEvent('textarea,select,input[type="text"]',"focusout",function(){var b=RegExp(/jsp/);var a=location.pathname.match(b);check(this,RegExp.leftContext+"jsp/common/realtimecheck.jsp")});$("table#viewTable").parent().parent().scroll(function(){if(isShowTip){isShowTip=false;$(".tipErr").remove()}})}});function check(f,b){var c,d,h,g,e,j,a,i;c=f.name;if(typeof jQuery!="undefined"&&c.indexOf("h_")!=0){d=f.value;if(f.rtOption!="null"&&f.rtOption!="undefined"){i=f.rtOption}h=c.split("__");g=(2==h.length);e="command=RENEW&checkType="+(g?"ENTRY":"NEW")+(g?"&h_rowSel="+h[1]:"")+"&column="+h[0]+"&"+c+"="+encodeURIComponent(d)+(i?"&"+i:"");j={dataType:"html",type:"POST",url:b,data:e};j.error=function(){};j.success=function(k){a=$(f).data("tipId");$("#"+a).remove();if($.trim(k).indexOf("row_error")>=0){showCheckTip(f,k);isShowTip=true}};$.ajax(j)}return true}function showCheckTip(a,c){var j,i,k,g,e,h,f,d,b;j=$(a);i=j.offset();if(i.top>=30){e="<div class='tipErr'><div id='tipArrowBottom'></div><div>"+c+"</div></div>";h=$(e).appendTo(document.body);f=i.left;d=i.top+(-11-h[0].offsetHeight)}else{e="<div class='tipErr'><div id='tipArrowTop'></div><div>"+c+"</div></div>";h=$(e).appendTo(document.body);f=i.left;d=i.top+11+h[0].offsetHeight}b=(new Date()).getTime();$(a).data("tipId",b);h.css({left:f+"px",top:d+"px"}).attr("id",b).click(function(){$(this).remove()}).show()}$(function(){bindEvents()});$.fn.simpleColorPickerOg=function(a){var c={colorsPerLine:8,colors:["#000000","#444444","#666666","#999999","#cccccc","#eeeeee","#f3f3f3","#ffffff","#ff0000","#ff9900","#ffff00","#00ff00","#00ffff","#0000ff","#9900ff","#ff00ff","#f4cccc","#fce5cd","#fff2cc","#d9ead3","#d0e0e3","#cfe2f3","#d9d2e9","#ead1dc","#ea9999","#f9cb9c","#ffe599","#b6d7a8","#a2c4c9","#9fc5e8","#b4a7d6","#d5a6bd","#e06666","#f6b26b","#ffd966","#93c47d","#76a5af","#6fa8dc","#8e7cc3","#c27ba0","#cc0000","#e69138","#f1c232","#6aa84f","#45818e","#3d85c6","#674ea7","#a64d79","#990000","#b45f06","#bf9000","#38761d","#134f5c","#0b5394","#351c75","#741b47","#660000","#783f04","#7f6000","#274e13","#0c343d","#073763","#20124d","#4C1130"],showEffect:"",hideEffect:"",onChangeColor:false};var b=$.extend(c,a);return this.each(function(){var g=$(this);var l="";var j=g.attr("id").replace(/-/g,"")+"_";for(var f=0;f<b.colors.length;f++){var m=b.colors[f];var k="";if(f%b.colorsPerLine==0){k="clear: both; "}if(f>0&&k&&$.browser&&$.browser.msie&&$.browser.version<=7){k="";l+='<li style="float: none; clear: both; overflow: hidden; background-color: #fff; display: block; height: 1px; line-height: 1px; font-size: 1px; margin-bottom: -2px;"></li>'}l+='<li id="'+j+"color-"+f+'" class="color-box" style="'+k+"background-color: "+m+'" title="'+m+'"></li>'}k="clear: both; ";l+='<li id="'+j+'color-default" class="color-box" style="width:80px; text-align:center; '+k+'background-color:white;" title="clear">clear</li>';var h=$('<div id="'+j+'color-picker" class="color-picker" style="position: absolute; left: 0px; top: 0px;"><ul>'+l+'</ul><div style="clear: both;"></div></div>');$("body").append(h);h.hide();h.find("li.color-box").click(function(){var i=isNaN(this.id.substr(this.id.indexOf("-")+1))?"":b.colors[this.id.substr(this.id.indexOf("-")+1)];if(!g.is("input")){g.val(i);g.blur()}if($.isFunction(c.onChangeColor)){c.onChangeColor.call(g,i)}d(h)});$("body").live("click",function(){d(h)});h.click(function(i){i.stopPropagation()});var e=function(i){var p=g.offset();var o=p.left+g.outerWidth()-i.outerWidth();if(o<p.left){o=p.left}i.css({left:o,top:(p.top+g.outerHeight())});n(i)};g.click(function(i){g=$(this);i.stopPropagation();if(!g.is("input")){e(h)}});g.change(function(i){if(g.val()!=g.css("background-color")){g.css("background-color",g.val()).css("color",g.val())}});g.focus(function(){e(h)});function d(i){if(b.hideEffect=="fade"){i.fadeOut()}else{if(b.hideEffect=="slide"){i.slideUp()}else{i.hide()}}}function n(i){if(b.showEffect=="fade"){i.fadeIn()}else{if(b.showEffect=="slide"){i.slideDown()}else{i.show()}}}})};$(function(){if($.fn.simpleColorPickerOg){$("input.colorPicker").simpleColorPickerOg({onChangeColor:function(a){$(this).val(a).css("background-color",a).css("color",a).change()}})}});jQuery.fn.ogClockpicker=function(options,callback){var org_settings={starthour:6,endhour:20,showminutes:"true",minutedivisions:4,military:true,event:"click",layout:"vertical",valuefield:null,useBgiframe:false,hoursopacity:1,minutesopacity:1,second:""};if(options){jQuery.extend(org_settings,options)}var callback=callback||function(){},v=(org_settings.layout=="vertical");errorcheck(org_settings);jQuery(this)[org_settings.event](function(e){var self=this,$self=jQuery(this),$body=jQuery("body");var settings=jQuery.extend(true,{},org_settings);if($self.attr("valuefield")){settings.valuefield=$self.attr("valuefield")}if($self.attr("starthour")){settings.starthour=$self.attr("starthour")}if($self.attr("endhour")){settings.endhour=$self.attr("endhour")}if($self.attr("minutedivisions")){settings.minutedivisions=$self.attr("minutedivisions")}if($self.attr("military")){settings.military=$self.attr("military")}if($self.attr("showminutes")){settings.showminutes=$self.attr("showminutes")}if($self.attr("usesecond")=="true"){settings.second="00"}errorcheck(settings);if(!settings.valuefield){$self.unbind("keydown").bind("keydown",keyhandler)}else{var inputfield=jQuery("[name="+settings.valuefield+"]");inputfield.unbind("keydown").bind("keydown",keyhandler)[0].focus();inputfield.bind("click",function(){inputfield.unbind("keydown")})}jQuery("#CP_hourcont,#CP_minutecont").remove();var $hourcont=jQuery("<div id='CP_hourcont' class='CP' />").appendTo($body);!settings.useBgiframe?$hourcont.css("opacity",settings.hoursopacity):null;binder($hourcont);var $hourcol1=jQuery("<div class='CP_hourcol' id='hourcol1' />").appendTo($body);var $hourcol2=jQuery("<div class='CP_hourcol' id='hourcol2' />").appendTo($body);if(settings.showminutes=="true"){var $mc=jQuery("<div id='CP_minutecont' class='CP' />").appendTo($body);!settings.useBgiframe?$mc.css("opacity",settings.minutesopacity):null;binder($mc)}if(!v){$hourcont.css("width","auto");if(settings.showminutes=="true"){$mc.css("width","auto")}}else{$hourcol1.addClass("floatleft");$hourcol2.addClass("floatleft")}renderhours();putcontainer();function renderhours(){var c=1;for(var h=settings.starthour;h<=settings.endhour;h++){if(h==12){c=1}var displayhours=((!settings.military&&h>12)?h-12:h);var valuehouers=h;if(!settings.military&&h==0){}else{if(!settings.military&&h==12){displayhours="0"}}if(settings.military&&h<10){displayhours="0"+displayhours}if(h<10){valuehouers="0"+valuehouers}var $hd=jQuery("<div class='CP_hour' id='hr_"+h+"_"+c+"' value='"+valuehouers+"' >"+displayhours+set_tt(h)+"</div>");if(settings.military){$hd.width(20)}binder($hd);if(!v){$hd.css("float","left")}(h<12)?$hourcol1.append($hd):$hourcol2.append($hd);c++}$hourcont.append($hourcol1);!v?$hourcont.append("<div style='clear:left' />"):"";$hourcont.append($hourcol2)}function renderminutes(h){var realhours=h;var displayhours=(!settings.military&&h>12)?h-12:h;var valuehouers=h;if(!settings.military&&h==0){}else{if(!settings.military&&h==12){displayhours="0"}}if(settings.military&&h<10){displayhours="0"+displayhours}if(h<10){valuehouers="0"+valuehouers}$mc.empty();var n=60/settings.minutedivisions,tt=set_tt(realhours),counter=1;for(var m=0;m<60;m=m+n){$md=jQuery("<div class='CP_minute' id='"+realhours+"_"+m+"' value='"+valuehouers+((m<10)?"0":"")+m+"'>"+displayhours+":"+((m<10)?"0":"")+m+tt+"</div>");if(!v){$md.css("float","left");if(settings.minutedivisions>6&&counter==settings.minutedivisions/2+1){$mc.append("<div style='clear:left' />")}}$mc.append($md);binder($md);counter++}}function set_tt(realhours){if(!settings.military){return(realhours>=12)?" PM":" AM"}else{return""}}function putcontainer(){if(e.type!="focus"){$hourcont[0].style.left=e.pageX-5+"px";$hourcont[0].style.top=e.pageY-(Math.floor($hourcont.height()/2))+"px";rectify($hourcont)}else{$self.after($hourcont)}$hourcont.slideDown("fast");if(settings.useBgiframe){bgi($hourcont)}}function rectify($obj){var ph=document.documentElement.clientHeight?document.documentElement.clientHeight:document.body.clientHeight;var pw=document.documentElement.clientWidth?document.documentElement.clientWidth:document.body.clientWidth;var t=parseInt($obj[0].style.top);var l=parseInt($obj[0].style.left);var st=document.documentElement.scrollTop?document.documentElement.scrollTop:document.body.scrollTop;if(t<=st&&!$obj.is("#CP_minutecont")){$obj.css("top",st+10+"px")}else{if(t+$obj.height()-st>ph){$obj.css("top",st+ph-$obj.height()-10+"px")}}if(l<=0){$obj.css("left","10px")}}function bgi(ob){if(typeof jQuery.fn.bgIframe=="function"){ob.bgIframe()}else{alert("bgIframe plugin not loaded.")}}function binder($obj){if($obj.attr("id")=="CP_hourcont"){$obj.mouseout(function(e){hourcont_out(e)})}else{if($obj.attr("id")=="CP_minutecont"){$obj.mouseout(function(e){minutecont_out(e)})}else{if($obj.attr("class")=="CP_hour"){$obj.mouseover(function(e){hourdiv_over($obj,e)});$obj.mouseout(function(){hourdiv_out($obj)});$obj.click(function(){hourdiv_click($obj)})}else{if($obj.attr("class")=="CP_minute"){$obj.mouseover(function(){minutediv_over($obj)});$obj.mouseout(function(){minutediv_out($obj)});$obj.click(function(){minutediv_click($obj)})}}}}}function hourcont_out(e){try{var t=(e.toElement)?e.toElement:e.relatedTarget;if(!(jQuery(t).is("div[class^=CP], iframe"))){cleardivs()}}catch(e){cleardivs()}}function minutecont_out(e){try{var t=(e.toElement)?e.toElement:e.relatedTarget;if(!(jQuery(t).is("div[class^=CP], iframe"))){cleardivs()}}catch(e){cleardivs()}}function hourdiv_over($obj,e){var h=$obj.attr("id").split("_")[1],i=$obj.attr("id").split("_")[2],l,t;$obj.addClass("CP_over");if(settings.showminutes=="true"){$mc.hide();renderminutes(h);if(v){t=e.type=="mouseover"?e.pageY-15:$hourcont.offset().top+2+($obj.height()*i);if(h<12){l=$hourcont.offset().left-$mc.width()-2}else{l=$hourcont.offset().left+$hourcont.width()+2}}else{l=(e.type=="mouseover")?e.pageX-10:$hourcont.offset().left+($obj.width()-5)*i;if(h<12){t=$hourcont.offset().top-$mc.height()-2}else{t=$hourcont.offset().top+$hourcont.height()}}$mc.css("left",l+"px").css("top",t+"px");rectify($mc);$mc.show();if(settings.useBgiframe){bgi($mc)}}return false}function hourdiv_out($obj){$obj.removeClass("CP_over");return false}function hourdiv_click($obj){var h=$obj.attr("id").split("_")[1],tt=set_tt(h),str=$obj.attr("value");if(str.indexOf(" ")!=-1){var cleanstr=str.substring(0,str.indexOf(" "))}else{var cleanstr=str}$obj.text(cleanstr+"00"+settings.second);setval($obj);cleardivs()}function minutediv_over($obj){$obj.addClass("CP_over");return false}function minutediv_out($obj){$obj.removeClass("CP_over");return false}function minutediv_click($obj){$obj.text($obj.attr("value")+settings.second);setval($obj);cleardivs()}function setval($obj){if(!settings.valuefield){self.value=$obj.text()}else{jQuery("input[name="+settings.valuefield+"]").val($obj.text()).change()}callback.apply($self,[$obj.text()]);$self.unbind("keydown",keyhandler)}function cleardivs(){if(settings.showminutes=="true"){$mc.hide()}$hourcont.slideUp("fast");$self.unbind("keydown",keyhandler)}function keyhandler(e){var $obj=$("div.CP_over").size()?$("div.CP_over"):$("div.CP_hour:first"),divtype=$obj.is(".CP_hour")?"hour":"minute",hi=(divtype=="hour")?$obj[0].id.split("_")[2]:0,h=(divtype=="minute")?$obj[0].id.split("_")[0]:$obj[0].id.split("_")[1];if(divtype=="minute"){var curloc=h<12?"m1":"m2"}else{var curloc=h<12?"h1":"h2"}function divprev($obj){if($obj.prev().size()){eval(divtype+"div_out($obj)");eval(divtype+"div_over($obj.prev(), e)")}else{return false}}function divnext($obj){if($obj.next().size()){eval(divtype+"div_out($obj)");eval(divtype+"div_over($obj.next(), e)")}else{return false}}function hourtohour($obj){var ctx=h>=12?"#hourcol1":"#hourcol2";$newobj=jQuery(".CP_hour[id$=_"+hi+"]",ctx);if($newobj.size()){hourdiv_out($obj);hourdiv_over($newobj,e)}else{return false}}function hourtominute($obj){hourdiv_out($obj);minutediv_over($(".CP_minute:first"))}function minutetohour($obj){minutediv_out($obj);var ctx=h>=12?"#hourcol2":"#hourcol1";var $newobj=jQuery(".CP_hour[id^=hr_"+h+"]",ctx);hourdiv_over($newobj,e)}switch(e.keyCode){case 37:if(v){switch(curloc){case"m1":return false;break;case"m2":minutetohour($obj);break;case"h1":hourtominute($obj);break;case"h2":hourtohour($obj);break}}else{divprev($obj)}break;case 38:if(v){divprev($obj)}else{switch(curloc){case"m1":return false;break;case"m2":minutetohour($obj);break;case"h1":hourtominute($obj);break;case"h2":hourtohour($obj);break}}break;case 39:if(v){switch(curloc){case"m1":minutetohour($obj);break;case"m2":return false;break;case"h1":hourtohour($obj);break;case"h2":hourtominute($obj);break}}else{divnext($obj)}break;case 40:if(v){divnext($obj)}else{switch(curloc){case"m1":minutetohour($obj);break;case"m2":return false;break;case"h1":hourtohour($obj);break;case"h2":hourtominute($obj);break}}break;case 13:eval(divtype+"div_click($obj)");break;default:return true}return false}return false});function errorcheck(settings){if(settings.starthour>=settings.endhour){alert("Error - start hour must be less than end hour.");return false}else{if(60%settings.minutedivisions!=0){alert("Error - param minutedivisions must divide evenly into 60.");return false}}}return this};$(function(){if($.fn.ogClockpicker){$(document).ready(function(){$(".clockpick").ogClockpicker()})}});function likeComp(c){var b=c.substring(6);var d=$("#"+c).attr("aimaiType");var a=$("#"+b).val();a=a.replace(/^%+|%+$/g,"");if(a!=""){switch(d){case"1":a=a+"%";break;case"2":a="%"+a;break;case"3":a="%"+a+"%";break}}$("#"+b).val(a)}$(function(){$("form").submit(function(){$("[id^='AIMAI_']").each(function(){likeComp(this.id)})})});$.fn.aimaiPickerOg=function(a){var c={texts:[" V "," V*","*V ","*V*"],titls:["完全一致","前方一致","後方一致","前後曖昧"]};var b=$.extend(c,a);return this.each(function(){var g=$(this);var j="PIC_"+g.attr("id").replace(/-/g,"")+"_";var l="";for(var f=0;f<b.texts.length;f++){var m=b.texts[f];var k=b.titls[f];l+='<span id="'+j+"text-"+f+'" class="text-box"" title="'+k+'">('+m+") </span>"}var h=$('<div id="'+j+'aimai-picker" class="aimai-picker" style="position: absolute; left: 0px; top: 0px;">'+l+'<div style="clear: both;"></div></div>');$("body").append(h);h.hide();h.find("span.text-box").click(function(){var i=this.id.substr(this.id.indexOf("-")+1);g.attr("aimaiType",i);g.attr("title",b.titls[i]);g.text(b.texts[i]);g.blur();d(h)});$("body").live("click",function(){d(h)});h.click(function(i){i.stopPropagation()});var e=function(i){var p=g.offset();var o=p.left+g.outerWidth()-i.outerWidth();if(o<p.left){o=p.left}i.css({left:o,top:(p.top+g.outerHeight())});n(i)};g.click(function(i){i.stopPropagation();if(!g.is("input")){e(h)}});g.focus(function(){e(h)});function d(i){if(b.hideEffect=="fade"){i.fadeOut()}else{if(b.hideEffect=="slide"){i.slideUp()}else{i.hide()}}}function n(i){if(b.showEffect=="fade"){i.fadeIn()}else{if(b.showEffect=="slide"){i.slideDown()}else{i.show()}}}})};$(function(){if($.fn.aimaiPickerOg){$(".aimaiClm").aimaiPickerOg()}});(function(){$.fn.glDatePicker=function(options){var pluginName="glDatePicker";var instance=this.data(pluginName);if(!instance){return this.each(function(){return $(this).data(pluginName,new glDatePicker(this,options))})}return(options===true)?instance:this};$.fn.glDatePicker.defaults={cssName:"default",zIndex:1000,borderSize:1,calendarOffset:{x:0,y:1},showAlways:false,hideOnClick:true,allowMonthSelect:true,allowYearSelect:true,todayDate:new Date(),selectedDate:null,prevArrow:"\u25c4",nextArrow:"\u25ba",selectableDates:null,selectableDateRange:null,specialDates:null,selectableMonths:null,selectableYears:null,selectableDOW:null,monthNames:null,dowNames:null,dowOffset:(HYBS_CAL_START_MON==true?1:0),onClick:(function(el,cell,date,data){var tgt=el;if(el[0].tagName.toUpperCase()!="INPUT"){var _targetId=el.attr("targetId");if(_targetId!=null){tgt=$("#"+_targetId)}}var year=date.getFullYear();var month=date.getMonth()+1;var day=date.getDate();if(month<10){month="0"+month}if(day<10){day="0"+day}var str=year+""+month+""+day;tgt.val(str)}),onHover:function(el,cell,date,data){},onShow:function(calendar){calendar.show()},onHide:function(calendar){calendar.hide()},firstDate:null};var glDatePicker=(function(){function glDatePicker(element,userOptions){var self=this;self.el=$(element);var el=self.el;self.options=$.extend(true,{},$.fn.glDatePicker.defaults,userOptions);var options=self.options;self.calendar=$($.find("[gldp-el="+el.attr("gldp-id")+" ]"));options.selectedDate=options.selectedDate||options.todayDate;options.firstDate=(new Date((options.firstDate||options.selectedDate)))._first();if(!(el.attr("gldp-id")||"").length){el.attr("gldp-id","gldp-"+Math.round(Math.random()*10000000000))}el.addClass("gldp-el").bind("click",function(e){self.show(e)});if(self.calendar.length&&!options.showAlways){self.calendar.hide()}$(document).bind("mouseup",function(e){var target=e.target;var calendar=self.calendar;if(!el.is(target)&&!calendar.is(target)&&calendar.has(target).length===0&&calendar.is(":visible")){self.hide()}})}glDatePicker.prototype={show:function(){this.render();$.each($(".gldp-el").not(this.el),function(i,o){if(o.length){o.options.onHide(o.calendar)}});this.options.onShow(this.calendar)},hide:function(){if(this.options&&!this.options.showAlways){this.options.onHide(this.calendar)}},render:function(renderCalback){var self=this;var el=self.el;var options=self.options;var calendar=self.calendar;var coreClass=" core border ";var cssName="gldp-"+options.cssName;var todayVal=options.todayDate._val();var todayTime=todayVal.time;var maxRow=6;var maxCol=7;var borderSize=options.borderSize+"px";var getSelectableList=function(min,max,userList){var resultList=[];for(var i=min;i<=max;i++){resultList.push(i)}if(userList){var newList=[];$.each(userList,function(i,v){if(v>=min&&v<=max&&newList._indexOf(v)<0){newList.push(v)}});resultList=newList.length?newList:resultList}resultList.sort();return resultList};var selectableMonths=getSelectableList(0,11,options.selectableMonths);var selectableYears=getSelectableList(todayVal.year-5,todayVal.year+5,options.selectableYears);var selectableDOW=getSelectableList(0,6,options.selectableDOW);var dowNames=options.dowNames||["日","月","火","水","木","金","土"];var monthNames=options.monthNames||["1月","2月","3月","4月","5月","6月","7月","8月","9月","10月","11月","12月"];var containerSize=window.innerHeight?window.innerHeight:180;if(containerSize<180){containerSize=(containerSize>135?containerSize:135)}else{containerSize=180}var containerWidth=options.conainerWidth||containerSize;var containerHeight=containerWidth;var getCellSize=function(_size,_count){return(_size/_count)+((options.borderSize/_count)*(_count-1))-1};var cellWidth=getCellSize(containerWidth,maxCol);var cellHeight=getCellSize(containerHeight,maxRow+2);if(!calendar.length){self.calendar=calendar=$("<div/>").attr("gldp-el",el.attr("gldp-id")).data("is",true).css({display:(options.showAlways?undefined:"none"),zIndex:options.zIndex,width:((cellWidth+1)*maxCol)+"px"});$("body").append(calendar)}else{if(!eval(calendar.data("is"))){containerWidth=calendar.outerWidth();containerHeight=calendar.outerHeight();cellWidth=getCellSize(containerWidth,maxCol);cellHeight=getCellSize(containerHeight,maxRow+2)}self.calendar.css({width:((cellWidth+1)*maxCol)+"px"})}if(!el.is(":visible")){calendar.hide()}calendar.removeClass().addClass(cssName).children().remove();var onResize=function(){var elPos=el.offset();calPosTop=(elPos.top+el.outerHeight()+options.calendarOffset.y)-20;calPosLeft=(elPos.left+options.calendarOffset.x);if(calPosTop>$(window).height()-150){calPosTop-=130}if(calPosLeft>$(window).width()-150){calPosLeft-=150}if(calPosTop<0){calPosTop=0}if(calPosLeft<0){calPosLeft=0}calendar.css({top:calPosTop+"px",left:calPosLeft+"px"})};$(window).resize(onResize);onResize();var cellCSS={width:cellWidth+"px",height:cellHeight+"px",lineHeight:cellHeight+"px"};var setFirstDate=function(_date){if(_date){options.firstDate=_date;self.render()}};var getFirstDate=function(_offset){var _date=new Date(options.firstDate);_offset=_offset||0;while(true){_date.setMonth(_date.getMonth()+_offset);_date.setDate(Math.min(1,_date._max()));if(_offset==0){break}var dateVal=_date._val();var dateMonth=dateVal.month;var dateYear=dateVal.year;if(selectableMonths._indexOf(dateMonth)!=-1){if(selectableYears._indexOf(dateYear)!=-1){break}else{if(dateYear<selectableYears[0]||dateYear>selectableYears[selectableYears.length-1]){return null}}}}return _date};var prevFirstDate=getFirstDate(-1);var nextFirstDate=getFirstDate(1);var firstDate=(options.firstDate=getFirstDate());var firstDateVal=firstDate._val();var firstDateMonth=firstDateVal.month;var firstDateYear=firstDateVal.year;var startDate=new Date(firstDate);var dowOffset=Math.abs(Math.min(6,Math.max(0,options.dowOffset)));var startOffset=startDate.getDay()-dowOffset;startOffset=startOffset<1?-7-startOffset:-startOffset;dowNames=(dowNames.concat(dowNames)).slice(dowOffset,dowOffset+7);startDate._add(startOffset);var showPrev=(prevFirstDate);var showNext=(nextFirstDate);var monyearClass=coreClass+"monyear ";var prevCell=$("<div/>").addClass(monyearClass).css($.extend({},cellCSS,{borderWidth:borderSize+" 0 0 "+borderSize})).append($("<a/>").addClass("prev-arrow"+(showPrev?"":"-off")).html(options.prevArrow)).mousedown(function(){return false}).click(function(e){if(options.prevArrow!=""&&showPrev){e.stopPropagation();setFirstDate(prevFirstDate)}});var titleCellCount=maxCol-2;var titleWidth=(cellWidth*titleCellCount)-(titleCellCount*options.borderSize)+(options.borderSize);var titleCell=$("<div/>").addClass(monyearClass+"title").css($.extend({},cellCSS,{width:titleWidth+"px",borderTopWidth:borderSize,marginLeft:"-"+(borderSize)}));var nextCell=$("<div/>").addClass(monyearClass).css($.extend({},cellCSS,{marginLeft:"-"+(borderSize),borderWidth:borderSize+" "+borderSize+" 0 0"})).append($("<a/>").addClass("next-arrow"+(showNext?"":"-off")).html(options.nextArrow)).mousedown(function(){return false}).click(function(e){if(options.nextArrow!=""&&showNext){e.stopPropagation();setFirstDate(nextFirstDate)}});calendar.append(prevCell).append(titleCell).append(nextCell);for(var row=0,cellIndex=0;row<maxRow+1;row++){for(var col=0;col<maxCol;col++,cellIndex++){var cellDate=new Date(startDate);var cellClass="day";var cellZIndex=options.zIndex+(cellIndex);var cell=$("<div/>");if(!row){cellClass="dow";cell.html(dowNames[col]);cellDate=null}else{cellDate._add(col+((row-1)*maxCol));var cellDateVal=cellDate._val();var cellDateTime=cellDateVal.time;var specialData=null;var isSelectable=true;var getRepeatDate=function(v,date){if(v.repeatYear===true){date.setYear(cellDateVal.year)}if(v.repeatMonth===true){date.setMonth(cellDateVal.month)}return date._val()};cell.html(cellDateVal.date);if(options.selectableDateRange){isSelectable=false;$.each(options.selectableDateRange,function(i,v){var dateFrom=v.from;var dateTo=(v.to||null);dateTo=dateTo||new Date(v.from.getFullYear(),v.from.getMonth(),v.from._max());dateFrom=getRepeatDate(v,dateFrom);dateTo=getRepeatDate(v,dateTo);if(cellDateTime>=dateFrom.time&&cellDateTime<=dateTo.time){isSelectable=true;return true}})}if(options.selectableDates){if((options.selectableDateRange&&!isSelectable)||(isSelectable&&!options.selectableDateRange)){isSelectable=false}$.each(options.selectableDates,function(i,v){var vDate=getRepeatDate(v,v.date);if(vDate.time==cellDateTime){return(isSelectable=true)}})}if(!isSelectable||selectableYears._indexOf(cellDateVal.year)<0||selectableMonths._indexOf(cellDateVal.month)<0||selectableDOW._indexOf(cellDateVal.day)<0){cellClass="noday"}else{cellClass=(["sun","mon","tue","wed","thu","fri","sat"])[cellDateVal.day];if(firstDateMonth!=cellDateVal.month){cellClass+=" outday"}if(todayTime==cellDateTime){cellClass="today";cellZIndex+=50}if(options.selectedDate._time()==cellDateTime){cellClass="selected";cellZIndex+=51}if(options.specialDates){$.each(options.specialDates,function(i,v){var vDate=getRepeatDate(v,v.date);if(vDate.time==cellDateTime){cellClass=(v.cssClass||"special");cellZIndex+=52;specialData=v.data}})}cell.mousedown(function(){return false}).hover(function(e){e.stopPropagation();var hoverData=$(this).data("data");options.onHover(el,cell,hoverData.date,hoverData.data)}).click(function(e){e.stopPropagation();var clickedData=$(this).data("data");options.selectedDate=options.firstDate=clickedData.date;self.render(function(){if(!options.showAlways&&options.hideOnClick){self.hide()}});options.onClick(el,$(this),clickedData.date,clickedData.data)})}}$.extend(cellCSS,{borderTopWidth:borderSize,borderBottomWidth:borderSize,borderLeftWidth:(row>0||(!row&&!col))?borderSize:0,borderRightWidth:(row>0||(!row&&col==6))?borderSize:0,marginLeft:(col>0)?"-"+(borderSize):0,marginTop:(row>0)?"-"+(borderSize):0,zIndex:cellZIndex});cell.data("data",{date:cellDate,data:specialData}).addClass(coreClass+cellClass).css(cellCSS);calendar.append(cell)}}var toggleYearMonthSelect=function(showYear){var show="inline-block";var hide="none";if(options.allowMonthSelect){monthText.css({display:!showYear?hide:show});monthSelect.css({display:!showYear?show:hide})}if(options.allowYearSelect){yearText.css({display:showYear?hide:show});yearSelect.css({display:showYear?show:hide})}};var onYearMonthSelect=function(){options.firstDate=new Date(yearSelect.val(),monthSelect.val(),1);self.render()};var monthSelect=$("<select/>").hide().change(onYearMonthSelect);var yearSelect=$("<select/>").hide().change(onYearMonthSelect);var monthText=$("<span/>").html(monthNames[firstDateMonth]).mousedown(function(){return false}).click(function(e){e.stopPropagation();toggleYearMonthSelect(false)});var yearText=$("<span/>").html(firstDateYear).mousedown(function(){return false}).click(function(e){e.stopPropagation();toggleYearMonthSelect(true)});$.each(monthNames,function(i,v){if(options.allowMonthSelect&&selectableMonths._indexOf(i)!=-1){var o=$("<option/>").html(v).attr("value",i);if(i==firstDateMonth){o.attr("selected","selected")}monthSelect.append(o)}});$.each(selectableYears,function(i,v){if(options.allowYearSelect){var o=$("<option/>").html(v).attr("value",v);if(v==firstDateYear){o.attr("selected","selected")}yearSelect.append(o)}});var titleYearMonth=$("<div/>").append(monthText).append(monthSelect).append(yearText).append(yearSelect);titleCell.children().remove();titleCell.append(titleYearMonth);renderCalback=renderCalback||(function(){});renderCalback();var mousewheelevent="onwheel" in document?"wheel":"onmousewheel" in document?"mousewheel":"DOMMouseScroll";calendar.bind(mousewheelevent,function(e){e.preventDefault();var delta=e.originalEvent.deltaY?-(e.originalEvent.deltaY):e.originalEvent.wheelDelta?e.originalEvent.wheelDelta:-(e.originalEvent.detail);if(delta<0){nextCell.click()}else{prevCell.click()}})}};return glDatePicker})();(function(){Date.prototype._clear=function(){this.setHours(0);this.setMinutes(0);this.setSeconds(0);this.setMilliseconds(0);return this};Date.prototype._time=function(){return this._clear().getTime()};Date.prototype._max=function(){var isLeapYear=(new Date(this.getYear(),1,29).getMonth()==1)?1:0;var days=[31,28+isLeapYear,31,30,31,30,31,31,30,31,30,31];return days[this.getMonth()]};Date.prototype._add=function(days){this.setDate(this.getDate()+days)};Date.prototype._first=function(){var date=new Date(this);date.setDate(1);return date};Date.prototype._val=function(){this._clear();return{year:this.getFullYear(),month:this.getMonth(),date:this.getDate(),time:this.getTime(),day:this.getDay()}};Array.prototype._indexOf=function(value){return $.inArray(value,this)}})()})();$(function(){if($.fn.glDatePicker){$(".calPic").glDatePicker()}});function selectScroll(a){var d=4;if(a.getAttribute("size")){d=a.getAttribute("size")}var e=a.options;for(var c=0;c<e.length;c++){if(e[c].selected){if(e[c].parentNode.tagName.toUpperCase()=="OPTGROUP"){c+=$(e[c].parentNode).prev().length}var b=c*($(a).height()/d);break}}$(a).scrollTop(b)}$(function(){$("select[multiple]").each(function(){selectScroll(this)})});
\ No newline at end of file
1+var orgFldCls=null;$(function(){if(USE_FOCUS_HILIGHT){setEvent('textarea,select,input[type="text"]',"focusin",function(){doFocus2(this)});setEvent('textarea,select,input[type="text"]',"focusout",function(){doBlur2(this)})}});function doFocus2(a){if(a!=null){if(a.className==null||a.className.indexOf("must")<0){if(a.tagName=="SELECT"){a.orgBgColor=a.style.backgroundColor;a.style.backgroundColor="#ffcccc"}else{orgFldCls=a.className;a.className="focusField "+orgFldCls}}}}function doBlur2(a){if(a!=null){if(a.className==null||a.className.indexOf("must")<0){if(a.tagName=="SELECT"){a.style.backgroundColor=a.orgBgColor}else{if(orgFldCls!=null){a.className=orgFldCls}else{a.className="notFocusField"}}}}}oldDoFocusFlag=true;function doFocus(a){if(oldDoFocusFlag){oldDoFocusFlag=false;setTimeout(alert("Old Script Error!!\ncustom/query_info.jsp,custom/result_info.jsp Please delete the following part.\n<script>Tag(Header fix and Focus) , BODY onLoad and oncontextmenu Attribute"),100)}}function doBlur(a){}$(function(){setEvent('textarea,select,input[type="text"]',"focusout",function(){convert(this)})});function convert(b){var c,a;c=b.value;a=b.className;if(c!=null&&a!=null){if(a.match(/XL/)&&!(a.match(/XLU/))){b.value=c.toLowerCase()}else{if((a.match(/XU/)&&!(a.match(/XUL/)))||a.match(/PN2/)){b.value=c.toUpperCase()}}}return true}var colMap;var notFireCols;var jH_evElm;$(function(){if(!(typeof(EC_NAME)=="undefined")){jH_evElm=$(".h_evElm");makeColMapping();setEvent('textarea,select,input[type="text"]',"change",function(){makeColumn(this)},".h_evCol",true,addEvColCls);setEvent("input[type=checkbox],input[type=radio]","click",function(){makeColumn(this)},".h_evCol",true)}});function makeColMapping(){var b,a,e,d,c;if(colMap){return}colMap=new Object();for(b=0;b<EC_EVCOL.length;b++){e=EC_EVCOL[b].split(",");for(a=0;a<e.length;a++){d=e[a];if(d.charAt(0)=="_"){d=d.substring(1);if(notFireCols){notFireCols+=","}notFireCols+=d}c=colMap[d];if(!c){c=new Array()}c[c.length]=EC_NAME[b];colMap[d]=c}}}function addEvColCls(){for(var a in colMap){$("#"+a+",[id^="+a+"__]").addClass("h_evCol")}}function makeColumn(e){var k,l,g,j,b,h,d,c,a,f;if(jH_evElm&&isEndInitEvent()){jH_evElm=null}k=$(e);l=k.attr("id");g=l.split("__")[0];j=colMap[g];if(!j){return}if(!isEndInitEvent()&&notFireCols&&notFireCols.indexOf(g)>=0){return}for(b=0;b<j.length;b++){h=(l==g?"":"__"+l.split("__")[1]);d=j[b]+h;c=d.split("__")[0];a=isEndInitEvent()?$(".h_evElm[h_evCid="+d+"]"):jH_evElm.filter("[h_evCid="+d+"]");f=a.attr("h_evWrtbl");eventColumn(k,a,d,c,h,f)}}function eventColumn(jEvCol,jTag,cid,cname,suffix,writable){var evVal,url,param,_pos1,_pos2,_repClm,_rep,_clm,noVal,columnFocus,jCol,val,renderer,editor,ATTRS,optAttrs,i,optAtt,vtype,isAdd;var callback;if(!jTag||jTag.length==0){alert("[SYSTEM_ERROR] : jTag is null. The element of the replacement object doesn't exist. ["+cname+"]");return}if(!isEndInitEvent()){evVal=jEvCol.get(0).value;if(!evVal||evVal==null||evVal==""){return}}try{url=eval("EC_"+cname+"_URL")}catch(e){alert("[SYSTEM_ERROR] : URL that processes the event is not specified. (variable undefinition). ["+cname+"]");return}if(!url||url==""){alert("[SYSTEM_ERROR] : URL that processes the event is not specified. ["+cname+"]");return}param="";try{param=(writable?eval("EC_"+cname+"_EDITPARAM"):eval("EC_"+cname+"_RENDPARAM"))}catch(e){}if(param!=null&&param!=""){url+="?";_pos1=0;_pos2=0;while((_pos1=param.indexOf("{@",_pos2))!=-1){_pos2=param.indexOf("}",_pos1);_clm=param.substring(_pos1+2,_pos2);if(_clm.indexOf(".")<0){_repClm="{@"+_clm+"}";_rep=suffix==""?$("#"+_clm).get(0).value:$("#"+_clm+suffix).get(0).value;_rep=(_rep==null?"":_rep);param=param.replace(_repClm,_rep);url+=_clm+"="+encodeURIComponent(_rep)+"&"}_pos2=_pos1+1}}noVal=function(){_firstOption=jCol.children("option").get(0);if(_firstOption==null||_firstOption.value!=""){return false}return true};columnFocus=function(){jCol.attr("isfocus","true")};if(cid!=null&&cid!=""){jCol=jTag.find("#"+cid)}else{jCol=new Array(0)}if(jCol.length>0&&isEndInitEvent()){jCol.bind("focus",columnFocus)}val="";if(jCol.length>0){if(isEndInitEvent()){val=(jCol.val()==null?"":jCol.val())}else{val=(jTag.attr("h_evVal")==null?"":jTag.attr("h_evVal"))}}renderer="";try{renderer=eval("EC_"+cname+"_RENDERER")}catch(e){}editor="";try{editor=eval("EC_"+cname+"_EDITOR")}catch(e){}ATTRS=["title","style","tabindex","readonly","disabled","onClick","onChange","onBlur","onFocus","ondblClick","onMouseDown","onMouseUp","onMouseMove","onMouseOut","onMouseOver","onSelect","onKeydown","onKeypress","onKeyup","eventCallBack","multiple"];optAttrs="";if(jCol.length>0){for(i=0;i<ATTRS.length;i++){optAtt=jCol.attr(ATTRS[i]);if(optAtt!=null){vtype=typeof(optAtt);isAdd=false;if(vtype=="function"){optAtt=optAtt.toString();isAdd=optAtt.length>0?true:false;optAtt="("+optAtt+")()"}else{if(vtype=="boolean"){isAdd=optAtt}else{isAdd=optAtt.length>0?true:false}}if(isAdd){optAttrs+=ATTRS[i]+"='"+optAtt+"' "}}}}$.ajax({url:url,data:{EC_CID:(cid==null?"":cid),EC_CNAME:(cname==null?"":cname),EC_RENDERER:renderer,EC_EDITOR:editor,EC_PARAM:param,EC_SQL:param,EC_WRITABLE:(writable==null?"":writable),EC_CVALUE:val,EC_NOVALUE:(jCol.length==0?"":noVal()),EC_CLASS:(jCol.length==0?"":jCol.attr("class")),EC_SIZE:(jCol.length==0?"":jCol.attr("size")),EC_MAXLENGTH:(jCol.length==0?"":jCol.attr("maxlength")),EC_OPTATTRS:optAttrs,EC_PNAME:jEvCol.attr("id")==null?"":jEvCol.attr("id").split("__")[0],EC_PVALUE:jEvCol.get(0).value==null?"":jEvCol.get(0).value,EC_USESLBL:(suffix==null||suffix=="")?"false":"true"},type:"POST",dataType:"html",async:isEndInitEvent(),error:function(r,s,e){if(url.indexOf(".htm")<0){alert("EventColumnError:"+r+":"+s+":"+e+":"+cname)}},success:function(data,status){var jNewCol=$(data);if(jCol.length>0){if(isEndInitEvent()){jCol.unbind("focus",columnFocus)}bindOldEvents(jNewCol.get(0),jQuery.data(jCol.clone(true).get(0),"events"))}jTag.empty().append(jNewCol);if(jCol.length>0){jTag.find("input,select,textarea").attr("name",cid).attr("id",cid);if(isEndInitEvent()){if(jCol.attr("isfocus")){jNewCol.get(0).focus();if($.browser.msie){jNewCol.get(0).focus()}}}if(!isEndInitEvent()){jNewCol.change()}if(jCol.attr("eventCallback")){callback=function(){eval(jCol.attr("eventCallback")+"(arguments);")};callback(cid,jNewCol.val(),jCol.get(0).value)}}if(suffix!=null&&suffix!=""){if(isEndInitEvent()){$("table#viewTable").resizeView()}}}})}function bindOldEvents(d,a){var c,b;for(c in a){for(b in a[c]){jQuery.event.add(d,c,a[c][b],a[c][b].data)}}}var isShowTip=false;$(function(){if(USE_REAL_TIME_CHECK){setEvent('textarea,select,input[type="text"]',"focusout",function(){var b=RegExp(/jsp/);var a=location.pathname.match(b);check(this,RegExp.leftContext+"jsp/common/realtimecheck.jsp")});$("table#viewTable").parent().parent().scroll(function(){if(isShowTip){isShowTip=false;$(".tipErr").remove()}})}});function check(f,b){var c,d,h,g,e,j,a,i;c=f.name;if(typeof jQuery!="undefined"&&c.indexOf("h_")!=0){d=f.value;if(f.rtOption!="null"&&f.rtOption!="undefined"){i=f.rtOption}h=c.split("__");g=(2==h.length);e="command=RENEW&checkType="+(g?"ENTRY":"NEW")+(g?"&h_rowSel="+h[1]:"")+"&column="+h[0]+"&"+c+"="+encodeURIComponent(d)+(i?"&"+i:"");j={dataType:"html",type:"POST",url:b,data:e};j.error=function(){};j.success=function(k){a=$(f).data("tipId");$("#"+a).remove();if($.trim(k).indexOf("row_error")>=0){showCheckTip(f,k);isShowTip=true}};$.ajax(j)}return true}function showCheckTip(a,c){var j,i,k,g,e,h,f,d,b;j=$(a);i=j.offset();if(i.top>=30){e="<div class='tipErr'><div id='tipArrowBottom'></div><div>"+c+"</div></div>";h=$(e).appendTo(document.body);f=i.left;d=i.top+(-11-h[0].offsetHeight)}else{e="<div class='tipErr'><div id='tipArrowTop'></div><div>"+c+"</div></div>";h=$(e).appendTo(document.body);f=i.left;d=i.top+11+h[0].offsetHeight}b=(new Date()).getTime();$(a).data("tipId",b);h.css({left:f+"px",top:d+"px"}).attr("id",b).click(function(){$(this).remove()}).show()}$(function(){bindEvents()});$.fn.simpleColorPickerOg=function(a){var c={colorsPerLine:8,colors:["#000000","#444444","#666666","#999999","#cccccc","#eeeeee","#f3f3f3","#ffffff","#ff0000","#ff9900","#ffff00","#00ff00","#00ffff","#0000ff","#9900ff","#ff00ff","#f4cccc","#fce5cd","#fff2cc","#d9ead3","#d0e0e3","#cfe2f3","#d9d2e9","#ead1dc","#ea9999","#f9cb9c","#ffe599","#b6d7a8","#a2c4c9","#9fc5e8","#b4a7d6","#d5a6bd","#e06666","#f6b26b","#ffd966","#93c47d","#76a5af","#6fa8dc","#8e7cc3","#c27ba0","#cc0000","#e69138","#f1c232","#6aa84f","#45818e","#3d85c6","#674ea7","#a64d79","#990000","#b45f06","#bf9000","#38761d","#134f5c","#0b5394","#351c75","#741b47","#660000","#783f04","#7f6000","#274e13","#0c343d","#073763","#20124d","#4C1130"],showEffect:"",hideEffect:"",onChangeColor:false};var b=$.extend(c,a);return this.each(function(){var g=$(this);var l="";var j=g.attr("id").replace(/-/g,"")+"_";for(var f=0;f<b.colors.length;f++){var m=b.colors[f];var k="";if(f%b.colorsPerLine==0){k="clear: both; "}if(f>0&&k&&$.browser&&$.browser.msie&&$.browser.version<=7){k="";l+='<li style="float: none; clear: both; overflow: hidden; background-color: #fff; display: block; height: 1px; line-height: 1px; font-size: 1px; margin-bottom: -2px;"></li>'}l+='<li id="'+j+"color-"+f+'" class="color-box" style="'+k+"background-color: "+m+'" title="'+m+'"></li>'}k="clear: both; ";l+='<li id="'+j+'color-default" class="color-box" style="width:80px; text-align:center; '+k+'background-color:white;" title="clear">clear</li>';var h=$('<div id="'+j+'color-picker" class="color-picker" style="position: absolute; left: 0px; top: 0px;"><ul>'+l+'</ul><div style="clear: both;"></div></div>');$("body").append(h);h.hide();h.find("li.color-box").click(function(){var i=isNaN(this.id.substr(this.id.indexOf("-")+1))?"":b.colors[this.id.substr(this.id.indexOf("-")+1)];if(!g.is("input")){g.val(i);g.blur()}if($.isFunction(c.onChangeColor)){c.onChangeColor.call(g,i)}d(h)});$("body").live("click",function(){d(h)});h.click(function(i){i.stopPropagation()});var e=function(i){var p=g.offset();var o=p.left+g.outerWidth()-i.outerWidth();if(o<p.left){o=p.left}i.css({left:o,top:(p.top+g.outerHeight())});n(i)};g.click(function(i){g=$(this);i.stopPropagation();if(!g.is("input")){e(h)}});g.change(function(i){if(g.val()!=g.css("background-color")){g.css("background-color",g.val()).css("color",g.val())}});g.focus(function(){e(h)});function d(i){if(b.hideEffect=="fade"){i.fadeOut()}else{if(b.hideEffect=="slide"){i.slideUp()}else{i.hide()}}}function n(i){if(b.showEffect=="fade"){i.fadeIn()}else{if(b.showEffect=="slide"){i.slideDown()}else{i.show()}}}})};$(function(){if($.fn.simpleColorPickerOg){$("input.colorPicker").simpleColorPickerOg({onChangeColor:function(a){$(this).val(a).css("background-color",a).css("color",a).change()}})}});jQuery.fn.ogClockpicker=function(options,callback){var org_settings={starthour:6,endhour:20,showminutes:"true",minutedivisions:4,military:true,event:"click",layout:"vertical",valuefield:null,useBgiframe:false,hoursopacity:1,minutesopacity:1,second:""};if(options){jQuery.extend(org_settings,options)}var callback=callback||function(){},v=(org_settings.layout=="vertical");errorcheck(org_settings);jQuery(this)[org_settings.event](function(e){var self=this,$self=jQuery(this),$body=jQuery("body");var settings=jQuery.extend(true,{},org_settings);if($self.attr("valuefield")){settings.valuefield=$self.attr("valuefield")}if($self.attr("starthour")){settings.starthour=parseInt($self.attr("starthour"))}if($self.attr("endhour")){settings.endhour=parseInt($self.attr("endhour"))}if($self.attr("minutedivisions")){settings.minutedivisions=parseInt($self.attr("minutedivisions"))}if($self.attr("military")){settings.military=$self.attr("military")}if($self.attr("showminutes")){settings.showminutes=$self.attr("showminutes")}if($self.attr("usesecond")=="true"){settings.second="00"}if($self.attr("layout")){settings.layout=$self.attr("layout");org_settings.layout=settings.layout;v=(settings.layout=="vertical")}errorcheck(settings);if(!settings.valuefield){$self.unbind("keydown").bind("keydown",keyhandler)}else{var inputfield=jQuery("[name="+settings.valuefield+"]");inputfield.unbind("keydown").bind("keydown",keyhandler)[0].focus();inputfield.bind("click",function(){inputfield.unbind("keydown")})}jQuery("#CP_hourcont,#CP_minutecont").remove();var $hourcont=jQuery("<div id='CP_hourcont' class='CP' />").appendTo($body);!settings.useBgiframe?$hourcont.css("opacity",settings.hoursopacity):null;binder($hourcont);var $hourcol1=jQuery("<div class='CP_hourcol' id='hourcol1' />").appendTo($body);var $hourcol2=jQuery("<div class='CP_hourcol' id='hourcol2' />").appendTo($body);if(settings.showminutes=="true"){var $mc=jQuery("<div id='CP_minutecont' class='CP' />").appendTo($body);!settings.useBgiframe?$mc.css("opacity",settings.minutesopacity):null;binder($mc)}if(!v){$hourcont.css("width","auto");if(settings.showminutes=="true"){$mc.css("width","auto")}}else{$hourcol1.addClass("floatleft");$hourcol2.addClass("floatleft")}renderhours();putcontainer();function renderhours(){var c=1;for(var h=settings.starthour;h<=settings.endhour;h++){if(h==12){c=1}var displayhours=((!settings.military&&h>12)?h-12:h);var valuehouers=h;if(!settings.military&&h==0){}else{if(!settings.military&&h==12){displayhours="0"}}if(settings.military&&h<10){displayhours="0"+displayhours}if(h<10){valuehouers="0"+valuehouers}var $hd=jQuery("<div class='CP_hour' id='hr_"+h+"_"+c+"' value='"+valuehouers+"' >"+displayhours+set_tt(h)+"</div>");if(settings.military){$hd.width(20)}binder($hd);if(!v){$hd.css("float","left")}(h<12)?$hourcol1.append($hd):$hourcol2.append($hd);c++}$hourcont.append($hourcol1);!v?$hourcont.append("<div style='clear:left' />"):"";$hourcont.append($hourcol2)}function renderminutes(h){var realhours=h;var displayhours=(!settings.military&&h>12)?h-12:h;var valuehouers=h;if(!settings.military&&h==0){}else{if(!settings.military&&h==12){displayhours="0"}}if(settings.military&&h<10){displayhours="0"+displayhours}if(h<10){valuehouers="0"+valuehouers}$mc.empty();var n=60/settings.minutedivisions,tt=set_tt(realhours),counter=1;for(var m=0;m<60;m=m+n){$md=jQuery("<div class='CP_minute' id='"+realhours+"_"+m+"' value='"+valuehouers+((m<10)?"0":"")+m+"'>"+displayhours+":"+((m<10)?"0":"")+m+tt+"</div>");if(!v){$md.css("float","left");if(settings.minutedivisions>6&&counter==settings.minutedivisions/2+1){$mc.append("<div style='clear:left' />")}}$mc.append($md);binder($md);counter++}}function set_tt(realhours){if(!settings.military){return(realhours>=12)?" PM":" AM"}else{return""}}function putcontainer(){if(e.type!="focus"){$hourcont[0].style.left=e.pageX-5+"px";$hourcont[0].style.top=e.pageY-(Math.floor($hourcont.height()/2))+"px";rectify($hourcont)}else{$self.after($hourcont)}$hourcont.slideDown("fast");if(settings.useBgiframe){bgi($hourcont)}}function rectify($obj){var ph=document.documentElement.clientHeight?document.documentElement.clientHeight:document.body.clientHeight;var pw=document.documentElement.clientWidth?document.documentElement.clientWidth:document.body.clientWidth;var t=parseInt($obj[0].style.top);var l=parseInt($obj[0].style.left);var st=document.documentElement.scrollTop?document.documentElement.scrollTop:document.body.scrollTop;if(t<=st&&!$obj.is("#CP_minutecont")){$obj.css("top",st+10+"px")}else{if(t+$obj.height()-st>ph){$obj.css("top",st+ph-$obj.height()-10+"px")}}if(l<=0){$obj.css("left","10px")}}function bgi(ob){if(typeof jQuery.fn.bgIframe=="function"){ob.bgIframe()}else{alert("bgIframe plugin not loaded.")}}function binder($obj){if($obj.attr("id")=="CP_hourcont"){$obj.mouseout(function(e){hourcont_out(e)})}else{if($obj.attr("id")=="CP_minutecont"){$obj.mouseout(function(e){minutecont_out(e)})}else{if($obj.attr("class")=="CP_hour"){$obj.mouseover(function(e){hourdiv_over($obj,e)});$obj.mouseout(function(){hourdiv_out($obj)});$obj.click(function(){hourdiv_click($obj)})}else{if($obj.attr("class")=="CP_minute"){$obj.mouseover(function(){minutediv_over($obj)});$obj.mouseout(function(){minutediv_out($obj)});$obj.click(function(){minutediv_click($obj)})}}}}}function hourcont_out(e){try{var t=(e.toElement)?e.toElement:e.relatedTarget;if(!(jQuery(t).is("div[class^=CP], iframe"))){cleardivs()}}catch(e){cleardivs()}}function minutecont_out(e){try{var t=(e.toElement)?e.toElement:e.relatedTarget;if(!(jQuery(t).is("div[class^=CP], iframe"))){cleardivs()}}catch(e){cleardivs()}}function hourdiv_over($obj,e){var h=$obj.attr("id").split("_")[1],i=$obj.attr("id").split("_")[2],l,t;$obj.addClass("CP_over");if(settings.showminutes=="true"){$mc.hide();renderminutes(h);if(v){t=e.type=="mouseover"?e.pageY-15:$hourcont.offset().top+2+($obj.height()*i);if(h<12){l=$hourcont.offset().left-$mc.width()-2}else{l=$hourcont.offset().left+$hourcont.width()+2}}else{l=(e.type=="mouseover")?e.pageX-10:$hourcont.offset().left+($obj.width()-5)*i;if(h<12){t=$hourcont.offset().top-$mc.height()-2}else{t=$hourcont.offset().top+$hourcont.height()}}$mc.css("left",l+"px").css("top",t+"px");rectify($mc);$mc.show();if(settings.useBgiframe){bgi($mc)}}return false}function hourdiv_out($obj){$obj.removeClass("CP_over");return false}function hourdiv_click($obj){var h=$obj.attr("id").split("_")[1],tt=set_tt(h),str=$obj.attr("value");if(str.indexOf(" ")!=-1){var cleanstr=str.substring(0,str.indexOf(" "))}else{var cleanstr=str}$obj.text(cleanstr+"00"+settings.second);setval($obj);cleardivs()}function minutediv_over($obj){$obj.addClass("CP_over");return false}function minutediv_out($obj){$obj.removeClass("CP_over");return false}function minutediv_click($obj){$obj.text($obj.attr("value")+settings.second);setval($obj);cleardivs()}function setval($obj){if(!settings.valuefield){self.value=$obj.text()}else{jQuery("input[name="+settings.valuefield+"]").val($obj.text()).change()}callback.apply($self,[$obj.text()]);$self.unbind("keydown",keyhandler)}function cleardivs(){if(settings.showminutes=="true"){$mc.hide()}$hourcont.slideUp("fast");$self.unbind("keydown",keyhandler)}function keyhandler(e){var $obj=$("div.CP_over").size()?$("div.CP_over"):$("div.CP_hour:first"),divtype=$obj.is(".CP_hour")?"hour":"minute",hi=(divtype=="hour")?$obj[0].id.split("_")[2]:0,h=(divtype=="minute")?$obj[0].id.split("_")[0]:$obj[0].id.split("_")[1];if(divtype=="minute"){var curloc=h<12?"m1":"m2"}else{var curloc=h<12?"h1":"h2"}function divprev($obj){if($obj.prev().size()){eval(divtype+"div_out($obj)");eval(divtype+"div_over($obj.prev(), e)")}else{return false}}function divnext($obj){if($obj.next().size()){eval(divtype+"div_out($obj)");eval(divtype+"div_over($obj.next(), e)")}else{return false}}function hourtohour($obj){var ctx=h>=12?"#hourcol1":"#hourcol2";$newobj=jQuery(".CP_hour[id$=_"+hi+"]",ctx);if($newobj.size()){hourdiv_out($obj);hourdiv_over($newobj,e)}else{return false}}function hourtominute($obj){hourdiv_out($obj);minutediv_over($(".CP_minute:first"))}function minutetohour($obj){minutediv_out($obj);var ctx=h>=12?"#hourcol2":"#hourcol1";var $newobj=jQuery(".CP_hour[id^=hr_"+h+"]",ctx);hourdiv_over($newobj,e)}switch(e.keyCode){case 37:if(v){switch(curloc){case"m1":return false;break;case"m2":minutetohour($obj);break;case"h1":hourtominute($obj);break;case"h2":hourtohour($obj);break}}else{divprev($obj)}break;case 38:if(v){divprev($obj)}else{switch(curloc){case"m1":return false;break;case"m2":minutetohour($obj);break;case"h1":hourtominute($obj);break;case"h2":hourtohour($obj);break}}break;case 39:if(v){switch(curloc){case"m1":minutetohour($obj);break;case"m2":return false;break;case"h1":hourtohour($obj);break;case"h2":hourtominute($obj);break}}else{divnext($obj)}break;case 40:if(v){divnext($obj)}else{switch(curloc){case"m1":minutetohour($obj);break;case"m2":return false;break;case"h1":hourtohour($obj);break;case"h2":hourtominute($obj);break}}break;case 13:eval(divtype+"div_click($obj)");break;default:return true}return false}return false});function errorcheck(settings){if(settings.starthour>=settings.endhour){alert("Error - start hour must be less than end hour.");return false}else{if(60%settings.minutedivisions!=0){alert("Error - param minutedivisions must divide evenly into 60.");return false}}}return this};$(function(){if($.fn.ogClockpicker){$(document).ready(function(){$(".clockpick").ogClockpicker()})}});function likeComp(c){var b=c.substring(6);var d=$("#"+c).attr("aimaiType");var a=$("#"+b).val();a=a.replace(/^%+|%+$/g,"");if(a!=""){switch(d){case"1":a=a+"%";break;case"2":a="%"+a;break;case"3":a="%"+a+"%";break}}$("#"+b).val(a)}$(function(){$("form").submit(function(){$("[id^='AIMAI_']").each(function(){likeComp(this.id)})})});$.fn.aimaiPickerOg=function(a){var c={texts:[" V "," V*","*V ","*V*"],titls:["完全一致","前方一致","後方一致","前後曖昧"]};var b=$.extend(c,a);return this.each(function(){var g=$(this);var j="PIC_"+g.attr("id").replace(/-/g,"")+"_";var l="";for(var f=0;f<b.texts.length;f++){var m=b.texts[f];var k=b.titls[f];l+='<span id="'+j+"text-"+f+'" class="text-box"" title="'+k+'">('+m+") </span>"}var h=$('<div id="'+j+'aimai-picker" class="aimai-picker" style="position: absolute; left: 0px; top: 0px;">'+l+'<div style="clear: both;"></div></div>');$("body").append(h);h.hide();h.find("span.text-box").click(function(){var i=this.id.substr(this.id.indexOf("-")+1);g.attr("aimaiType",i);g.attr("title",b.titls[i]);g.text(b.texts[i]);g.blur();d(h)});$("body").live("click",function(){d(h)});h.click(function(i){i.stopPropagation()});var e=function(i){var p=g.offset();var o=p.left+g.outerWidth()-i.outerWidth();if(o<p.left){o=p.left}i.css({left:o,top:(p.top+g.outerHeight())});n(i)};g.click(function(i){i.stopPropagation();if(!g.is("input")){e(h)}});g.focus(function(){e(h)});function d(i){if(b.hideEffect=="fade"){i.fadeOut()}else{if(b.hideEffect=="slide"){i.slideUp()}else{i.hide()}}}function n(i){if(b.showEffect=="fade"){i.fadeIn()}else{if(b.showEffect=="slide"){i.slideDown()}else{i.show()}}}})};$(function(){if($.fn.aimaiPickerOg){$(".aimaiClm").aimaiPickerOg()}});(function(){$.fn.glDatePicker=function(options){var pluginName="glDatePicker";var instance=this.data(pluginName);if(!instance){return this.each(function(){return $(this).data(pluginName,new glDatePicker(this,options))})}return(options===true)?instance:this};$.fn.glDatePicker.defaults={cssName:"default",zIndex:1000,borderSize:1,calendarOffset:{x:0,y:1},showAlways:false,hideOnClick:true,allowMonthSelect:true,allowYearSelect:true,todayDate:new Date(),selectedDate:null,prevArrow:"\u25c4",nextArrow:"\u25ba",selectableDates:null,selectableDateRange:null,specialDates:null,selectableMonths:null,selectableYears:null,selectableDOW:null,monthNames:null,dowNames:null,dowOffset:(HYBS_CAL_START_MON==true?1:0),onClick:(function(el,cell,date,data){var tgt=el;if(el[0].tagName.toUpperCase()!="INPUT"){var _targetId=el.attr("targetId");if(_targetId!=null){tgt=$("#"+_targetId)}}var year=date.getFullYear();var month=date.getMonth()+1;var day=date.getDate();if(month<10){month="0"+month}if(day<10){day="0"+day}var str=year+""+month+""+day;tgt.val(str)}),onHover:function(el,cell,date,data){},onShow:function(calendar){calendar.show()},onHide:function(calendar){calendar.hide()},firstDate:null};var glDatePicker=(function(){function glDatePicker(element,userOptions){var self=this;self.el=$(element);var el=self.el;self.options=$.extend(true,{},$.fn.glDatePicker.defaults,userOptions);var options=self.options;var _tgt=el;if(el[0].tagName.toUpperCase()!="INPUT"){if(el.attr("targetId")){_tgt=$("#"+el.attr("targetId"))}}var _inputDate=_tgt.val();if(_inputDate!=null){_inputDate=_inputDate.replace(/\u002f/g,"");try{_inputDate=_inputDate.substr(0,4)+"/"+_inputDate.substr(4,2)+"/"+_inputDate.substr(6,2)}catch(e){_inputDate=null}}self.calendar=$($.find("[gldp-el="+el.attr("gldp-id")+" ]"));options.selectedDate=(options.selectedDate||new Date(_inputDate))||options.todayDate;options.firstDate=(new Date((options.firstDate||options.selectedDate)))._first();if(!(el.attr("gldp-id")||"").length){el.attr("gldp-id","gldp-"+Math.round(Math.random()*10000000000))}el.addClass("gldp-el").bind("click",function(e){self.show(e)});if(self.calendar.length&&!options.showAlways){self.calendar.hide()}$(document).bind("mouseup",function(e){var target=e.target;var calendar=self.calendar;if(!el.is(target)&&!calendar.is(target)&&calendar.has(target).length===0&&calendar.is(":visible")){self.hide()}})}glDatePicker.prototype={show:function(){this.render();$.each($(".gldp-el").not(this.el),function(i,o){if(o.length){o.options.onHide(o.calendar)}});this.options.onShow(this.calendar)},hide:function(){if(this.options&&!this.options.showAlways){this.options.onHide(this.calendar)}},render:function(renderCalback){var self=this;var el=self.el;var options=self.options;var calendar=self.calendar;var coreClass=" core border ";var cssName="gldp-"+options.cssName;var todayVal=options.todayDate._val();var todayTime=todayVal.time;var maxRow=6;var maxCol=7;var borderSize=options.borderSize+"px";var getSelectableList=function(min,max,userList){var resultList=[];for(var i=min;i<=max;i++){resultList.push(i)}if(userList){var newList=[];$.each(userList,function(i,v){if(v>=min&&v<=max&&newList._indexOf(v)<0){newList.push(v)}});resultList=newList.length?newList:resultList}resultList.sort();return resultList};var selectableMonths=getSelectableList(0,11,options.selectableMonths);var selectableYears=getSelectableList(todayVal.year-5,todayVal.year+5,options.selectableYears);var selectableDOW=getSelectableList(0,6,options.selectableDOW);var dowNames=options.dowNames||["日","月","火","水","木","金","土"];var monthNames=options.monthNames||["1月","2月","3月","4月","5月","6月","7月","8月","9月","10月","11月","12月"];var containerSize=window.innerHeight?window.innerHeight:180;if(containerSize<180){containerSize=(containerSize>135?containerSize:135)}else{containerSize=180}var containerWidth=options.conainerWidth||containerSize;var containerHeight=containerWidth;var getCellSize=function(_size,_count){return(_size/_count)+((options.borderSize/_count)*(_count-1))-1};var cellWidth=getCellSize(containerWidth,maxCol);var cellHeight=getCellSize(containerHeight,maxRow+2);if(!calendar.length){self.calendar=calendar=$("<div/>").attr("gldp-el",el.attr("gldp-id")).data("is",true).css({display:(options.showAlways?undefined:"none"),zIndex:options.zIndex,width:((cellWidth+1)*maxCol)+"px"});$("body").append(calendar)}else{if(!eval(calendar.data("is"))){containerWidth=calendar.outerWidth();containerHeight=calendar.outerHeight();cellWidth=getCellSize(containerWidth,maxCol);cellHeight=getCellSize(containerHeight,maxRow+2)}self.calendar.css({width:((cellWidth+1)*maxCol)+"px"})}if(!el.is(":visible")){calendar.hide()}calendar.removeClass().addClass(cssName).children().remove();var onResize=function(){var elPos=el.offset();calPosTop=(elPos.top+el.outerHeight()+options.calendarOffset.y)-20;calPosLeft=(elPos.left+options.calendarOffset.x);if(calPosTop>$(window).height()-150){calPosTop-=130}if(calPosLeft>$(window).width()-150){calPosLeft-=150}if(calPosTop<0){calPosTop=0}if(calPosLeft<0){calPosLeft=0}calendar.css({top:calPosTop+"px",left:calPosLeft+"px"})};$(window).resize(onResize);onResize();var cellCSS={width:cellWidth+"px",height:cellHeight+"px",lineHeight:cellHeight+"px"};var setFirstDate=function(_date){if(_date){options.firstDate=_date;self.render()}};var getFirstDate=function(_offset){var _date=new Date(options.firstDate);_offset=_offset||0;while(true){_date.setMonth(_date.getMonth()+_offset);_date.setDate(Math.min(1,_date._max()));if(_offset==0){break}var dateVal=_date._val();var dateMonth=dateVal.month;var dateYear=dateVal.year;if(selectableMonths._indexOf(dateMonth)!=-1){if(selectableYears._indexOf(dateYear)!=-1){break}else{if(dateYear<selectableYears[0]||dateYear>selectableYears[selectableYears.length-1]){return null}}}}return _date};var prevFirstDate=getFirstDate(-1);var nextFirstDate=getFirstDate(1);var firstDate=(options.firstDate=getFirstDate());var firstDateVal=firstDate._val();var firstDateMonth=firstDateVal.month;var firstDateYear=firstDateVal.year;var startDate=new Date(firstDate);var dowOffset=Math.abs(Math.min(6,Math.max(0,options.dowOffset)));var startOffset=startDate.getDay()-dowOffset;startOffset=startOffset<1?-7-startOffset:-startOffset;dowNames=(dowNames.concat(dowNames)).slice(dowOffset,dowOffset+7);startDate._add(startOffset);var showPrev=(prevFirstDate);var showNext=(nextFirstDate);var monyearClass=coreClass+"monyear ";var prevCell=$("<div/>").addClass(monyearClass).css($.extend({},cellCSS,{borderWidth:borderSize+" 0 0 "+borderSize})).append($("<a/>").addClass("prev-arrow"+(showPrev?"":"-off")).html(options.prevArrow)).mousedown(function(){return false}).click(function(e){if(options.prevArrow!=""&&showPrev){e.stopPropagation();setFirstDate(prevFirstDate)}});var titleCellCount=maxCol-2;var titleWidth=(cellWidth*titleCellCount)-(titleCellCount*options.borderSize)+(options.borderSize);var titleCell=$("<div/>").addClass(monyearClass+"title").css($.extend({},cellCSS,{width:titleWidth+"px",borderTopWidth:borderSize,marginLeft:"-"+(borderSize)}));var nextCell=$("<div/>").addClass(monyearClass).css($.extend({},cellCSS,{marginLeft:"-"+(borderSize),borderWidth:borderSize+" "+borderSize+" 0 0"})).append($("<a/>").addClass("next-arrow"+(showNext?"":"-off")).html(options.nextArrow)).mousedown(function(){return false}).click(function(e){if(options.nextArrow!=""&&showNext){e.stopPropagation();setFirstDate(nextFirstDate)}});calendar.append(prevCell).append(titleCell).append(nextCell);for(var row=0,cellIndex=0;row<maxRow+1;row++){for(var col=0;col<maxCol;col++,cellIndex++){var cellDate=new Date(startDate);var cellClass="day";var cellZIndex=options.zIndex+(cellIndex);var cell=$("<div/>");if(!row){cellClass="dow";cell.html(dowNames[col]);cellDate=null}else{cellDate._add(col+((row-1)*maxCol));var cellDateVal=cellDate._val();var cellDateTime=cellDateVal.time;var specialData=null;var isSelectable=true;var getRepeatDate=function(v,date){if(v.repeatYear===true){date.setYear(cellDateVal.year)}if(v.repeatMonth===true){date.setMonth(cellDateVal.month)}return date._val()};cell.html(cellDateVal.date);if(options.selectableDateRange){isSelectable=false;$.each(options.selectableDateRange,function(i,v){var dateFrom=v.from;var dateTo=(v.to||null);dateTo=dateTo||new Date(v.from.getFullYear(),v.from.getMonth(),v.from._max());dateFrom=getRepeatDate(v,dateFrom);dateTo=getRepeatDate(v,dateTo);if(cellDateTime>=dateFrom.time&&cellDateTime<=dateTo.time){isSelectable=true;return true}})}if(options.selectableDates){if((options.selectableDateRange&&!isSelectable)||(isSelectable&&!options.selectableDateRange)){isSelectable=false}$.each(options.selectableDates,function(i,v){var vDate=getRepeatDate(v,v.date);if(vDate.time==cellDateTime){return(isSelectable=true)}})}if(!isSelectable||selectableYears._indexOf(cellDateVal.year)<0||selectableMonths._indexOf(cellDateVal.month)<0||selectableDOW._indexOf(cellDateVal.day)<0){cellClass="noday"}else{cellClass=(["sun","mon","tue","wed","thu","fri","sat"])[cellDateVal.day];if(firstDateMonth!=cellDateVal.month){cellClass+=" outday"}if(todayTime==cellDateTime){cellClass="today";cellZIndex+=50}if(options.selectedDate._time()==cellDateTime){cellClass="selected";cellZIndex+=51}if(options.specialDates){$.each(options.specialDates,function(i,v){var vDate=getRepeatDate(v,v.date);if(vDate.time==cellDateTime){cellClass=(v.cssClass||"special");cellZIndex+=52;specialData=v.data}})}cell.mousedown(function(){return false}).hover(function(e){e.stopPropagation();var hoverData=$(this).data("data");options.onHover(el,cell,hoverData.date,hoverData.data)}).click(function(e){e.stopPropagation();var clickedData=$(this).data("data");options.selectedDate=options.firstDate=clickedData.date;self.render(function(){if(!options.showAlways&&options.hideOnClick){self.hide()}});options.onClick(el,$(this),clickedData.date,clickedData.data)})}}$.extend(cellCSS,{borderTopWidth:borderSize,borderBottomWidth:borderSize,borderLeftWidth:(row>0||(!row&&!col))?borderSize:0,borderRightWidth:(row>0||(!row&&col==6))?borderSize:0,marginLeft:(col>0)?"-"+(borderSize):0,marginTop:(row>0)?"-"+(borderSize):0,zIndex:cellZIndex});cell.data("data",{date:cellDate,data:specialData}).addClass(coreClass+cellClass).css(cellCSS);calendar.append(cell)}}var toggleYearMonthSelect=function(showYear){var show="inline-block";var hide="none";if(options.allowMonthSelect){monthText.css({display:!showYear?hide:show});monthSelect.css({display:!showYear?show:hide})}if(options.allowYearSelect){yearText.css({display:showYear?hide:show});yearSelect.css({display:showYear?show:hide})}};var onYearMonthSelect=function(){options.firstDate=new Date(yearSelect.val(),monthSelect.val(),1);self.render()};var monthSelect=$("<select/>").hide().change(onYearMonthSelect);var yearSelect=$("<select/>").hide().change(onYearMonthSelect);var monthText=$("<span/>").html(monthNames[firstDateMonth]).mousedown(function(){return false}).click(function(e){e.stopPropagation();toggleYearMonthSelect(false)});var yearText=$("<span/>").html(firstDateYear).mousedown(function(){return false}).click(function(e){e.stopPropagation();toggleYearMonthSelect(true)});$.each(monthNames,function(i,v){if(options.allowMonthSelect&&selectableMonths._indexOf(i)!=-1){var o=$("<option/>").html(v).attr("value",i);if(i==firstDateMonth){o.attr("selected","selected")}monthSelect.append(o)}});$.each(selectableYears,function(i,v){if(options.allowYearSelect){var o=$("<option/>").html(v).attr("value",v);if(v==firstDateYear){o.attr("selected","selected")}yearSelect.append(o)}});var titleYearMonth=$("<div/>").append(monthText).append(monthSelect).append(yearText).append(yearSelect);titleCell.children().remove();titleCell.append(titleYearMonth);renderCalback=renderCalback||(function(){});renderCalback();var mousewheelevent="onwheel" in document?"wheel":"onmousewheel" in document?"mousewheel":"DOMMouseScroll";calendar.bind(mousewheelevent,function(e){e.preventDefault();var delta=e.originalEvent.deltaY?-(e.originalEvent.deltaY):e.originalEvent.wheelDelta?e.originalEvent.wheelDelta:-(e.originalEvent.detail);if(delta<0){nextCell.click()}else{prevCell.click()}})}};return glDatePicker})();(function(){Date.prototype._clear=function(){this.setHours(0);this.setMinutes(0);this.setSeconds(0);this.setMilliseconds(0);return this};Date.prototype._time=function(){return this._clear().getTime()};Date.prototype._max=function(){var isLeapYear=(new Date(this.getYear(),1,29).getMonth()==1)?1:0;var days=[31,28+isLeapYear,31,30,31,30,31,31,30,31,30,31];return days[this.getMonth()]};Date.prototype._add=function(days){this.setDate(this.getDate()+days)};Date.prototype._first=function(){var date=new Date(this);date.setDate(1);return date};Date.prototype._val=function(){this._clear();return{year:this.getFullYear(),month:this.getMonth(),date:this.getDate(),time:this.getTime(),day:this.getDay()}};Array.prototype._indexOf=function(value){return $.inArray(value,this)}})()})();$(function(){if($.fn.glDatePicker){$(".calPic").glDatePicker()}});function selectScroll(a){var d=4;if(a.getAttribute("size")){d=a.getAttribute("size")}var e=a.options;for(var c=0;c<e.length;c++){if(e[c].selected){if(e[c].parentNode.tagName.toUpperCase()=="OPTGROUP"){c+=$(e[c].parentNode).prev().length}var b=c*($(a).height()/d);break}}$(a).scrollTop(b)}$(function(){$("select[multiple]").each(function(){selectScroll(this)})});
\ No newline at end of file
Show on old repository browser