var JSON = {
copyright: '(c)2005 JSON.org',
license: 'http://www.crockford.com/JSON/license.html',
stringify: function (v) {
var a = [];


function e(s) {
a[a.length] = s;
}

function g(x) {
var c, i, l, v;

switch (typeof x) {
case 'object':
if (x) {
if (x instanceof Array) {
e('[');
l = a.length;
for (i = 0; i < x.length; i += 1) {
v = x[i];
if (typeof v != 'undefined' &&
typeof v != 'function') {
if (l < a.length) {
e(',');
}
g(v);
}
}
e(']');
return;
} else if (typeof x.valueOf == 'function') {
e('{');
l = a.length;
for (i in x) {
v = x[i];
if (typeof v != 'undefined' &&
typeof v != 'function' &&
(!v || typeof v != 'object' ||
typeof v.valueOf == 'function')) {
if (l < a.length) {
e(',');
}
g(i);
e(':');
g(v);
}
}
return e('}');
}
}
e('null');
return;
case 'number':
e(isFinite(x) ? +x : 'null');
return;
case 'string':
l = x.length;
e('"');
for (i = 0; i < l; i += 1) {
c = x.charAt(i);
if (c >= ' ') {
if (c == '\\' || c == '"') {
e('\\');
}
e(c);
} else {
switch (c) {
case '\b':
e('\\b');
break;
case '\f':
e('\\f');
break;
case '\n':
e('\\n');
break;
case '\r':
e('\\r');
break;
case '\t':
e('\\t');
break;
default:
c = c.charCodeAt();
e('\\u00' + Math.floor(c / 16).toString(16) +
(c % 16).toString(16));
}
}
}
e('"');
return;
case 'boolean':
e(String(x));
return;
default:
e('null');
return;
}
}
g(v);
return a.join('');
},
parse: function (text) {
return (/^(\s+|[,:{}\[\]]|"(\\["\\\/bfnrtu]|[^\x00-\x1f"\\]+)*"|-?\d+(\.\d*)?([eE][+-]?\d+)?|true|false|null)+$/.test(text)) &&
eval('(' + text + ')');
}
};
/*
 * jQuery JavaScript Library v1.3.2
 * http://jquery.com/
 *
 * Copyright (c) 2009 John Resig
 * Dual licensed under the MIT and GPL licenses.
 * http://docs.jquery.com/License
 *
 * Date: 2009-02-19 17:34:21 -0500 (Thu, 19 Feb 2009)
 * Revision: 6246
 */
(function(){var l=this,g,y=l.jQuery,p=l.$,o=l.jQuery=l.$=function(E,F){return new o.fn.init(E,F)},D=/^[^<]*(<(.|\s)+>)[^>]*$|^#([\w-]+)$/,f=/^.[^:#\[\.,]*$/;o.fn=o.prototype={init:function(E,H){E=E||document;if(E.nodeType){this[0]=E;this.length=1;this.context=E;return this}if(typeof E==="string"){var G=D.exec(E);if(G&&(G[1]||!H)){if(G[1]){E=o.clean([G[1]],H)}else{var I=document.getElementById(G[3]);if(I&&I.id!=G[3]){return o().find(E)}var F=o(I||[]);F.context=document;F.selector=E;return F}}else{return o(H).find(E)}}else{if(o.isFunction(E)){return o(document).ready(E)}}if(E.selector&&E.context){this.selector=E.selector;this.context=E.context}return this.setArray(o.isArray(E)?E:o.makeArray(E))},selector:"",jquery:"1.3.2",size:function(){return this.length},get:function(E){return E===g?Array.prototype.slice.call(this):this[E]},pushStack:function(F,H,E){var G=o(F);G.prevObject=this;G.context=this.context;if(H==="find"){G.selector=this.selector+(this.selector?" ":"")+E}else{if(H){G.selector=this.selector+"."+H+"("+E+")"}}return G},setArray:function(E){this.length=0;Array.prototype.push.apply(this,E);return this},each:function(F,E){return o.each(this,F,E)},index:function(E){return o.inArray(E&&E.jquery?E[0]:E,this)},attr:function(F,H,G){var E=F;if(typeof F==="string"){if(H===g){return this[0]&&o[G||"attr"](this[0],F)}else{E={};E[F]=H}}return this.each(function(I){for(F in E){o.attr(G?this.style:this,F,o.prop(this,E[F],G,I,F))}})},css:function(E,F){if((E=="width"||E=="height")&&parseFloat(F)<0){F=g}return this.attr(E,F,"curCSS")},text:function(F){if(typeof F!=="object"&&F!=null){return this.empty().append((this[0]&&this[0].ownerDocument||document).createTextNode(F))}var E="";o.each(F||this,function(){o.each(this.childNodes,function(){if(this.nodeType!=8){E+=this.nodeType!=1?this.nodeValue:o.fn.text([this])}})});return E},wrapAll:function(E){if(this[0]){var F=o(E,this[0].ownerDocument).clone();if(this[0].parentNode){F.insertBefore(this[0])}F.map(function(){var G=this;while(G.firstChild){G=G.firstChild}return G}).append(this)}return this},wrapInner:function(E){return this.each(function(){o(this).contents().wrapAll(E)})},wrap:function(E){return this.each(function(){o(this).wrapAll(E)})},append:function(){return this.domManip(arguments,true,function(E){if(this.nodeType==1){this.appendChild(E)}})},prepend:function(){return this.domManip(arguments,true,function(E){if(this.nodeType==1){this.insertBefore(E,this.firstChild)}})},before:function(){return this.domManip(arguments,false,function(E){this.parentNode.insertBefore(E,this)})},after:function(){return this.domManip(arguments,false,function(E){this.parentNode.insertBefore(E,this.nextSibling)})},end:function(){return this.prevObject||o([])},push:[].push,sort:[].sort,splice:[].splice,find:function(E){if(this.length===1){var F=this.pushStack([],"find",E);F.length=0;o.find(E,this[0],F);return F}else{return this.pushStack(o.unique(o.map(this,function(G){return o.find(E,G)})),"find",E)}},clone:function(G){var E=this.map(function(){if(!o.support.noCloneEvent&&!o.isXMLDoc(this)){var I=this.outerHTML;if(!I){var J=this.ownerDocument.createElement("div");J.appendChild(this.cloneNode(true));I=J.innerHTML}return o.clean([I.replace(/ jQuery\d+="(?:\d+|null)"/g,"").replace(/^\s*/,"")])[0]}else{return this.cloneNode(true)}});if(G===true){var H=this.find("*").andSelf(),F=0;E.find("*").andSelf().each(function(){if(this.nodeName!==H[F].nodeName){return}var I=o.data(H[F],"events");for(var K in I){for(var J in I[K]){o.event.add(this,K,I[K][J],I[K][J].data)}}F++})}return E},filter:function(E){return this.pushStack(o.isFunction(E)&&o.grep(this,function(G,F){return E.call(G,F)})||o.multiFilter(E,o.grep(this,function(F){return F.nodeType===1})),"filter",E)},closest:function(E){var G=o.expr.match.POS.test(E)?o(E):null,F=0;return this.map(function(){var H=this;while(H&&H.ownerDocument){if(G?G.index(H)>-1:o(H).is(E)){o.data(H,"closest",F);return H}H=H.parentNode;F++}})},not:function(E){if(typeof E==="string"){if(f.test(E)){return this.pushStack(o.multiFilter(E,this,true),"not",E)}else{E=o.multiFilter(E,this)}}var F=E.length&&E[E.length-1]!==g&&!E.nodeType;return this.filter(function(){return F?o.inArray(this,E)<0:this!=E})},add:function(E){return this.pushStack(o.unique(o.merge(this.get(),typeof E==="string"?o(E):o.makeArray(E))))},is:function(E){return !!E&&o.multiFilter(E,this).length>0},hasClass:function(E){return !!E&&this.is("."+E)},val:function(K){if(K===g){var E=this[0];if(E){if(o.nodeName(E,"option")){return(E.attributes.value||{}).specified?E.value:E.text}if(o.nodeName(E,"select")){var I=E.selectedIndex,L=[],M=E.options,H=E.type=="select-one";if(I<0){return null}for(var F=H?I:0,J=H?I+1:M.length;F<J;F++){var G=M[F];if(G.selected){K=o(G).val();if(H){return K}L.push(K)}}return L}return(E.value||"").replace(/\r/g,"")}return g}if(typeof K==="number"){K+=""}return this.each(function(){if(this.nodeType!=1){return}if(o.isArray(K)&&/radio|checkbox/.test(this.type)){this.checked=(o.inArray(this.value,K)>=0||o.inArray(this.name,K)>=0)}else{if(o.nodeName(this,"select")){var N=o.makeArray(K);o("option",this).each(function(){this.selected=(o.inArray(this.value,N)>=0||o.inArray(this.text,N)>=0)});if(!N.length){this.selectedIndex=-1}}else{this.value=K}}})},html:function(E){return E===g?(this[0]?this[0].innerHTML.replace(/ jQuery\d+="(?:\d+|null)"/g,""):null):this.empty().append(E)},replaceWith:function(E){return this.after(E).remove()},eq:function(E){return this.slice(E,+E+1)},slice:function(){return this.pushStack(Array.prototype.slice.apply(this,arguments),"slice",Array.prototype.slice.call(arguments).join(","))},map:function(E){return this.pushStack(o.map(this,function(G,F){return E.call(G,F,G)}))},andSelf:function(){return this.add(this.prevObject)},domManip:function(J,M,L){if(this[0]){var I=(this[0].ownerDocument||this[0]).createDocumentFragment(),F=o.clean(J,(this[0].ownerDocument||this[0]),I),H=I.firstChild;if(H){for(var G=0,E=this.length;G<E;G++){L.call(K(this[G],H),this.length>1||G>0?I.cloneNode(true):I)}}if(F){o.each(F,z)}}return this;function K(N,O){return M&&o.nodeName(N,"table")&&o.nodeName(O,"tr")?(N.getElementsByTagName("tbody")[0]||N.appendChild(N.ownerDocument.createElement("tbody"))):N}}};o.fn.init.prototype=o.fn;function z(E,F){if(F.src){o.ajax({url:F.src,async:false,dataType:"script"})}else{o.globalEval(F.text||F.textContent||F.innerHTML||"")}if(F.parentNode){F.parentNode.removeChild(F)}}function e(){return +new Date}o.extend=o.fn.extend=function(){var J=arguments[0]||{},H=1,I=arguments.length,E=false,G;if(typeof J==="boolean"){E=J;J=arguments[1]||{};H=2}if(typeof J!=="object"&&!o.isFunction(J)){J={}}if(I==H){J=this;--H}for(;H<I;H++){if((G=arguments[H])!=null){for(var F in G){var K=J[F],L=G[F];if(J===L){continue}if(E&&L&&typeof L==="object"&&!L.nodeType){J[F]=o.extend(E,K||(L.length!=null?[]:{}),L)}else{if(L!==g){J[F]=L}}}}}return J};var b=/z-?index|font-?weight|opacity|zoom|line-?height/i,q=document.defaultView||{},s=Object.prototype.toString;o.extend({noConflict:function(E){l.$=p;if(E){l.jQuery=y}return o},isFunction:function(E){return s.call(E)==="[object Function]"},isArray:function(E){return s.call(E)==="[object Array]"},isXMLDoc:function(E){return E.nodeType===9&&E.documentElement.nodeName!=="HTML"||!!E.ownerDocument&&o.isXMLDoc(E.ownerDocument)},globalEval:function(G){if(G&&/\S/.test(G)){var F=document.getElementsByTagName("head")[0]||document.documentElement,E=document.createElement("script");E.type="text/javascript";if(o.support.scriptEval){E.appendChild(document.createTextNode(G))}else{E.text=G}F.insertBefore(E,F.firstChild);F.removeChild(E)}},nodeName:function(F,E){return F.nodeName&&F.nodeName.toUpperCase()==E.toUpperCase()},each:function(G,K,F){var E,H=0,I=G.length;if(F){if(I===g){for(E in G){if(K.apply(G[E],F)===false){break}}}else{for(;H<I;){if(K.apply(G[H++],F)===false){break}}}}else{if(I===g){for(E in G){if(K.call(G[E],E,G[E])===false){break}}}else{for(var J=G[0];H<I&&K.call(J,H,J)!==false;J=G[++H]){}}}return G},prop:function(H,I,G,F,E){if(o.isFunction(I)){I=I.call(H,F)}return typeof I==="number"&&G=="curCSS"&&!b.test(E)?I+"px":I},className:{add:function(E,F){o.each((F||"").split(/\s+/),function(G,H){if(E.nodeType==1&&!o.className.has(E.className,H)){E.className+=(E.className?" ":"")+H}})},remove:function(E,F){if(E.nodeType==1){E.className=F!==g?o.grep(E.className.split(/\s+/),function(G){return !o.className.has(F,G)}).join(" "):""}},has:function(F,E){return F&&o.inArray(E,(F.className||F).toString().split(/\s+/))>-1}},swap:function(H,G,I){var E={};for(var F in G){E[F]=H.style[F];H.style[F]=G[F]}I.call(H);for(var F in G){H.style[F]=E[F]}},css:function(H,F,J,E){if(F=="width"||F=="height"){var L,G={position:"absolute",visibility:"hidden",display:"block"},K=F=="width"?["Left","Right"]:["Top","Bottom"];function I(){L=F=="width"?H.offsetWidth:H.offsetHeight;if(E==="border"){return}o.each(K,function(){if(!E){L-=parseFloat(o.curCSS(H,"padding"+this,true))||0}if(E==="margin"){L+=parseFloat(o.curCSS(H,"margin"+this,true))||0}else{L-=parseFloat(o.curCSS(H,"border"+this+"Width",true))||0}})}if(H.offsetWidth!==0){I()}else{o.swap(H,G,I)}return Math.max(0,Math.round(L))}return o.curCSS(H,F,J)},curCSS:function(I,F,G){var L,E=I.style;if(F=="opacity"&&!o.support.opacity){L=o.attr(E,"opacity");return L==""?"1":L}if(F.match(/float/i)){F=w}if(!G&&E&&E[F]){L=E[F]}else{if(q.getComputedStyle){if(F.match(/float/i)){F="float"}F=F.replace(/([A-Z])/g,"-$1").toLowerCase();var M=q.getComputedStyle(I,null);if(M){L=M.getPropertyValue(F)}if(F=="opacity"&&L==""){L="1"}}else{if(I.currentStyle){var J=F.replace(/\-(\w)/g,function(N,O){return O.toUpperCase()});L=I.currentStyle[F]||I.currentStyle[J];if(!/^\d+(px)?$/i.test(L)&&/^\d/.test(L)){var H=E.left,K=I.runtimeStyle.left;I.runtimeStyle.left=I.currentStyle.left;E.left=L||0;L=E.pixelLeft+"px";E.left=H;I.runtimeStyle.left=K}}}}return L},clean:function(F,K,I){K=K||document;if(typeof K.createElement==="undefined"){K=K.ownerDocument||K[0]&&K[0].ownerDocument||document}if(!I&&F.length===1&&typeof F[0]==="string"){var H=/^<(\w+)\s*\/?>$/.exec(F[0]);if(H){return[K.createElement(H[1])]}}var G=[],E=[],L=K.createElement("div");o.each(F,function(P,S){if(typeof S==="number"){S+=""}if(!S){return}if(typeof S==="string"){S=S.replace(/(<(\w+)[^>]*?)\/>/g,function(U,V,T){return T.match(/^(abbr|br|col|img|input|link|meta|param|hr|area|embed)$/i)?U:V+"></"+T+">"});var O=S.replace(/^\s+/,"").substring(0,10).toLowerCase();var Q=!O.indexOf("<opt")&&[1,"<select multiple='multiple'>","</select>"]||!O.indexOf("<leg")&&[1,"<fieldset>","</fieldset>"]||O.match(/^<(thead|tbody|tfoot|colg|cap)/)&&[1,"<table>","</table>"]||!O.indexOf("<tr")&&[2,"<table><tbody>","</tbody></table>"]||(!O.indexOf("<td")||!O.indexOf("<th"))&&[3,"<table><tbody><tr>","</tr></tbody></table>"]||!O.indexOf("<col")&&[2,"<table><tbody></tbody><colgroup>","</colgroup></table>"]||!o.support.htmlSerialize&&[1,"div<div>","</div>"]||[0,"",""];L.innerHTML=Q[1]+S+Q[2];while(Q[0]--){L=L.lastChild}if(!o.support.tbody){var R=/<tbody/i.test(S),N=!O.indexOf("<table")&&!R?L.firstChild&&L.firstChild.childNodes:Q[1]=="<table>"&&!R?L.childNodes:[];for(var M=N.length-1;M>=0;--M){if(o.nodeName(N[M],"tbody")&&!N[M].childNodes.length){N[M].parentNode.removeChild(N[M])}}}if(!o.support.leadingWhitespace&&/^\s/.test(S)){L.insertBefore(K.createTextNode(S.match(/^\s*/)[0]),L.firstChild)}S=o.makeArray(L.childNodes)}if(S.nodeType){G.push(S)}else{G=o.merge(G,S)}});if(I){for(var J=0;G[J];J++){if(o.nodeName(G[J],"script")&&(!G[J].type||G[J].type.toLowerCase()==="text/javascript")){E.push(G[J].parentNode?G[J].parentNode.removeChild(G[J]):G[J])}else{if(G[J].nodeType===1){G.splice.apply(G,[J+1,0].concat(o.makeArray(G[J].getElementsByTagName("script"))))}I.appendChild(G[J])}}return E}return G},attr:function(J,G,K){if(!J||J.nodeType==3||J.nodeType==8){return g}var H=!o.isXMLDoc(J),L=K!==g;G=H&&o.props[G]||G;if(J.tagName){var F=/href|src|style/.test(G);if(G=="selected"&&J.parentNode){J.parentNode.selectedIndex}if(G in J&&H&&!F){if(L){if(G=="type"&&o.nodeName(J,"input")&&J.parentNode){throw"type property can't be changed"}J[G]=K}if(o.nodeName(J,"form")&&J.getAttributeNode(G)){return J.getAttributeNode(G).nodeValue}if(G=="tabIndex"){var I=J.getAttributeNode("tabIndex");return I&&I.specified?I.value:J.nodeName.match(/(button|input|object|select|textarea)/i)?0:J.nodeName.match(/^(a|area)$/i)&&J.href?0:g}return J[G]}if(!o.support.style&&H&&G=="style"){return o.attr(J.style,"cssText",K)}if(L){J.setAttribute(G,""+K)}var E=!o.support.hrefNormalized&&H&&F?J.getAttribute(G,2):J.getAttribute(G);return E===null?g:E}if(!o.support.opacity&&G=="opacity"){if(L){J.zoom=1;J.filter=(J.filter||"").replace(/alpha\([^)]*\)/,"")+(parseInt(K)+""=="NaN"?"":"alpha(opacity="+K*100+")")}return J.filter&&J.filter.indexOf("opacity=")>=0?(parseFloat(J.filter.match(/opacity=([^)]*)/)[1])/100)+"":""}G=G.replace(/-([a-z])/ig,function(M,N){return N.toUpperCase()});if(L){J[G]=K}return J[G]},trim:function(E){return(E||"").replace(/^\s+|\s+$/g,"")},makeArray:function(G){var E=[];if(G!=null){var F=G.length;if(F==null||typeof G==="string"||o.isFunction(G)||G.setInterval){E[0]=G}else{while(F){E[--F]=G[F]}}}return E},inArray:function(G,H){for(var E=0,F=H.length;E<F;E++){if(H[E]===G){return E}}return -1},merge:function(H,E){var F=0,G,I=H.length;if(!o.support.getAll){while((G=E[F++])!=null){if(G.nodeType!=8){H[I++]=G}}}else{while((G=E[F++])!=null){H[I++]=G}}return H},unique:function(K){var F=[],E={};try{for(var G=0,H=K.length;G<H;G++){var J=o.data(K[G]);if(!E[J]){E[J]=true;F.push(K[G])}}}catch(I){F=K}return F},grep:function(F,J,E){var G=[];for(var H=0,I=F.length;H<I;H++){if(!E!=!J(F[H],H)){G.push(F[H])}}return G},map:function(E,J){var F=[];for(var G=0,H=E.length;G<H;G++){var I=J(E[G],G);if(I!=null){F[F.length]=I}}return F.concat.apply([],F)}});var C=navigator.userAgent.toLowerCase();o.browser={version:(C.match(/.+(?:rv|it|ra|ie)[\/: ]([\d.]+)/)||[0,"0"])[1],safari:/webkit/.test(C),opera:/opera/.test(C),msie:/msie/.test(C)&&!/opera/.test(C),mozilla:/mozilla/.test(C)&&!/(compatible|webkit)/.test(C)};o.each({parent:function(E){return E.parentNode},parents:function(E){return o.dir(E,"parentNode")},next:function(E){return o.nth(E,2,"nextSibling")},prev:function(E){return o.nth(E,2,"previousSibling")},nextAll:function(E){return o.dir(E,"nextSibling")},prevAll:function(E){return o.dir(E,"previousSibling")},siblings:function(E){return o.sibling(E.parentNode.firstChild,E)},children:function(E){return o.sibling(E.firstChild)},contents:function(E){return o.nodeName(E,"iframe")?E.contentDocument||E.contentWindow.document:o.makeArray(E.childNodes)}},function(E,F){o.fn[E]=function(G){var H=o.map(this,F);if(G&&typeof G=="string"){H=o.multiFilter(G,H)}return this.pushStack(o.unique(H),E,G)}});o.each({appendTo:"append",prependTo:"prepend",insertBefore:"before",insertAfter:"after",replaceAll:"replaceWith"},function(E,F){o.fn[E]=function(G){var J=[],L=o(G);for(var K=0,H=L.length;K<H;K++){var I=(K>0?this.clone(true):this).get();o.fn[F].apply(o(L[K]),I);J=J.concat(I)}return this.pushStack(J,E,G)}});o.each({removeAttr:function(E){o.attr(this,E,"");if(this.nodeType==1){this.removeAttribute(E)}},addClass:function(E){o.className.add(this,E)},removeClass:function(E){o.className.remove(this,E)},toggleClass:function(F,E){if(typeof E!=="boolean"){E=!o.className.has(this,F)}o.className[E?"add":"remove"](this,F)},remove:function(E){if(!E||o.filter(E,[this]).length){o("*",this).add([this]).each(function(){o.event.remove(this);o.removeData(this)});if(this.parentNode){this.parentNode.removeChild(this)}}},empty:function(){o(this).children().remove();while(this.firstChild){this.removeChild(this.firstChild)}}},function(E,F){o.fn[E]=function(){return this.each(F,arguments)}});function j(E,F){return E[0]&&parseInt(o.curCSS(E[0],F,true),10)||0}var h="jQuery"+e(),v=0,A={};o.extend({cache:{},data:function(F,E,G){F=F==l?A:F;var H=F[h];if(!H){H=F[h]=++v}if(E&&!o.cache[H]){o.cache[H]={}}if(G!==g){o.cache[H][E]=G}return E?o.cache[H][E]:H},removeData:function(F,E){F=F==l?A:F;var H=F[h];if(E){if(o.cache[H]){delete o.cache[H][E];E="";for(E in o.cache[H]){break}if(!E){o.removeData(F)}}}else{try{delete F[h]}catch(G){if(F.removeAttribute){F.removeAttribute(h)}}delete o.cache[H]}},queue:function(F,E,H){if(F){E=(E||"fx")+"queue";var G=o.data(F,E);if(!G||o.isArray(H)){G=o.data(F,E,o.makeArray(H))}else{if(H){G.push(H)}}}return G},dequeue:function(H,G){var E=o.queue(H,G),F=E.shift();if(!G||G==="fx"){F=E[0]}if(F!==g){F.call(H)}}});o.fn.extend({data:function(E,G){var H=E.split(".");H[1]=H[1]?"."+H[1]:"";if(G===g){var F=this.triggerHandler("getData"+H[1]+"!",[H[0]]);if(F===g&&this.length){F=o.data(this[0],E)}return F===g&&H[1]?this.data(H[0]):F}else{return this.trigger("setData"+H[1]+"!",[H[0],G]).each(function(){o.data(this,E,G)})}},removeData:function(E){return this.each(function(){o.removeData(this,E)})},queue:function(E,F){if(typeof E!=="string"){F=E;E="fx"}if(F===g){return o.queue(this[0],E)}return this.each(function(){var G=o.queue(this,E,F);if(E=="fx"&&G.length==1){G[0].call(this)}})},dequeue:function(E){return this.each(function(){o.dequeue(this,E)})}});
/*
 * Sizzle CSS Selector Engine - v0.9.3
 *  Copyright 2009, The Dojo Foundation
 *  Released under the MIT, BSD, and GPL Licenses.
 *  More information: http://sizzlejs.com/
 */
(function(){var R=/((?:\((?:\([^()]+\)|[^()]+)+\)|\[(?:\[[^[\]]*\]|['"][^'"]*['"]|[^[\]'"]+)+\]|\\.|[^ >+~,(\[\\]+)+|[>+~])(\s*,\s*)?/g,L=0,H=Object.prototype.toString;var F=function(Y,U,ab,ac){ab=ab||[];U=U||document;if(U.nodeType!==1&&U.nodeType!==9){return[]}if(!Y||typeof Y!=="string"){return ab}var Z=[],W,af,ai,T,ad,V,X=true;R.lastIndex=0;while((W=R.exec(Y))!==null){Z.push(W[1]);if(W[2]){V=RegExp.rightContext;break}}if(Z.length>1&&M.exec(Y)){if(Z.length===2&&I.relative[Z[0]]){af=J(Z[0]+Z[1],U)}else{af=I.relative[Z[0]]?[U]:F(Z.shift(),U);while(Z.length){Y=Z.shift();if(I.relative[Y]){Y+=Z.shift()}af=J(Y,af)}}}else{var ae=ac?{expr:Z.pop(),set:E(ac)}:F.find(Z.pop(),Z.length===1&&U.parentNode?U.parentNode:U,Q(U));af=F.filter(ae.expr,ae.set);if(Z.length>0){ai=E(af)}else{X=false}while(Z.length){var ah=Z.pop(),ag=ah;if(!I.relative[ah]){ah=""}else{ag=Z.pop()}if(ag==null){ag=U}I.relative[ah](ai,ag,Q(U))}}if(!ai){ai=af}if(!ai){throw"Syntax error, unrecognized expression: "+(ah||Y)}if(H.call(ai)==="[object Array]"){if(!X){ab.push.apply(ab,ai)}else{if(U.nodeType===1){for(var aa=0;ai[aa]!=null;aa++){if(ai[aa]&&(ai[aa]===true||ai[aa].nodeType===1&&K(U,ai[aa]))){ab.push(af[aa])}}}else{for(var aa=0;ai[aa]!=null;aa++){if(ai[aa]&&ai[aa].nodeType===1){ab.push(af[aa])}}}}}else{E(ai,ab)}if(V){F(V,U,ab,ac);if(G){hasDuplicate=false;ab.sort(G);if(hasDuplicate){for(var aa=1;aa<ab.length;aa++){if(ab[aa]===ab[aa-1]){ab.splice(aa--,1)}}}}}return ab};F.matches=function(T,U){return F(T,null,null,U)};F.find=function(aa,T,ab){var Z,X;if(!aa){return[]}for(var W=0,V=I.order.length;W<V;W++){var Y=I.order[W],X;if((X=I.match[Y].exec(aa))){var U=RegExp.leftContext;if(U.substr(U.length-1)!=="\\"){X[1]=(X[1]||"").replace(/\\/g,"");Z=I.find[Y](X,T,ab);if(Z!=null){aa=aa.replace(I.match[Y],"");break}}}}if(!Z){Z=T.getElementsByTagName("*")}return{set:Z,expr:aa}};F.filter=function(ad,ac,ag,W){var V=ad,ai=[],aa=ac,Y,T,Z=ac&&ac[0]&&Q(ac[0]);while(ad&&ac.length){for(var ab in I.filter){if((Y=I.match[ab].exec(ad))!=null){var U=I.filter[ab],ah,af;T=false;if(aa==ai){ai=[]}if(I.preFilter[ab]){Y=I.preFilter[ab](Y,aa,ag,ai,W,Z);if(!Y){T=ah=true}else{if(Y===true){continue}}}if(Y){for(var X=0;(af=aa[X])!=null;X++){if(af){ah=U(af,Y,X,aa);var ae=W^!!ah;if(ag&&ah!=null){if(ae){T=true}else{aa[X]=false}}else{if(ae){ai.push(af);T=true}}}}}if(ah!==g){if(!ag){aa=ai}ad=ad.replace(I.match[ab],"");if(!T){return[]}break}}}if(ad==V){if(T==null){throw"Syntax error, unrecognized expression: "+ad}else{break}}V=ad}return aa};var I=F.selectors={order:["ID","NAME","TAG"],match:{ID:/#((?:[\w\u00c0-\uFFFF_-]|\\.)+)/,CLASS:/\.((?:[\w\u00c0-\uFFFF_-]|\\.)+)/,NAME:/\[name=['"]*((?:[\w\u00c0-\uFFFF_-]|\\.)+)['"]*\]/,ATTR:/\[\s*((?:[\w\u00c0-\uFFFF_-]|\\.)+)\s*(?:(\S?=)\s*(['"]*)(.*?)\3|)\s*\]/,TAG:/^((?:[\w\u00c0-\uFFFF\*_-]|\\.)+)/,CHILD:/:(only|nth|last|first)-child(?:\((even|odd|[\dn+-]*)\))?/,POS:/:(nth|eq|gt|lt|first|last|even|odd)(?:\((\d*)\))?(?=[^-]|$)/,PSEUDO:/:((?:[\w\u00c0-\uFFFF_-]|\\.)+)(?:\((['"]*)((?:\([^\)]+\)|[^\2\(\)]*)+)\2\))?/},attrMap:{"class":"className","for":"htmlFor"},attrHandle:{href:function(T){return T.getAttribute("href")}},relative:{"+":function(aa,T,Z){var X=typeof T==="string",ab=X&&!/\W/.test(T),Y=X&&!ab;if(ab&&!Z){T=T.toUpperCase()}for(var W=0,V=aa.length,U;W<V;W++){if((U=aa[W])){while((U=U.previousSibling)&&U.nodeType!==1){}aa[W]=Y||U&&U.nodeName===T?U||false:U===T}}if(Y){F.filter(T,aa,true)}},">":function(Z,U,aa){var X=typeof U==="string";if(X&&!/\W/.test(U)){U=aa?U:U.toUpperCase();for(var V=0,T=Z.length;V<T;V++){var Y=Z[V];if(Y){var W=Y.parentNode;Z[V]=W.nodeName===U?W:false}}}else{for(var V=0,T=Z.length;V<T;V++){var Y=Z[V];if(Y){Z[V]=X?Y.parentNode:Y.parentNode===U}}if(X){F.filter(U,Z,true)}}},"":function(W,U,Y){var V=L++,T=S;if(!U.match(/\W/)){var X=U=Y?U:U.toUpperCase();T=P}T("parentNode",U,V,W,X,Y)},"~":function(W,U,Y){var V=L++,T=S;if(typeof U==="string"&&!U.match(/\W/)){var X=U=Y?U:U.toUpperCase();T=P}T("previousSibling",U,V,W,X,Y)}},find:{ID:function(U,V,W){if(typeof V.getElementById!=="undefined"&&!W){var T=V.getElementById(U[1]);return T?[T]:[]}},NAME:function(V,Y,Z){if(typeof Y.getElementsByName!=="undefined"){var U=[],X=Y.getElementsByName(V[1]);for(var W=0,T=X.length;W<T;W++){if(X[W].getAttribute("name")===V[1]){U.push(X[W])}}return U.length===0?null:U}},TAG:function(T,U){return U.getElementsByTagName(T[1])}},preFilter:{CLASS:function(W,U,V,T,Z,aa){W=" "+W[1].replace(/\\/g,"")+" ";if(aa){return W}for(var X=0,Y;(Y=U[X])!=null;X++){if(Y){if(Z^(Y.className&&(" "+Y.className+" ").indexOf(W)>=0)){if(!V){T.push(Y)}}else{if(V){U[X]=false}}}}return false},ID:function(T){return T[1].replace(/\\/g,"")},TAG:function(U,T){for(var V=0;T[V]===false;V++){}return T[V]&&Q(T[V])?U[1]:U[1].toUpperCase()},CHILD:function(T){if(T[1]=="nth"){var U=/(-?)(\d*)n((?:\+|-)?\d*)/.exec(T[2]=="even"&&"2n"||T[2]=="odd"&&"2n+1"||!/\D/.test(T[2])&&"0n+"+T[2]||T[2]);T[2]=(U[1]+(U[2]||1))-0;T[3]=U[3]-0}T[0]=L++;return T},ATTR:function(X,U,V,T,Y,Z){var W=X[1].replace(/\\/g,"");if(!Z&&I.attrMap[W]){X[1]=I.attrMap[W]}if(X[2]==="~="){X[4]=" "+X[4]+" "}return X},PSEUDO:function(X,U,V,T,Y){if(X[1]==="not"){if(X[3].match(R).length>1||/^\w/.test(X[3])){X[3]=F(X[3],null,null,U)}else{var W=F.filter(X[3],U,V,true^Y);if(!V){T.push.apply(T,W)}return false}}else{if(I.match.POS.test(X[0])||I.match.CHILD.test(X[0])){return true}}return X},POS:function(T){T.unshift(true);return T}},filters:{enabled:function(T){return T.disabled===false&&T.type!=="hidden"},disabled:function(T){return T.disabled===true},checked:function(T){return T.checked===true},selected:function(T){T.parentNode.selectedIndex;return T.selected===true},parent:function(T){return !!T.firstChild},empty:function(T){return !T.firstChild},has:function(V,U,T){return !!F(T[3],V).length},header:function(T){return/h\d/i.test(T.nodeName)},text:function(T){return"text"===T.type},radio:function(T){return"radio"===T.type},checkbox:function(T){return"checkbox"===T.type},file:function(T){return"file"===T.type},password:function(T){return"password"===T.type},submit:function(T){return"submit"===T.type},image:function(T){return"image"===T.type},reset:function(T){return"reset"===T.type},button:function(T){return"button"===T.type||T.nodeName.toUpperCase()==="BUTTON"},input:function(T){return/input|select|textarea|button/i.test(T.nodeName)}},setFilters:{first:function(U,T){return T===0},last:function(V,U,T,W){return U===W.length-1},even:function(U,T){return T%2===0},odd:function(U,T){return T%2===1},lt:function(V,U,T){return U<T[3]-0},gt:function(V,U,T){return U>T[3]-0},nth:function(V,U,T){return T[3]-0==U},eq:function(V,U,T){return T[3]-0==U}},filter:{PSEUDO:function(Z,V,W,aa){var U=V[1],X=I.filters[U];if(X){return X(Z,W,V,aa)}else{if(U==="contains"){return(Z.textContent||Z.innerText||"").indexOf(V[3])>=0}else{if(U==="not"){var Y=V[3];for(var W=0,T=Y.length;W<T;W++){if(Y[W]===Z){return false}}return true}}}},CHILD:function(T,W){var Z=W[1],U=T;switch(Z){case"only":case"first":while(U=U.previousSibling){if(U.nodeType===1){return false}}if(Z=="first"){return true}U=T;case"last":while(U=U.nextSibling){if(U.nodeType===1){return false}}return true;case"nth":var V=W[2],ac=W[3];if(V==1&&ac==0){return true}var Y=W[0],ab=T.parentNode;if(ab&&(ab.sizcache!==Y||!T.nodeIndex)){var X=0;for(U=ab.firstChild;U;U=U.nextSibling){if(U.nodeType===1){U.nodeIndex=++X}}ab.sizcache=Y}var aa=T.nodeIndex-ac;if(V==0){return aa==0}else{return(aa%V==0&&aa/V>=0)}}},ID:function(U,T){return U.nodeType===1&&U.getAttribute("id")===T},TAG:function(U,T){return(T==="*"&&U.nodeType===1)||U.nodeName===T},CLASS:function(U,T){return(" "+(U.className||U.getAttribute("class"))+" ").indexOf(T)>-1},ATTR:function(Y,W){var V=W[1],T=I.attrHandle[V]?I.attrHandle[V](Y):Y[V]!=null?Y[V]:Y.getAttribute(V),Z=T+"",X=W[2],U=W[4];return T==null?X==="!=":X==="="?Z===U:X==="*="?Z.indexOf(U)>=0:X==="~="?(" "+Z+" ").indexOf(U)>=0:!U?Z&&T!==false:X==="!="?Z!=U:X==="^="?Z.indexOf(U)===0:X==="$="?Z.substr(Z.length-U.length)===U:X==="|="?Z===U||Z.substr(0,U.length+1)===U+"-":false},POS:function(X,U,V,Y){var T=U[2],W=I.setFilters[T];if(W){return W(X,V,U,Y)}}}};var M=I.match.POS;for(var O in I.match){I.match[O]=RegExp(I.match[O].source+/(?![^\[]*\])(?![^\(]*\))/.source)}var E=function(U,T){U=Array.prototype.slice.call(U);if(T){T.push.apply(T,U);return T}return U};try{Array.prototype.slice.call(document.documentElement.childNodes)}catch(N){E=function(X,W){var U=W||[];if(H.call(X)==="[object Array]"){Array.prototype.push.apply(U,X)}else{if(typeof X.length==="number"){for(var V=0,T=X.length;V<T;V++){U.push(X[V])}}else{for(var V=0;X[V];V++){U.push(X[V])}}}return U}}var G;if(document.documentElement.compareDocumentPosition){G=function(U,T){var V=U.compareDocumentPosition(T)&4?-1:U===T?0:1;if(V===0){hasDuplicate=true}return V}}else{if("sourceIndex" in document.documentElement){G=function(U,T){var V=U.sourceIndex-T.sourceIndex;if(V===0){hasDuplicate=true}return V}}else{if(document.createRange){G=function(W,U){var V=W.ownerDocument.createRange(),T=U.ownerDocument.createRange();V.selectNode(W);V.collapse(true);T.selectNode(U);T.collapse(true);var X=V.compareBoundaryPoints(Range.START_TO_END,T);if(X===0){hasDuplicate=true}return X}}}}(function(){var U=document.createElement("form"),V="script"+(new Date).getTime();U.innerHTML="<input name='"+V+"'/>";var T=document.documentElement;T.insertBefore(U,T.firstChild);if(!!document.getElementById(V)){I.find.ID=function(X,Y,Z){if(typeof Y.getElementById!=="undefined"&&!Z){var W=Y.getElementById(X[1]);return W?W.id===X[1]||typeof W.getAttributeNode!=="undefined"&&W.getAttributeNode("id").nodeValue===X[1]?[W]:g:[]}};I.filter.ID=function(Y,W){var X=typeof Y.getAttributeNode!=="undefined"&&Y.getAttributeNode("id");return Y.nodeType===1&&X&&X.nodeValue===W}}T.removeChild(U)})();(function(){var T=document.createElement("div");T.appendChild(document.createComment(""));if(T.getElementsByTagName("*").length>0){I.find.TAG=function(U,Y){var X=Y.getElementsByTagName(U[1]);if(U[1]==="*"){var W=[];for(var V=0;X[V];V++){if(X[V].nodeType===1){W.push(X[V])}}X=W}return X}}T.innerHTML="<a href='#'></a>";if(T.firstChild&&typeof T.firstChild.getAttribute!=="undefined"&&T.firstChild.getAttribute("href")!=="#"){I.attrHandle.href=function(U){return U.getAttribute("href",2)}}})();if(document.querySelectorAll){(function(){var T=F,U=document.createElement("div");U.innerHTML="<p class='TEST'></p>";if(U.querySelectorAll&&U.querySelectorAll(".TEST").length===0){return}F=function(Y,X,V,W){X=X||document;if(!W&&X.nodeType===9&&!Q(X)){try{return E(X.querySelectorAll(Y),V)}catch(Z){}}return T(Y,X,V,W)};F.find=T.find;F.filter=T.filter;F.selectors=T.selectors;F.matches=T.matches})()}if(document.getElementsByClassName&&document.documentElement.getElementsByClassName){(function(){var T=document.createElement("div");T.innerHTML="<div class='test e'></div><div class='test'></div>";if(T.getElementsByClassName("e").length===0){return}T.lastChild.className="e";if(T.getElementsByClassName("e").length===1){return}I.order.splice(1,0,"CLASS");I.find.CLASS=function(U,V,W){if(typeof V.getElementsByClassName!=="undefined"&&!W){return V.getElementsByClassName(U[1])}}})()}function P(U,Z,Y,ad,aa,ac){var ab=U=="previousSibling"&&!ac;for(var W=0,V=ad.length;W<V;W++){var T=ad[W];if(T){if(ab&&T.nodeType===1){T.sizcache=Y;T.sizset=W}T=T[U];var X=false;while(T){if(T.sizcache===Y){X=ad[T.sizset];break}if(T.nodeType===1&&!ac){T.sizcache=Y;T.sizset=W}if(T.nodeName===Z){X=T;break}T=T[U]}ad[W]=X}}}function S(U,Z,Y,ad,aa,ac){var ab=U=="previousSibling"&&!ac;for(var W=0,V=ad.length;W<V;W++){var T=ad[W];if(T){if(ab&&T.nodeType===1){T.sizcache=Y;T.sizset=W}T=T[U];var X=false;while(T){if(T.sizcache===Y){X=ad[T.sizset];break}if(T.nodeType===1){if(!ac){T.sizcache=Y;T.sizset=W}if(typeof Z!=="string"){if(T===Z){X=true;break}}else{if(F.filter(Z,[T]).length>0){X=T;break}}}T=T[U]}ad[W]=X}}}var K=document.compareDocumentPosition?function(U,T){return U.compareDocumentPosition(T)&16}:function(U,T){return U!==T&&(U.contains?U.contains(T):true)};var Q=function(T){return T.nodeType===9&&T.documentElement.nodeName!=="HTML"||!!T.ownerDocument&&Q(T.ownerDocument)};var J=function(T,aa){var W=[],X="",Y,V=aa.nodeType?[aa]:aa;while((Y=I.match.PSEUDO.exec(T))){X+=Y[0];T=T.replace(I.match.PSEUDO,"")}T=I.relative[T]?T+"*":T;for(var Z=0,U=V.length;Z<U;Z++){F(T,V[Z],W)}return F.filter(X,W)};o.find=F;o.filter=F.filter;o.expr=F.selectors;o.expr[":"]=o.expr.filters;F.selectors.filters.hidden=function(T){return T.offsetWidth===0||T.offsetHeight===0};F.selectors.filters.visible=function(T){return T.offsetWidth>0||T.offsetHeight>0};F.selectors.filters.animated=function(T){return o.grep(o.timers,function(U){return T===U.elem}).length};o.multiFilter=function(V,T,U){if(U){V=":not("+V+")"}return F.matches(V,T)};o.dir=function(V,U){var T=[],W=V[U];while(W&&W!=document){if(W.nodeType==1){T.push(W)}W=W[U]}return T};o.nth=function(X,T,V,W){T=T||1;var U=0;for(;X;X=X[V]){if(X.nodeType==1&&++U==T){break}}return X};o.sibling=function(V,U){var T=[];for(;V;V=V.nextSibling){if(V.nodeType==1&&V!=U){T.push(V)}}return T};return;l.Sizzle=F})();o.event={add:function(I,F,H,K){if(I.nodeType==3||I.nodeType==8){return}if(I.setInterval&&I!=l){I=l}if(!H.guid){H.guid=this.guid++}if(K!==g){var G=H;H=this.proxy(G);H.data=K}var E=o.data(I,"events")||o.data(I,"events",{}),J=o.data(I,"handle")||o.data(I,"handle",function(){return typeof o!=="undefined"&&!o.event.triggered?o.event.handle.apply(arguments.callee.elem,arguments):g});J.elem=I;o.each(F.split(/\s+/),function(M,N){var O=N.split(".");N=O.shift();H.type=O.slice().sort().join(".");var L=E[N];if(o.event.specialAll[N]){o.event.specialAll[N].setup.call(I,K,O)}if(!L){L=E[N]={};if(!o.event.special[N]||o.event.special[N].setup.call(I,K,O)===false){if(I.addEventListener){I.addEventListener(N,J,false)}else{if(I.attachEvent){I.attachEvent("on"+N,J)}}}}L[H.guid]=H;o.event.global[N]=true});I=null},guid:1,global:{},remove:function(K,H,J){if(K.nodeType==3||K.nodeType==8){return}var G=o.data(K,"events"),F,E;if(G){if(H===g||(typeof H==="string"&&H.charAt(0)==".")){for(var I in G){this.remove(K,I+(H||""))}}else{if(H.type){J=H.handler;H=H.type}o.each(H.split(/\s+/),function(M,O){var Q=O.split(".");O=Q.shift();var N=RegExp("(^|\\.)"+Q.slice().sort().join(".*\\.")+"(\\.|$)");if(G[O]){if(J){delete G[O][J.guid]}else{for(var P in G[O]){if(N.test(G[O][P].type)){delete G[O][P]}}}if(o.event.specialAll[O]){o.event.specialAll[O].teardown.call(K,Q)}for(F in G[O]){break}if(!F){if(!o.event.special[O]||o.event.special[O].teardown.call(K,Q)===false){if(K.removeEventListener){K.removeEventListener(O,o.data(K,"handle"),false)}else{if(K.detachEvent){K.detachEvent("on"+O,o.data(K,"handle"))}}}F=null;delete G[O]}}})}for(F in G){break}if(!F){var L=o.data(K,"handle");if(L){L.elem=null}o.removeData(K,"events");o.removeData(K,"handle")}}},trigger:function(I,K,H,E){var G=I.type||I;if(!E){I=typeof I==="object"?I[h]?I:o.extend(o.Event(G),I):o.Event(G);if(G.indexOf("!")>=0){I.type=G=G.slice(0,-1);I.exclusive=true}if(!H){I.stopPropagation();if(this.global[G]){o.each(o.cache,function(){if(this.events&&this.events[G]){o.event.trigger(I,K,this.handle.elem)}})}}if(!H||H.nodeType==3||H.nodeType==8){return g}I.result=g;I.target=H;K=o.makeArray(K);K.unshift(I)}I.currentTarget=H;var J=o.data(H,"handle");if(J){J.apply(H,K)}if((!H[G]||(o.nodeName(H,"a")&&G=="click"))&&H["on"+G]&&H["on"+G].apply(H,K)===false){I.result=false}if(!E&&H[G]&&!I.isDefaultPrevented()&&!(o.nodeName(H,"a")&&G=="click")){this.triggered=true;try{H[G]()}catch(L){}}this.triggered=false;if(!I.isPropagationStopped()){var F=H.parentNode||H.ownerDocument;if(F){o.event.trigger(I,K,F,true)}}},handle:function(K){var J,E;K=arguments[0]=o.event.fix(K||l.event);K.currentTarget=this;var L=K.type.split(".");K.type=L.shift();J=!L.length&&!K.exclusive;var I=RegExp("(^|\\.)"+L.slice().sort().join(".*\\.")+"(\\.|$)");E=(o.data(this,"events")||{})[K.type];for(var G in E){var H=E[G];if(J||I.test(H.type)){K.handler=H;K.data=H.data;var F=H.apply(this,arguments);if(F!==g){K.result=F;if(F===false){K.preventDefault();K.stopPropagation()}}if(K.isImmediatePropagationStopped()){break}}}},props:"altKey attrChange attrName bubbles button cancelable charCode clientX clientY ctrlKey currentTarget data detail eventPhase fromElement handler keyCode metaKey newValue originalTarget pageX pageY prevValue relatedNode relatedTarget screenX screenY shiftKey srcElement target toElement view wheelDelta which".split(" "),fix:function(H){if(H[h]){return H}var F=H;H=o.Event(F);for(var G=this.props.length,J;G;){J=this.props[--G];H[J]=F[J]}if(!H.target){H.target=H.srcElement||document}if(H.target.nodeType==3){H.target=H.target.parentNode}if(!H.relatedTarget&&H.fromElement){H.relatedTarget=H.fromElement==H.target?H.toElement:H.fromElement}if(H.pageX==null&&H.clientX!=null){var I=document.documentElement,E=document.body;H.pageX=H.clientX+(I&&I.scrollLeft||E&&E.scrollLeft||0)-(I.clientLeft||0);H.pageY=H.clientY+(I&&I.scrollTop||E&&E.scrollTop||0)-(I.clientTop||0)}if(!H.which&&((H.charCode||H.charCode===0)?H.charCode:H.keyCode)){H.which=H.charCode||H.keyCode}if(!H.metaKey&&H.ctrlKey){H.metaKey=H.ctrlKey}if(!H.which&&H.button){H.which=(H.button&1?1:(H.button&2?3:(H.button&4?2:0)))}return H},proxy:function(F,E){E=E||function(){return F.apply(this,arguments)};E.guid=F.guid=F.guid||E.guid||this.guid++;return E},special:{ready:{setup:B,teardown:function(){}}},specialAll:{live:{setup:function(E,F){o.event.add(this,F[0],c)},teardown:function(G){if(G.length){var E=0,F=RegExp("(^|\\.)"+G[0]+"(\\.|$)");o.each((o.data(this,"events").live||{}),function(){if(F.test(this.type)){E++}});if(E<1){o.event.remove(this,G[0],c)}}}}}};o.Event=function(E){if(!this.preventDefault){return new o.Event(E)}if(E&&E.type){this.originalEvent=E;this.type=E.type}else{this.type=E}this.timeStamp=e();this[h]=true};function k(){return false}function u(){return true}o.Event.prototype={preventDefault:function(){this.isDefaultPrevented=u;var E=this.originalEvent;if(!E){return}if(E.preventDefault){E.preventDefault()}E.returnValue=false},stopPropagation:function(){this.isPropagationStopped=u;var E=this.originalEvent;if(!E){return}if(E.stopPropagation){E.stopPropagation()}E.cancelBubble=true},stopImmediatePropagation:function(){this.isImmediatePropagationStopped=u;this.stopPropagation()},isDefaultPrevented:k,isPropagationStopped:k,isImmediatePropagationStopped:k};var a=function(F){var E=F.relatedTarget;while(E&&E!=this){try{E=E.parentNode}catch(G){E=this}}if(E!=this){F.type=F.data;o.event.handle.apply(this,arguments)}};o.each({mouseover:"mouseenter",mouseout:"mouseleave"},function(F,E){o.event.special[E]={setup:function(){o.event.add(this,F,a,E)},teardown:function(){o.event.remove(this,F,a)}}});o.fn.extend({bind:function(F,G,E){return F=="unload"?this.one(F,G,E):this.each(function(){o.event.add(this,F,E||G,E&&G)})},one:function(G,H,F){var E=o.event.proxy(F||H,function(I){o(this).unbind(I,E);return(F||H).apply(this,arguments)});return this.each(function(){o.event.add(this,G,E,F&&H)})},unbind:function(F,E){return this.each(function(){o.event.remove(this,F,E)})},trigger:function(E,F){return this.each(function(){o.event.trigger(E,F,this)})},triggerHandler:function(E,G){if(this[0]){var F=o.Event(E);F.preventDefault();F.stopPropagation();o.event.trigger(F,G,this[0]);return F.result}},toggle:function(G){var E=arguments,F=1;while(F<E.length){o.event.proxy(G,E[F++])}return this.click(o.event.proxy(G,function(H){this.lastToggle=(this.lastToggle||0)%F;H.preventDefault();return E[this.lastToggle++].apply(this,arguments)||false}))},hover:function(E,F){return this.mouseenter(E).mouseleave(F)},ready:function(E){B();if(o.isReady){E.call(document,o)}else{o.readyList.push(E)}return this},live:function(G,F){var E=o.event.proxy(F);E.guid+=this.selector+G;o(document).bind(i(G,this.selector),this.selector,E);return this},die:function(F,E){o(document).unbind(i(F,this.selector),E?{guid:E.guid+this.selector+F}:null);return this}});function c(H){var E=RegExp("(^|\\.)"+H.type+"(\\.|$)"),G=true,F=[];o.each(o.data(this,"events").live||[],function(I,J){if(E.test(J.type)){var K=o(H.target).closest(J.data)[0];if(K){F.push({elem:K,fn:J})}}});F.sort(function(J,I){return o.data(J.elem,"closest")-o.data(I.elem,"closest")});o.each(F,function(){if(this.fn.call(this.elem,H,this.fn.data)===false){return(G=false)}});return G}function i(F,E){return["live",F,E.replace(/\./g,"`").replace(/ /g,"|")].join(".")}o.extend({isReady:false,readyList:[],ready:function(){if(!o.isReady){o.isReady=true;if(o.readyList){o.each(o.readyList,function(){this.call(document,o)});o.readyList=null}o(document).triggerHandler("ready")}}});var x=false;function B(){if(x){return}x=true;if(document.addEventListener){document.addEventListener("DOMContentLoaded",function(){document.removeEventListener("DOMContentLoaded",arguments.callee,false);o.ready()},false)}else{if(document.attachEvent){document.attachEvent("onreadystatechange",function(){if(document.readyState==="complete"){document.detachEvent("onreadystatechange",arguments.callee);o.ready()}});if(document.documentElement.doScroll&&l==l.top){(function(){if(o.isReady){return}try{document.documentElement.doScroll("left")}catch(E){setTimeout(arguments.callee,0);return}o.ready()})()}}}o.event.add(l,"load",o.ready)}o.each(("blur,focus,load,resize,scroll,unload,click,dblclick,mousedown,mouseup,mousemove,mouseover,mouseout,mouseenter,mouseleave,change,select,submit,keydown,keypress,keyup,error").split(","),function(F,E){o.fn[E]=function(G){return G?this.bind(E,G):this.trigger(E)}});o(l).bind("unload",function(){for(var E in o.cache){if(E!=1&&o.cache[E].handle){o.event.remove(o.cache[E].handle.elem)}}});(function(){o.support={};var F=document.documentElement,G=document.createElement("script"),K=document.createElement("div"),J="script"+(new Date).getTime();K.style.display="none";K.innerHTML='   <link/><table></table><a href="/a" style="color:red;float:left;opacity:.5;">a</a><select><option>text</option></select><object><param/></object>';var H=K.getElementsByTagName("*"),E=K.getElementsByTagName("a")[0];if(!H||!H.length||!E){return}o.support={leadingWhitespace:K.firstChild.nodeType==3,tbody:!K.getElementsByTagName("tbody").length,objectAll:!!K.getElementsByTagName("object")[0].getElementsByTagName("*").length,htmlSerialize:!!K.getElementsByTagName("link").length,style:/red/.test(E.getAttribute("style")),hrefNormalized:E.getAttribute("href")==="/a",opacity:E.style.opacity==="0.5",cssFloat:!!E.style.cssFloat,scriptEval:false,noCloneEvent:true,boxModel:null};G.type="text/javascript";try{G.appendChild(document.createTextNode("window."+J+"=1;"))}catch(I){}F.insertBefore(G,F.firstChild);if(l[J]){o.support.scriptEval=true;delete l[J]}F.removeChild(G);if(K.attachEvent&&K.fireEvent){K.attachEvent("onclick",function(){o.support.noCloneEvent=false;K.detachEvent("onclick",arguments.callee)});K.cloneNode(true).fireEvent("onclick")}o(function(){var L=document.createElement("div");L.style.width=L.style.paddingLeft="1px";document.body.appendChild(L);o.boxModel=o.support.boxModel=L.offsetWidth===2;document.body.removeChild(L).style.display="none"})})();var w=o.support.cssFloat?"cssFloat":"styleFloat";o.props={"for":"htmlFor","class":"className","float":w,cssFloat:w,styleFloat:w,readonly:"readOnly",maxlength:"maxLength",cellspacing:"cellSpacing",rowspan:"rowSpan",tabindex:"tabIndex"};o.fn.extend({_load:o.fn.load,load:function(G,J,K){if(typeof G!=="string"){return this._load(G)}var I=G.indexOf(" ");if(I>=0){var E=G.slice(I,G.length);G=G.slice(0,I)}var H="GET";if(J){if(o.isFunction(J)){K=J;J=null}else{if(typeof J==="object"){J=o.param(J);H="POST"}}}var F=this;o.ajax({url:G,type:H,dataType:"html",data:J,complete:function(M,L){if(L=="success"||L=="notmodified"){F.html(E?o("<div/>").append(M.responseText.replace(/<script(.|\s)*?\/script>/g,"")).find(E):M.responseText)}if(K){F.each(K,[M.responseText,L,M])}}});return this},serialize:function(){return o.param(this.serializeArray())},serializeArray:function(){return this.map(function(){return this.elements?o.makeArray(this.elements):this}).filter(function(){return this.name&&!this.disabled&&(this.checked||/select|textarea/i.test(this.nodeName)||/text|hidden|password|search/i.test(this.type))}).map(function(E,F){var G=o(this).val();return G==null?null:o.isArray(G)?o.map(G,function(I,H){return{name:F.name,value:I}}):{name:F.name,value:G}}).get()}});o.each("ajaxStart,ajaxStop,ajaxComplete,ajaxError,ajaxSuccess,ajaxSend".split(","),function(E,F){o.fn[F]=function(G){return this.bind(F,G)}});var r=e();o.extend({get:function(E,G,H,F){if(o.isFunction(G)){H=G;G=null}return o.ajax({type:"GET",url:E,data:G,success:H,dataType:F})},getScript:function(E,F){return o.get(E,null,F,"script")},getJSON:function(E,F,G){return o.get(E,F,G,"json")},post:function(E,G,H,F){if(o.isFunction(G)){H=G;G={}}return o.ajax({type:"POST",url:E,data:G,success:H,dataType:F})},ajaxSetup:function(E){o.extend(o.ajaxSettings,E)},ajaxSettings:{url:location.href,global:true,type:"GET",contentType:"application/x-www-form-urlencoded",processData:true,async:true,xhr:function(){return l.ActiveXObject?new ActiveXObject("Microsoft.XMLHTTP"):new XMLHttpRequest()},accepts:{xml:"application/xml, text/xml",html:"text/html",script:"text/javascript, application/javascript",json:"application/json, text/javascript",text:"text/plain",_default:"*/*"}},lastModified:{},ajax:function(M){M=o.extend(true,M,o.extend(true,{},o.ajaxSettings,M));var W,F=/=\?(&|$)/g,R,V,G=M.type.toUpperCase();if(M.data&&M.processData&&typeof M.data!=="string"){M.data=o.param(M.data)}if(M.dataType=="jsonp"){if(G=="GET"){if(!M.url.match(F)){M.url+=(M.url.match(/\?/)?"&":"?")+(M.jsonp||"callback")+"=?"}}else{if(!M.data||!M.data.match(F)){M.data=(M.data?M.data+"&":"")+(M.jsonp||"callback")+"=?"}}M.dataType="json"}if(M.dataType=="json"&&(M.data&&M.data.match(F)||M.url.match(F))){W="jsonp"+r++;if(M.data){M.data=(M.data+"").replace(F,"="+W+"$1")}M.url=M.url.replace(F,"="+W+"$1");M.dataType="script";l[W]=function(X){V=X;I();L();l[W]=g;try{delete l[W]}catch(Y){}if(H){H.removeChild(T)}}}if(M.dataType=="script"&&M.cache==null){M.cache=false}if(M.cache===false&&G=="GET"){var E=e();var U=M.url.replace(/(\?|&)_=.*?(&|$)/,"$1_="+E+"$2");M.url=U+((U==M.url)?(M.url.match(/\?/)?"&":"?")+"_="+E:"")}if(M.data&&G=="GET"){M.url+=(M.url.match(/\?/)?"&":"?")+M.data;M.data=null}if(M.global&&!o.active++){o.event.trigger("ajaxStart")}var Q=/^(\w+:)?\/\/([^\/?#]+)/.exec(M.url);if(M.dataType=="script"&&G=="GET"&&Q&&(Q[1]&&Q[1]!=location.protocol||Q[2]!=location.host)){var H=document.getElementsByTagName("head")[0];var T=document.createElement("script");T.src=M.url;if(M.scriptCharset){T.charset=M.scriptCharset}if(!W){var O=false;T.onload=T.onreadystatechange=function(){if(!O&&(!this.readyState||this.readyState=="loaded"||this.readyState=="complete")){O=true;I();L();T.onload=T.onreadystatechange=null;H.removeChild(T)}}}H.appendChild(T);return g}var K=false;var J=M.xhr();if(M.username){J.open(G,M.url,M.async,M.username,M.password)}else{J.open(G,M.url,M.async)}try{if(M.data){J.setRequestHeader("Content-Type",M.contentType)}if(M.ifModified){J.setRequestHeader("If-Modified-Since",o.lastModified[M.url]||"Thu, 01 Jan 1970 00:00:00 GMT")}J.setRequestHeader("X-Requested-With","XMLHttpRequest");J.setRequestHeader("Accept",M.dataType&&M.accepts[M.dataType]?M.accepts[M.dataType]+", */*":M.accepts._default)}catch(S){}if(M.beforeSend&&M.beforeSend(J,M)===false){if(M.global&&!--o.active){o.event.trigger("ajaxStop")}J.abort();return false}if(M.global){o.event.trigger("ajaxSend",[J,M])}var N=function(X){if(J.readyState==0){if(P){clearInterval(P);P=null;if(M.global&&!--o.active){o.event.trigger("ajaxStop")}}}else{if(!K&&J&&(J.readyState==4||X=="timeout")){K=true;if(P){clearInterval(P);P=null}R=X=="timeout"?"timeout":!o.httpSuccess(J)?"error":M.ifModified&&o.httpNotModified(J,M.url)?"notmodified":"success";if(R=="success"){try{V=o.httpData(J,M.dataType,M)}catch(Z){R="parsererror"}}if(R=="success"){var Y;try{Y=J.getResponseHeader("Last-Modified")}catch(Z){}if(M.ifModified&&Y){o.lastModified[M.url]=Y}if(!W){I()}}else{o.handleError(M,J,R)}L();if(X){J.abort()}if(M.async){J=null}}}};if(M.async){var P=setInterval(N,13);if(M.timeout>0){setTimeout(function(){if(J&&!K){N("timeout")}},M.timeout)}}try{J.send(M.data)}catch(S){o.handleError(M,J,null,S)}if(!M.async){N()}function I(){if(M.success){M.success(V,R)}if(M.global){o.event.trigger("ajaxSuccess",[J,M])}}function L(){if(M.complete){M.complete(J,R)}if(M.global){o.event.trigger("ajaxComplete",[J,M])}if(M.global&&!--o.active){o.event.trigger("ajaxStop")}}return J},handleError:function(F,H,E,G){if(F.error){F.error(H,E,G)}if(F.global){o.event.trigger("ajaxError",[H,F,G])}},active:0,httpSuccess:function(F){try{return !F.status&&location.protocol=="file:"||(F.status>=200&&F.status<300)||F.status==304||F.status==1223}catch(E){}return false},httpNotModified:function(G,E){try{var H=G.getResponseHeader("Last-Modified");return G.status==304||H==o.lastModified[E]}catch(F){}return false},httpData:function(J,H,G){var F=J.getResponseHeader("content-type"),E=H=="xml"||!H&&F&&F.indexOf("xml")>=0,I=E?J.responseXML:J.responseText;if(E&&I.documentElement.tagName=="parsererror"){throw"parsererror"}if(G&&G.dataFilter){I=G.dataFilter(I,H)}if(typeof I==="string"){if(H=="script"){o.globalEval(I)}if(H=="json"){I=l["eval"]("("+I+")")}}return I},param:function(E){var G=[];function H(I,J){G[G.length]=encodeURIComponent(I)+"="+encodeURIComponent(J)}if(o.isArray(E)||E.jquery){o.each(E,function(){H(this.name,this.value)})}else{for(var F in E){if(o.isArray(E[F])){o.each(E[F],function(){H(F,this)})}else{H(F,o.isFunction(E[F])?E[F]():E[F])}}}return G.join("&").replace(/%20/g,"+")}});var m={},n,d=[["height","marginTop","marginBottom","paddingTop","paddingBottom"],["width","marginLeft","marginRight","paddingLeft","paddingRight"],["opacity"]];function t(F,E){var G={};o.each(d.concat.apply([],d.slice(0,E)),function(){G[this]=F});return G}o.fn.extend({show:function(J,L){if(J){return this.animate(t("show",3),J,L)}else{for(var H=0,F=this.length;H<F;H++){var E=o.data(this[H],"olddisplay");this[H].style.display=E||"";if(o.css(this[H],"display")==="none"){var G=this[H].tagName,K;if(m[G]){K=m[G]}else{var I=o("<"+G+" />").appendTo("body");K=I.css("display");if(K==="none"){K="block"}I.remove();m[G]=K}o.data(this[H],"olddisplay",K)}}for(var H=0,F=this.length;H<F;H++){this[H].style.display=o.data(this[H],"olddisplay")||""}return this}},hide:function(H,I){if(H){return this.animate(t("hide",3),H,I)}else{for(var G=0,F=this.length;G<F;G++){var E=o.data(this[G],"olddisplay");if(!E&&E!=="none"){o.data(this[G],"olddisplay",o.css(this[G],"display"))}}for(var G=0,F=this.length;G<F;G++){this[G].style.display="none"}return this}},_toggle:o.fn.toggle,toggle:function(G,F){var E=typeof G==="boolean";return o.isFunction(G)&&o.isFunction(F)?this._toggle.apply(this,arguments):G==null||E?this.each(function(){var H=E?G:o(this).is(":hidden");o(this)[H?"show":"hide"]()}):this.animate(t("toggle",3),G,F)},fadeTo:function(E,G,F){return this.animate({opacity:G},E,F)},animate:function(I,F,H,G){var E=o.speed(F,H,G);return this[E.queue===false?"each":"queue"](function(){var K=o.extend({},E),M,L=this.nodeType==1&&o(this).is(":hidden"),J=this;for(M in I){if(I[M]=="hide"&&L||I[M]=="show"&&!L){return K.complete.call(this)}if((M=="height"||M=="width")&&this.style){K.display=o.css(this,"display");K.overflow=this.style.overflow}}if(K.overflow!=null){this.style.overflow="hidden"}K.curAnim=o.extend({},I);o.each(I,function(O,S){var R=new o.fx(J,K,O);if(/toggle|show|hide/.test(S)){R[S=="toggle"?L?"show":"hide":S](I)}else{var Q=S.toString().match(/^([+-]=)?([\d+-.]+)(.*)$/),T=R.cur(true)||0;if(Q){var N=parseFloat(Q[2]),P=Q[3]||"px";if(P!="px"){J.style[O]=(N||1)+P;T=((N||1)/R.cur(true))*T;J.style[O]=T+P}if(Q[1]){N=((Q[1]=="-="?-1:1)*N)+T}R.custom(T,N,P)}else{R.custom(T,S,"")}}});return true})},stop:function(F,E){var G=o.timers;if(F){this.queue([])}this.each(function(){for(var H=G.length-1;H>=0;H--){if(G[H].elem==this){if(E){G[H](true)}G.splice(H,1)}}});if(!E){this.dequeue()}return this}});o.each({slideDown:t("show",1),slideUp:t("hide",1),slideToggle:t("toggle",1),fadeIn:{opacity:"show"},fadeOut:{opacity:"hide"}},function(E,F){o.fn[E]=function(G,H){return this.animate(F,G,H)}});o.extend({speed:function(G,H,F){var E=typeof G==="object"?G:{complete:F||!F&&H||o.isFunction(G)&&G,duration:G,easing:F&&H||H&&!o.isFunction(H)&&H};E.duration=o.fx.off?0:typeof E.duration==="number"?E.duration:o.fx.speeds[E.duration]||o.fx.speeds._default;E.old=E.complete;E.complete=function(){if(E.queue!==false){o(this).dequeue()}if(o.isFunction(E.old)){E.old.call(this)}};return E},easing:{linear:function(G,H,E,F){return E+F*G},swing:function(G,H,E,F){return((-Math.cos(G*Math.PI)/2)+0.5)*F+E}},timers:[],fx:function(F,E,G){this.options=E;this.elem=F;this.prop=G;if(!E.orig){E.orig={}}}});o.fx.prototype={update:function(){if(this.options.step){this.options.step.call(this.elem,this.now,this)}(o.fx.step[this.prop]||o.fx.step._default)(this);if((this.prop=="height"||this.prop=="width")&&this.elem.style){this.elem.style.display="block"}},cur:function(F){if(this.elem[this.prop]!=null&&(!this.elem.style||this.elem.style[this.prop]==null)){return this.elem[this.prop]}var E=parseFloat(o.css(this.elem,this.prop,F));return E&&E>-10000?E:parseFloat(o.curCSS(this.elem,this.prop))||0},custom:function(I,H,G){this.startTime=e();this.start=I;this.end=H;this.unit=G||this.unit||"px";this.now=this.start;this.pos=this.state=0;var E=this;function F(J){return E.step(J)}F.elem=this.elem;if(F()&&o.timers.push(F)&&!n){n=setInterval(function(){var K=o.timers;for(var J=0;J<K.length;J++){if(!K[J]()){K.splice(J--,1)}}if(!K.length){clearInterval(n);n=g}},13)}},show:function(){this.options.orig[this.prop]=o.attr(this.elem.style,this.prop);this.options.show=true;this.custom(this.prop=="width"||this.prop=="height"?1:0,this.cur());o(this.elem).show()},hide:function(){this.options.orig[this.prop]=o.attr(this.elem.style,this.prop);this.options.hide=true;this.custom(this.cur(),0)},step:function(H){var G=e();if(H||G>=this.options.duration+this.startTime){this.now=this.end;this.pos=this.state=1;this.update();this.options.curAnim[this.prop]=true;var E=true;for(var F in this.options.curAnim){if(this.options.curAnim[F]!==true){E=false}}if(E){if(this.options.display!=null){this.elem.style.overflow=this.options.overflow;this.elem.style.display=this.options.display;if(o.css(this.elem,"display")=="none"){this.elem.style.display="block"}}if(this.options.hide){o(this.elem).hide()}if(this.options.hide||this.options.show){for(var I in this.options.curAnim){o.attr(this.elem.style,I,this.options.orig[I])}}this.options.complete.call(this.elem)}return false}else{var J=G-this.startTime;this.state=J/this.options.duration;this.pos=o.easing[this.options.easing||(o.easing.swing?"swing":"linear")](this.state,J,0,1,this.options.duration);this.now=this.start+((this.end-this.start)*this.pos);this.update()}return true}};o.extend(o.fx,{speeds:{slow:600,fast:200,_default:400},step:{opacity:function(E){o.attr(E.elem.style,"opacity",E.now)},_default:function(E){if(E.elem.style&&E.elem.style[E.prop]!=null){E.elem.style[E.prop]=E.now+E.unit}else{E.elem[E.prop]=E.now}}}});if(document.documentElement.getBoundingClientRect){o.fn.offset=function(){if(!this[0]){return{top:0,left:0}}if(this[0]===this[0].ownerDocument.body){return o.offset.bodyOffset(this[0])}var G=this[0].getBoundingClientRect(),J=this[0].ownerDocument,F=J.body,E=J.documentElement,L=E.clientTop||F.clientTop||0,K=E.clientLeft||F.clientLeft||0,I=G.top+(self.pageYOffset||o.boxModel&&E.scrollTop||F.scrollTop)-L,H=G.left+(self.pageXOffset||o.boxModel&&E.scrollLeft||F.scrollLeft)-K;return{top:I,left:H}}}else{o.fn.offset=function(){if(!this[0]){return{top:0,left:0}}if(this[0]===this[0].ownerDocument.body){return o.offset.bodyOffset(this[0])}o.offset.initialized||o.offset.initialize();var J=this[0],G=J.offsetParent,F=J,O=J.ownerDocument,M,H=O.documentElement,K=O.body,L=O.defaultView,E=L.getComputedStyle(J,null),N=J.offsetTop,I=J.offsetLeft;while((J=J.parentNode)&&J!==K&&J!==H){M=L.getComputedStyle(J,null);N-=J.scrollTop,I-=J.scrollLeft;if(J===G){N+=J.offsetTop,I+=J.offsetLeft;if(o.offset.doesNotAddBorder&&!(o.offset.doesAddBorderForTableAndCells&&/^t(able|d|h)$/i.test(J.tagName))){N+=parseInt(M.borderTopWidth,10)||0,I+=parseInt(M.borderLeftWidth,10)||0}F=G,G=J.offsetParent}if(o.offset.subtractsBorderForOverflowNotVisible&&M.overflow!=="visible"){N+=parseInt(M.borderTopWidth,10)||0,I+=parseInt(M.borderLeftWidth,10)||0}E=M}if(E.position==="relative"||E.position==="static"){N+=K.offsetTop,I+=K.offsetLeft}if(E.position==="fixed"){N+=Math.max(H.scrollTop,K.scrollTop),I+=Math.max(H.scrollLeft,K.scrollLeft)}return{top:N,left:I}}}o.offset={initialize:function(){if(this.initialized){return}var L=document.body,F=document.createElement("div"),H,G,N,I,M,E,J=L.style.marginTop,K='<div style="position:absolute;top:0;left:0;margin:0;border:5px solid #000;padding:0;width:1px;height:1px;"><div></div></div><table style="position:absolute;top:0;left:0;margin:0;border:5px solid #000;padding:0;width:1px;height:1px;" cellpadding="0" cellspacing="0"><tr><td></td></tr></table>';M={position:"absolute",top:0,left:0,margin:0,border:0,width:"1px",height:"1px",visibility:"hidden"};for(E in M){F.style[E]=M[E]}F.innerHTML=K;L.insertBefore(F,L.firstChild);H=F.firstChild,G=H.firstChild,I=H.nextSibling.firstChild.firstChild;this.doesNotAddBorder=(G.offsetTop!==5);this.doesAddBorderForTableAndCells=(I.offsetTop===5);H.style.overflow="hidden",H.style.position="relative";this.subtractsBorderForOverflowNotVisible=(G.offsetTop===-5);L.style.marginTop="1px";this.doesNotIncludeMarginInBodyOffset=(L.offsetTop===0);L.style.marginTop=J;L.removeChild(F);this.initialized=true},bodyOffset:function(E){o.offset.initialized||o.offset.initialize();var G=E.offsetTop,F=E.offsetLeft;if(o.offset.doesNotIncludeMarginInBodyOffset){G+=parseInt(o.curCSS(E,"marginTop",true),10)||0,F+=parseInt(o.curCSS(E,"marginLeft",true),10)||0}return{top:G,left:F}}};o.fn.extend({position:function(){var I=0,H=0,F;if(this[0]){var G=this.offsetParent(),J=this.offset(),E=/^body|html$/i.test(G[0].tagName)?{top:0,left:0}:G.offset();J.top-=j(this,"marginTop");J.left-=j(this,"marginLeft");E.top+=j(G,"borderTopWidth");E.left+=j(G,"borderLeftWidth");F={top:J.top-E.top,left:J.left-E.left}}return F},offsetParent:function(){var E=this[0].offsetParent||document.body;while(E&&(!/^body|html$/i.test(E.tagName)&&o.css(E,"position")=="static")){E=E.offsetParent}return o(E)}});o.each(["Left","Top"],function(F,E){var G="scroll"+E;o.fn[G]=function(H){if(!this[0]){return null}return H!==g?this.each(function(){this==l||this==document?l.scrollTo(!F?H:o(l).scrollLeft(),F?H:o(l).scrollTop()):this[G]=H}):this[0]==l||this[0]==document?self[F?"pageYOffset":"pageXOffset"]||o.boxModel&&document.documentElement[G]||document.body[G]:this[0][G]}});o.each(["Height","Width"],function(I,G){var E=I?"Left":"Top",H=I?"Right":"Bottom",F=G.toLowerCase();o.fn["inner"+G]=function(){return this[0]?o.css(this[0],F,false,"padding"):null};o.fn["outer"+G]=function(K){return this[0]?o.css(this[0],F,false,K?"margin":"border"):null};var J=G.toLowerCase();o.fn[J]=function(K){return this[0]==l?document.compatMode=="CSS1Compat"&&document.documentElement["client"+G]||document.body["client"+G]:this[0]==document?Math.max(document.documentElement["client"+G],document.body["scroll"+G],document.documentElement["scroll"+G],document.body["offset"+G],document.documentElement["offset"+G]):K===g?(this.length?o.css(this[0],J):null):this.css(J,typeof K==="string"?K:K+"px")}})})();
/**
 * @author Alexander Farkas
 * v. 1.1
 */

(function($){
	if(!document.defaultView || !document.defaultView.getComputedStyle){
		var oldCurCSS = jQuery.curCSS;
		jQuery.curCSS = function(elem, name, force){
			if(name !== 'backgroundPosition' || !elem.currentStyle || elem.currentStyle[ name ]){
				return oldCurCSS.apply(this, arguments);
			}
			var style = elem.style;
			if ( !force && style && style[ name ] ){
				return style[ name ];
			}
			return oldCurCSS(elem, 'backgroundPositionX', force) +' '+ oldCurCSS(elem, 'backgroundPositionY', force);
		};
	}
})(jQuery);

(function($) {
	
	function toArray(strg){
		strg = strg.replace(/left|top/g,'0px');
		strg = strg.replace(/right|bottom/g,'100%');
		strg = strg.replace(/([0-9\.]+)(\s|\)|$)/g,"$1px$2");
		var res = strg.match(/(-?[0-9\.]+)(px|\%|em|pt)\s(-?[0-9\.]+)(px|\%|em|pt)/);
		return [parseFloat(res[1],10),res[2],parseFloat(res[3],10),res[4]];
	}
	
	$.fx.step. backgroundPosition = function(fx) {
		if (!fx.bgPosReady) {
			
			var start = $.curCSS(fx.elem,'backgroundPosition');
			if(!start){//FF2 no inline-style fallback
				start = '0px 0px';
			}
			
			start = toArray(start);
			fx.start = [start[0],start[2]];
			
			var end = toArray(fx.options.curAnim.backgroundPosition);
			fx.end = [end[0],end[2]];
			
			fx.unit = [end[1],end[3]];
			fx.bgPosReady = true;
		}
		
		var nowPosX = [];
		nowPosX[0] = ((fx.end[0] - fx.start[0]) * fx.pos) + fx.start[0] + fx.unit[0];
		nowPosX[1] = ((fx.end[1] - fx.start[1]) * fx.pos) + fx.start[1] + fx.unit[1];           
		fx.elem.style.backgroundPosition = nowPosX[0]+' '+nowPosX[1];

	};
})(jQuery);/* Copyright (c) 2006 Brandon Aaron (http://brandonaaron.net)
 * Dual licensed under the MIT (http://www.opensource.org/licenses/mit-license.php) 
 * and GPL (http://www.opensource.org/licenses/gpl-license.php) licenses.
 *
 * $LastChangedDate: 2007-07-21 18:45:56 -0500 (Sat, 21 Jul 2007) $
 * $Rev: 2447 $
 *
 * Version 2.1.1
 */
(function($){$.fn.bgIframe=$.fn.bgiframe=function(s){if($.browser.msie&&/6.0/.test(navigator.userAgent)){s=$.extend({top:'auto',left:'auto',width:'auto',height:'auto',opacity:true,src:'javascript:false;'},s||{});var prop=function(n){return n&&n.constructor==Number?n+'px':n;},html='<iframe class="bgiframe"frameborder="0"tabindex="-1"src="'+s.src+'"'+'style="display:block;position:absolute;z-index:-1;'+(s.opacity!==false?'filter:Alpha(Opacity=\'0\');':'')+'top:'+(s.top=='auto'?'expression(((parseInt(this.parentNode.currentStyle.borderTopWidth)||0)*-1)+\'px\')':prop(s.top))+';'+'left:'+(s.left=='auto'?'expression(((parseInt(this.parentNode.currentStyle.borderLeftWidth)||0)*-1)+\'px\')':prop(s.left))+';'+'width:'+(s.width=='auto'?'expression(this.parentNode.offsetWidth+\'px\')':prop(s.width))+';'+'height:'+(s.height=='auto'?'expression(this.parentNode.offsetHeight+\'px\')':prop(s.height))+';'+'"/>';return this.each(function(){if($('> iframe.bgiframe',this).length==0)this.insertBefore(document.createElement(html),this.firstChild);});}return this;};})(jQuery);/*
 * jQuery Address Plugin v1.0
 * http://www.asual.com/jquery/address/
 *
 * Copyright (c) 2009 Rostislav Hristov
 * Dual licensed under the MIT and GPL licenses.
 * http://docs.jquery.com/License
 *
 * Date: 2009-04-28 16:54:00 +0300 (Tue, 28 Apr 2009)
 * Revision: 399
 */
(function($) {
	$.address = (function () {
		var _api = {};
		var _ready = false;
		
		var _activate = function() {					
			var _trigger = function(name) {
				$(this).trigger(
					$.extend($.Event(name), 
						(function() {
							var event = {
								value: this.value(),
								path: this.path(),
								pathNames: this.pathNames(),
								parameterNames: this.parameterNames(),
								parameters: {},
								queryString: this.queryString()
							};
							for (var i = 0, l = event.parameterNames.length; i < l; i++)
								event.parameters[event.parameterNames[i]] = this.parameter(event.parameterNames[i]);
							return event;
						}).call(this)
					)
				);
			};
		
			var _init = function() {
				_trigger.call($.address, 'init');
			};
			
			var _change = function() {
				_trigger.call($.address, 'change');
			};
	
			var _getHash = function() {
				var index = _l.href.indexOf('#');
				return index != -1 ? _ec(_dc(_l.href.substr(index + 1))) : '';
			};
			
			var _getWindow = function() {
				try {
					top.document;
					return top;
				} catch (e) {
					return window;
				}
			};
			
			var _strictCheck = function(value, force) {
				if (_opts.strict)
					value = force ? (value.substr(0, 1) != '/' ? '/' + value : value) : (value == '' ? '/' : value);
				return value;
			};
	
			var _ieLocal = function(value, direction) {
				return (_msie && _l.protocol == 'file:') ? 
					(direction ? _value.replace(/\?/, '%3F') : _value.replace(/%253F/, '?')) : value;
			};
	
			var _searchScript = function(el) {
				for (var i = 0, l = el.childNodes.length, s; i < l; i++) {
					if (el.childNodes[i].src)
						_url = String(el.childNodes[i].src);
					if (s = _searchScript(el.childNodes[i]))
						return s;
				}
			};
	
			var _listen = function() {
				if (!_silent) {
					var hash = _getHash();
					var diff = !(_value == hash);
					if (_safari && _version < 523) {
						if (_length != _h.length) {
							_length = _h.length;
							if (typeof _stack[_length - 1] != UNDEFINED)
								_value = _stack[_length - 1];
							_update();
						}
					} else if (_msie && diff) {
						if (_version < 7)
							_l.reload();
						else
							_setters.value(hash);
					} else if (diff) {
						_value = hash;
						_update();
					}
				}
			};
	
			var _update = function() {
				_change();
				_st(_track, 10);  //10
			};
	
			var _track = function() {
				var value = (_l.pathname + (/\/$/.test(_l.pathname) ? '' : '/') + _getters.value()).replace(/\/\//, '/').replace(/^\/$/, '');
				var fn = window[_opts.tracker];
				if (typeof fn == FUNCTION)
					fn(value);
				else if (typeof pageTracker != UNDEFINED && typeof pageTracker._trackPageview == FUNCTION)
					pageTracker._trackPageview(value);
				else if (typeof urchinTracker == FUNCTION) 
					urchinTracker(value);
			};
			
			var _htmlWrite = function() {
				var doc = _iframe.contentWindow.document;
				doc.open();
				doc.write('<html><head><title>' + _d.title + '</title><script>var ' + ID + ' = "' + _getHash() + '";</script></head></html>');
				doc.close();
			};
	
			var _load = function() {
				if (!_loaded) {
					_loaded = true;
					$('a').attr('xref', function() {
						return $(this).attr('href');
					});				
					
					if (_msie && _version < 8) {					
						$('body').prepend('<iframe id="' + ID + '" src="javascript:false;" width="0" height="0"></iframe>');
						_iframe = _d.getElementById(ID);
						_st(function() {
							$(_iframe).bind('load', function() {
								var win = _iframe.contentWindow;
								var src = win.location.href;
								_value = (typeof win[ID] != UNDEFINED ? win[ID] : '');
								if (_value != _getHash()) {
									_update();
									_l.hash = _ieLocal(_value, true);
								}
							});
							if (typeof _iframe.contentWindow[ID] == UNDEFINED) 
								_htmlWrite();
						}, 50); //50
					} else if (_safari) {
						if (_version < 418) {
							$(_d.body).append('<form id="' + ID + '" style="position:absolute;top:-9999px;" method="get"></form>');
							_form = _d.getElementById(ID);
						}
						if (typeof _l[ID] == UNDEFINED) _l[ID] = {};
						if (typeof _l[ID][_l.pathname] != UNDEFINED) _stack = _l[ID][_l.pathname].split(',');
					}
					
					_st(function() {
						_init();
						_change();
						_track();
					}, 1); //1
					
					if (_msie && _version >= 8)
						_d.body.onhashchange = _listen;
					else
						_si(_listen, 50);
						
					$('a').attr('href', function() {
						return $(this).attr('xref');
					}).removeAttr('xref');
					
					$('a[rel*=address:]').address();
				}
			};
			
			var _getters = {
				baseURL: function() {
					var url = _l.href;
					if (url.indexOf('#') != -1)
						url = url.substr(0, url.indexOf('#'));
					if (url.substr(url.length - 1) == '/')
						url = url.substr(0, url.length - 1);
					return url;
				}, 
				strict: function() {
					return _opts.strict;
				},
				history: function() {
					return _opts.history;
				},
				tracker: function() {
					return _opts.tracker;
				},
				title: function() {
					return _d.title;
				},
				value: function() {
					if (!_supported) return null;
					return _dc(_strictCheck(_ieLocal(_value, false), false));
				},
				path: function() {
					var value = this.value();
					return (value.indexOf('?') != -1) ? value.split('?')[0] : value;
				},
				pathNames: function() {
					var path = this.path();
					var names = path.split('/');
					if (path.substr(0, 1) == '/' || path.length == 0)
						names.splice(0, 1);
					if (path.substr(path.length - 1, 1) == '/')
						names.splice(names.length - 1, 1);
					return names;
				},
				queryString: function() {
					var value = this.value();
					var index = value.indexOf('?');
					return (index != -1 && index < value.length) ? value.substr(index + 1) : '';
				},
				parameter: function(param) {
					var value = this.value();
					var index = value.indexOf('?');
					if (index != -1) {
						value = value.substr(index + 1);
						var params = value.split('&');
						var p, i = params.length;
						while(i--) {
							p = params[i].split('=');
							if (p[0] == param)
								return p[1];
						}
					}
				},
				parameterNames: function() {
					var value = this.value();
					var index = value.indexOf('?');
					var names = [];
					if (index != -1) {
						value = value.substr(index + 1);
						if (value != '' && value.indexOf('=') != -1) {
							var params = value.split('&');
							var i = 0;
							while(i < params.length) {
								names.push(params[i].split('=')[0]);
								i++;
							}
						}
					}
					return names;
				}        
			};
			
			var _setters = {
				strict: function(strict) {
					_opts.strict = strict;
				},
				history: function(history) {
					_opts.history = history;
				},
				tracker: function(tracker) {
					_opts.tracker = tracker;
				},
				title: function(title) {
					_st(function() {
						_title = _d.title = title;
						if (_juststart && _iframe && _iframe.contentWindow && _iframe.contentWindow.document) {
							_iframe.contentWindow.document.title = title;
							_juststart = false;
						}
						if (!_justset && _mozilla)
							_l.replace(_l.href.indexOf('#') != -1 ? _l.href : _l.href + '#');
						_justset = false;
					}, 50); //50
				},
				value: function(value) {
					value = _ec(_dc(_strictCheck(value, true)));
					if (value == '/') value = '';
					if (_value == value) return;
					_justset = true;
					_value = value;
					_silent = true;
					_update();
					_stack[_h.length] = _value;
					if (_safari) {
						if (_opts.history) {
							_l[ID][_l.pathname] = _stack.toString();
							_length = _h.length + 1;
							if (_version < 418) {
								if (_l.search == '') {
									_form.action = '#' + _value;
									_form.submit();
								}
							} else if (_version < 523 || _value == '') {
								var evt = _d.createEvent('MouseEvents');
								evt.initEvent('click', true, true);
								var anchor = _d.createElement('a');
								anchor.href = '#' + _value;
								anchor.dispatchEvent(evt);                
							} else {
								_l.hash = '#' + _value;
							}
						} else {
							_l.replace('#' + _value);
						}
					} else if (_value != _getHash()) {
						if (_opts.history)
							_l.hash = '#' + _ieLocal(_value, true);
						else
							_l.replace('#' + _value);
					}
					if ((_msie && _version < 8) && _opts.history) {
						_st(_htmlWrite, 50); //50
					}
					if (_safari)
						_st(function(){ _silent = false; }, 1);
					else
						_silent = false;
				}
			};
	
			var ID = 'jQueryAddress',
				FUNCTION = 'function',
				UNDEFINED = 'undefined',
				_browser = $.browser, 
				_version = parseFloat($.browser.version),
				_mozilla = _browser.mozilla,
				_msie = _browser.msie,
				_opera = _browser.opera,
				_safari = _browser.safari,
				_supported = false,
				_t = _getWindow(),
				_d = _t.document,
				_h = _t.history, 
				_l = _t.location,
				_si = setInterval,
				_st = setTimeout, 
				_dc = decodeURI,
				_ec = encodeURI,
				_agent = navigator.userAgent,            
				_iframe,
				_form,
				_url,
				_title = _d.title, 
				_length = _h.length, 
				_loaded = false,
				_silent = false,
				_justset = true,
				_juststart = true,
				_stack = [], 
				_listeners = {}, 
				_value = _getHash(),
				_opts = {history: true, strict: true};
			
			if (_msie)
				_version = parseFloat(_agent.substr(_agent.indexOf('MSIE') + 4));
			
			_supported = 
				(_mozilla && _version >= 1) || 
				(_msie && _version >= 6) ||
				(_opera && _version >= 9.5) ||
				(_safari && _version >= 312);
				
			if (_supported) {
			
				for (var i = 1; i < _length; i++)
					_stack.push('');
					
				_stack.push(_getHash());
			
				if (_msie && _l.hash != _getHash())
					_l.hash = '#' + _ieLocal(_getHash(), true);
	
				if (_opera) 
					history.navigationMode = 'compatible'; 
				
				_searchScript(document);
				var _qi = _url.indexOf('?');
				if (_url && _qi > -1) {
					var param, params = _url.substr(_qi + 1).split('&');
					for (var i = 0, p; p = params[i]; i++) {
						param = p.split('=');
						if (/^(history|strict)$/.test(param[0])) {
							_opts[param[0]] = (isNaN(param[1]) ? /^(true|yes)$/i.test(param[1]) : (parseInt(param[1]) != 0));
						}
						if (/^tracker$/.test(param[0]))
							_opts[param[0]] = param[1];
					}
				}
	
				$(_load);
				
			} else if ((!_supported && _l.href.indexOf('#') != -1) || 
				(_safari && _version < 418 && _l.href.indexOf('#') != -1 && _l.search != '')){
				_d.open();
				_d.write('<html><head><meta http-equiv="refresh" content="0;url=' + 
					_l.href.substr(0, _l.href.indexOf('#')) + '" /></head></html>');
				_d.close();
			} else {
				_track();
			}
	
			$.each(('init,change').split(','), function(i, name){
				_api[name] = function(data, fn){
					$($.address).bind(name, fn || data, fn && data);
					return this;
				};
			});
			
			$.each(('baseURL,strict,history,tracker,title,value').split(','), function(i, name){
				_api[name] = function(value){
					if (typeof value != 'undefined') {
						if (_supported)
							_setters[name](value);
						return $.address;
					} else {
						return _getters[name]();
					}
				};
			});
	
			$.each(('path,pathNames,queryString,parameter,parameterNames').split(','), function(i, name){
				_api[name] = function(value){
					return _getters[name](value);
				};
			});
			
			_ready = true;
			$(document).trigger('onAddressActivated');
			$(document).unbind('onAddressActivated');
		};
			
		_api['activate'] = function(){
			_activate();
			return this;
		};

		_api['ready'] = function(){
			return _ready;
		};				
		
		return _api;
	})();

	$.fn.address = function (fn) {
		$(this).click(function() {
			var value = fn ? fn.call(this) : 
			/address:/.test($(this).attr('rel')) ? $(this).attr('rel').split('address:')[1].split(' ')[0] : 
			$(this).attr('href').replace(/^#/, '');
			$.address.value(value);
				return false;
		});
	};
}(jQuery));
// there needs to be empty functions setup for the debug logger
jQuery.dr_console = {
		logFunction: function(){},
		logVar: function(){}
};

/* Copyright (c) 2008 Gilberto Saraiva (saraivagilberto@gmail.com || http://gsaraiva.projects.pro.br)
 * Dual licensed under the MIT (http://www.opensource.org/licenses/mit-license.php)
 * and GPL (http://www.opensource.org/licenses/gpl-license.php) licenses.
 *
 * Version: 2008.0.1.2 -
 * Under development and testing
 *
 * Contributors:
 *    Marc van Neerven (marc@smartsite.nl) - Javascript .apply structure (function.this = current filter)
 *
 * Requires: $ 1.2+
 *
 * Support/Site: http://gsaraiva.projects.pro.br/openprj/?page=$namespace
 */

(function( $ ){
  $.fn.extend({ curReturn: null, $Init: $.fn.init });

  $.fn.extend({
  	init: function( selector, context ) {
      $.fn.curReturn = new $.fn.$Init(selector, context);
      return $.fn.curReturn;
  	}
  });

  $.extend({
    namespaceData: {},
    namespaceExtend: function(NameSpaces){
      if(eval(NameSpaces) != undefined){ $.extend(eval(NameSpaces), {}); }else{ eval(NameSpaces + " = {};"); }
    },
    namespace: function(namespaces, objects, inherited){

      // check to see if they want to make existing jQuery plugins available
	  if(arguments.length < 3) inherited = true;  
      
	  if(typeof objects == "function"){
        if(namespaces.match(".")){
          var nss = namespaces.split(".");
          var snss = "";
          for(var i = 0; i < nss.length; i++){
            snss += "['" + nss[i] + "']";

            $.namespaceExtend("$.namespaceData" + snss);
            $.namespaceExtend("$.fn" + snss);
          }
		  
          eval("$.namespaceData" + snss + " = arguments[1];");
          eval("$.fn" + snss + " = " + "function(){ return eval(\"$.namespaceData" + snss + ( (inherited) ? ".apply" : "") + "($.fn.curReturn, arguments)\"); }");

        }else{
          $.extend({
            namespaces: function(){
              return objects($.fn.curReturn);
            }
          });
        }
      }else{
             
        for(var space in objects){
          $.namespace(namespaces + "." + space, objects[space], inherited);
        };
      }
    }
  });
})( jQuery );var DR=window.DR||function(){
};
DR.extend=function(_1,_2){
YAHOO.extend(_1,_2);
};
DR.Global=function(){
};
DR.Utils=function(){
};
DR.Widgets=function(){
};
DR.VERSION="1.0";
DR.VERSION_CREATION_DATE="200909041131";
DR.BUILD_ID="200909041131";
DR.FRAMEWORK_PATH="/drui/200909041131/";
DR.IMAGE_PATH=DR.FRAMEWORK_PATH+"images/";
DR.BLANK_PAGE_URL=DR.FRAMEWORK_PATH+"html/Blank.html";
DR.CONTENT_AREA_ID="contentArea";
DR.CONTENT_TABLE_ID="pageAreaContainers";
DR.LOGIN_URL="";
DR.POD_MENU=null;
DR.TOP_MENU=null;
DR.USER_DATA=null;
DR.USER_LOCALE="en_US";
DR.IS_INTERNAL_USER=false;
(function($){
var _4=[];
$.dr=window.jQuery.dr||{addDomReadyEvent:function(_5,_6){
var _7=(_6)?_6:"domReadyNormal";
$(document).bind(_7,_5);
},triggerDomReadyEvents:function(){
$(document).trigger("domReadyEarly");
$(document).trigger("domReadyNormal");
$(document).trigger("domReadyLate");
},addUnobtrusiveEvent:function(_8,_9){
var _a=(_9)?_9:"unobtrusiveEventNormal";
$(document).bind(_a,_8);
},triggerUnobtrusiveEvents:function(_b){
$(document).trigger("unobtrusiveEventEarly",[_b]);
$(document).trigger("unobtrusiveEventNormal",[_b]);
$(document).trigger("unobtrusiveEventLate",[_b]);
},addPlugin:function(_c,_d){
if(_c&&typeof _d=="function"){
if(typeof _4[_c]==="undefined"){
_4[_c]=[];
}
_4[_c].push(_d);
}
},getPlugins:function(_e){
return _4[_e];
}};
var _f=function(){
$.dr.triggerUnobtrusiveEvents(document);
};
$.dr.addDomReadyEvent(_f);
})(jQuery);
var overlayStack,pageInfo={};
var Utils;
var BrowserDetect;
var customOnload;
var PanelSet;
var Cookie;
var DatePicker;
var ListControls;
var FauxTree;
var ModalOverlay;
var InlineModalOverlay;
var FormUtils;
var submitActionForm;
var Toggle;
var getElem;
var disableButton;
var disableSearchButton;
var iframeCallback;
DR.Global.init=function(){
$.dr.triggerDomReadyEvents();
if(typeof customOnload=="function"){
customOnload();
}
DR.Utils.customOnload();
};
DR.Global.modalInit=function(){
var _10=new DR.Utils.PageSizer();
var _11=(navigator.userAgent.indexOf("AppleWebKit")>-1);
if(document.all||_11){
window.setTimeout(function(){
_10.initModalScroller();
},100);
}
if(typeof customOnload=="function"){
customOnload();
}
$.dr.triggerDomReadyEvents();
DR.Utils.customOnload();
if(!document.all&&!_11){
_10.initModalScroller();
}
if(parent&&parent.overlayStack){
}
};
var AJAX_LOADING="Loading...";
var BUTTON_PROCESSING="Processing...";
var BUTTON_AUTHORIZING="Authorizing...";
var BUTTON_SEARCHING="Searching...";
var BUTTON_RENAME="Rename";
var BUTTON_PROPERTIES="Properties";
var BUTTON_MOVE_UP="Move Up";
var BUTTON_MOVE_DOWN="Move Down";
var BUTTON_DELETE="Delete";
var BUTTON_CLOSE="Close";
var BUTTON_COLLAPSE="Collapse";
var BUTTON_DONE="Done";
var BUTTON_EXPAND="Expand";
var BUTTON_SAVE="Save";
var BUTTON_NEXT="Next";
var BUTTON_YES="Yes";
var BUTTON_NO="No";
var BUTTON_FINISH="Finish";
var BUTTON_CANCEL="Cancel";
var BUTTON_OK="OK";
(function($){
$.dr.utils=window.jQuery.dr.utils||{};
$.dr.utils.logError=function(_13,err){
if(window.console){
console.error(_13);
if(err){
console.error("Error: ",err);
}
}
};
$.dr.utils.evalString=function(str,_16){
var o;
if(!str){
return;
}
if(str.trim().length==0){
return;
}
try{
eval("o="+str);
}
catch(e){
if(_16){
$.dr.utils.logError(_16,e);
}
o="error";
}
return o;
};
$.fn.setData=function(_18){
return this.each(function(){
for(var _19 in _18){
$(this).data(_19,_18[_19]);
}
});
};
})(jQuery);
DR.Utils.BrowserDetect={init:function(){
this.browser=this.searchString(this.dataBrowser)||"An unknown browser";
this.version=this.searchVersion(navigator.userAgent)||this.searchVersion(navigator.appVersion)||"an unknown version";
this.OS=this.searchString(this.dataOS)||"an unknown OS";
this.isStandardsMode=this.checkStandardsMode();
},checkStandardsMode:function(){
return document.compatMode=="CSS1Compat";
},getAvailableContentWidth:function(){
var _1a=null;
if(this.isStandardsMode){
if(document.documentElement){
_1a=document.documentElement.clientWidth;
}
}else{
_1a=document.body.clientWidth;
}
return _1a;
},getAvailableContentHeight:function(){
var _1b=null;
if(this.isStandardsMode){
if(document.documentElement){
_1b=document.documentElement.clientHeight;
}
}else{
_1b=document.body.clientHeight;
}
return _1b;
},searchString:function(_1c){
for(var i=0;i<_1c.length;i++){
var _1e=_1c[i].string;
var _1f=_1c[i].prop;
this.versionSearchString=_1c[i].versionSearch||_1c[i].identity;
if(_1e){
if(_1e.indexOf(_1c[i].subString)!=-1){
return _1c[i].identity;
}
}else{
if(_1f){
return _1c[i].identity;
}
}
}
},isIE6:function(){
if(this.version==6&&this.browser=="Explorer"){
return true;
}
return false;
},searchVersion:function(_20){
var _21=_20.indexOf(this.versionSearchString);
if(_21==-1){
return;
}
return parseFloat(_20.substring(_21+this.versionSearchString.length+1));
},dataBrowser:[{string:navigator.userAgent,subString:"OmniWeb",versionSearch:"OmniWeb/",identity:"OmniWeb"},{string:navigator.vendor,subString:"Apple",identity:"Safari"},{prop:window.opera,identity:"Opera"},{string:navigator.vendor,subString:"iCab",identity:"iCab"},{string:navigator.vendor,subString:"KDE",identity:"Konqueror"},{string:navigator.userAgent,subString:"Firefox",identity:"Firefox"},{string:navigator.vendor,subString:"Camino",identity:"Camino"},{string:navigator.userAgent,subString:"Netscape",identity:"Netscape"},{string:navigator.userAgent,subString:"MSIE",identity:"Explorer",versionSearch:"MSIE"},{string:navigator.userAgent,subString:"Gecko",identity:"Mozilla",versionSearch:"rv"},{string:navigator.userAgent,subString:"Mozilla",identity:"Netscape",versionSearch:"Mozilla"}],dataOS:[{string:navigator.platform,subString:"Win",identity:"Windows"},{string:navigator.platform,subString:"Mac",identity:"Mac"},{string:navigator.platform,subString:"Linux",identity:"Linux"}]};
DR.Utils.BrowserDetect.init();
DR.Utils.Cookie=function(_22){
this.name=_22;
this.expires=null;
this.path=null;
this.domain=null;
this.defaultExpireDays=365;
this.secure=null;
this.type="Single";
this.value=null;
this.valueLoaded=false;
this.arrayValues=[];
this.arrayValuesLoaded=false;
this.arraySeperator="^";
this.nameArrayValues=[];
this.nameArrayValuesLoaded=false;
this.nameArraySeperator="&";
this.nameArrayInnerSeperator=":";
};
DR.Utils.Cookie.ERROR_VALID_DATE="Enter a valid date.";
DR.Utils.Cookie.prototype={setExpires:function(_23){
if(!this.nameArrayValuesLoaded){
this.load();
}
if(_23!==null){
_23=new Date(_23);
if(_23.constructor==Date){
this.expires=_23.toGMTString();
}else{
alert(DR.Utils.Cookie.ERROR_VALID_DATE);
}
}
},setExpireDays:function(_24){
this.defaultExpireDays=_24;
},load:function(){
var _25=document.cookie;
if(_25===""){
return false;
}
var _26=_25.indexOf(this.name+"=");
if(_26!=-1){
_26+=this.name.length+1;
var _27=_25.indexOf(";",_26);
if(_27==-1){
_27=_25.length;
}
var _28=unescape(_25.substring(_26,_27));
if(this.type=="Single"){
this.value=_28;
this.nameArrayValuesLoaded=true;
}else{
if(this.type=="NameValuePair"){
this.splitCookiePairs(_28);
}else{
if(this.type=="Array"){
this.splitCookieArray(_28);
}
}
}
return true;
}
return false;
},save:function(){
var v="";
if(this.type=="Single"){
v=this.value;
}else{
if(this.type=="NameValuePair"){
v=this.joinNameValuePairs();
}else{
if(this.type=="Array"){
v=this.joinArrayValues();
}
}
}
if(this.expires===null){
this.expires=this.getDateOffset(this.defaultExpireDays);
}
document.cookie=this.name+"="+escape(v)+((this.expires)?"; expires="+this.expires:"")+((this.path)?"; path="+this.path:"")+((this.domain)?"; domain="+this.domain:"")+((this.secure)?"; secure":"");
},setValue:function(_2a){
if(!this.nameArrayValuesLoaded){
this.load();
}
this.value=_2a;
this.type="Single";
this.save();
},clear:function(){
var c=new Date();
document.cookie=this.name+"="+((this.expires)?"; expires="+c.toGMTString():"")+((this.path)?"; path="+this.path:"")+((this.domain)?"; domain="+this.domain:"")+((this.secure)?"; secure":"");
this.name=null;
this.expires=null;
this.path=null;
this.domain=null;
this.defaultExpireDays=null;
this.secure=null;
this.type=null;
this.value=null;
this.valueLoaded=null;
this.arrayValues=null;
this.arrayValuesLoaded=null;
this.arraySeperator=null;
this.nameArrayValues=null;
this.nameArrayValuesLoaded=null;
this.nameArraySeperator=null;
this.nameArrayInnerSeperator=null;
},addArrayValue:function(_2c){
this.type="Array";
if(!this.arrayValuesLoaded){
this.load();
}
var _2d="";
var ary=this.arrayValues;
var _2f=[];
var k=0;
if(ary.length>0){
for(var i=0;i<ary.length;i++){
if(ary[i]!=_2c){
_2d+=ary[i]+this.arraySeperator;
_2f[k]=ary[i];
k++;
}
}
}
_2f[k]=_2c;
_2d+=_2c+this.arraySeperator;
this.arrayValues=_2f;
this.value=_2d;
this.save();
},removeArrayValue:function(_32){
this.type="Array";
var _33="";
var ary=this.arrayValues;
var _35=[];
var k=0;
for(var i=0;i<ary.length;i++){
if(ary[i]!=_32){
_33+=ary[i]+this.arraySeperator;
_35[k]=ary[i];
k++;
}
}
this.arrayValues=_35;
this.value=_33;
this.save();
},setNameValuePair:function(_38,_39){
var v=_39+"";
if(_38.indexOf("&")==-1&&_38.indexOf(":")==-1&&v.indexOf("&")==-1&&v.indexOf(":")==-1){
if(!this.nameArrayValuesLoaded){
this.load();
}
this.type="NameValuePair";
this.nameArrayValues[_38]=_39;
this.save();
}
},getValue:function(_3b){
if(!this.nameArrayValuesLoaded){
this.load();
}
if(_3b){
return this.nameArrayValues[_3b];
}else{
return this.value;
}
},removeValue:function(_3c){
if(!this.nameArrayValuesLoaded){
this.load();
}
delete this.nameArrayValues.name;
this.save();
},removeAllValues:function(){
if(!this.nameArrayValuesLoaded){
this.load();
}
this.nameArrayValues=[];
},splitCookiePairs:function(_3d){
var _3e=_3d.split(this.nameArraySeperator);
for(var i=0;i<_3e.length;i++){
_3e[i]=_3e[i].split(this.nameArrayInnerSeperator);
}
this.nameArrayValues=[];
for(var j=0;j<_3e.length;j++){
this.nameArrayValues[_3e[j][0]]=_3e[j][1];
}
this.joinNameValuePairs();
},splitCookieArray:function(_41){
var ary=[];
if(_41!==null){
var i=0;
while(_41.indexOf(this.arraySeperator)!="-1"){
ary[i]=_41.substring(0,_41.indexOf(this.arraySeperator));
i++;
_41=_41.substring(_41.indexOf(this.arraySeperator)+1,_41.length);
}
}
this.arrayValues=ary;
this.joinArrayValues();
},joinNameValuePairs:function(){
var _44=[];
for(var i in this.nameArrayValues){
_44[_44.length]=i+this.nameArrayInnerSeperator+this.nameArrayValues[i];
}
var v=_44.join(this.nameArraySeperator);
this.value=v;
return v;
},joinArrayValues:function(){
var v="";
if(this.arrayValues.length>0){
for(var i=0;i<this.arrayValues.length;i++){
v+=this.arrayValues[i]+this.arraySeperator;
}
}
this.value=v;
return v;
},getDateOffset:function(_49){
var _4a=new Date();
_4a.setTime(_4a.getTime());
if(_49){
var _4b=_49*1000*60*60*24;
var _4c=new Date(_4a.getTime()+(_4b));
return _4c;
}
}};
DR.Utils.replaceCSSClass=function(_4d,_4e,_4f){
_4d=(typeof _4d=="object")?_4d:document.getElementById(_4d);
if(_4d){
_4d.className=_4d.className.replace(_4e,_4f).trim();
}
};
DR.Utils.hasCSSClass=function(_50,_51){
_50=(typeof _50=="object")?_50:document.getElementById(_50);
if(_50){
if(_50.className.indexOf(_51)>-1){
return true;
}
}
return false;
};
DR.Utils.removeCSSClass=function(_52,_53){
_52=(typeof _52=="object")?_52:document.getElementById(_52);
if(_52){
_52.className=_52.className.replace(_53,"").trim();
}
};
DR.Utils.addCSSClass=function(_54,_55){
_54=(typeof _54=="object")?_54:document.getElementById(_54);
if(_54){
DR.Utils.removeCSSClass(_54,_55);
_54.className=(_55+" "+_54.className).trim();
}
};
DR.Utils.setCSSClass=function(_56,_57){
_56=(typeof _56=="object")?_56:document.getElementById(_56);
if(_56){
_56.className=_57;
}
};
DR.Utils.getStyle=function(id,_59){
var obj=(typeof id=="object")?id:document.getElementById(id);
var _5b="";
if(document.defaultView&&document.defaultView.getComputedStyle){
DR.Utils.styleObj=document.defaultView.getComputedStyle(obj,null);
_5b=DR.Utils.styleObj?eval("DR.Utils.styleObj."+_59):null;
}else{
if(obj.currentStyle){
_5b=obj.currentStyle[_59];
}
}
return _5b;
};
DR.Utils.disableListLink=function(id,_5d){
var li=(typeof id=="object")?id:document.getElementById(id);
DR.Utils.addCSSClass(li,"disabled");
var a=li.getElementsByTagName("a");
if(a.length==1){
var _60=a[0];
_60.removeAttribute("href");
if(typeof (_60.onclick)=="function"){
_60.onclick_disabled=_60.onclick;
}
if(typeof (_5d)=="function"){
_60.onclick=_5d;
}
}
};
DR.Utils.enableListLink=function(id){
var li=(typeof id=="object")?id:document.getElementById(id);
DR.Utils.removeCSSClass(li,"disabled");
var a=li.getElementsByTagName("a");
if(a.length==1){
var _64=a[0];
_64.setAttribute("href","#");
var od=_64.getAttribute("onclick_disabled");
if(typeof (od)=="function"){
_64.onclick=_64.onclick_disabled;
}else{
if(typeof (od)=="object"){
_64.onclick=eval(_64.onclick_disabled);
}
}
_64.removeAttribute("onclick_disabled");
}
};
DR.Utils.insertBefore=function(_66,_67,_68){
var _69=_66.tagName.toLowerCase();
if(document.all&&_69=="td"){
var n=parentNode.appendChild(_67,_68);
_66.appendChild(_68,n);
}else{
_66.insertBefore(_67,_68);
}
};
DR.Utils.insertAfter=function(_6b,_6c,_6d){
return _6b.insertBefore(_6c,_6d.nextSibling);
};
DR.Utils.addToBody=function(el){
var _6f=document.getElementsByTagName("BODY")[0];
var _70=_6f.firstChild;
_6f.insertBefore(el,_70);
_6f=null;
_70=null;
return el;
};
DR.Utils.attachCssStyleSheet=function(url){
var _72=document.getElementsByTagName("head")[0];
var _73=document.createElement("link");
_73.type="text/css";
_73.rel="stylesheet";
_73.href=url;
_72.appendChild(_73);
};
DR.Utils.getElem=function(id){
var o=document.getElementById(id);
if(o){
return o;
}else{
window.status="Html element not found: "+id;
return null;
}
};
DR.Utils.getElementsByClassName=function(_76,_77){
if(_76.indexOf(".")==-1){
_76="."+_76;
}
if(typeof _77=="object"){
return jQuery(_76,_77);
}else{
if(typeof _77=="string"&&_77!==""){
if(_77.indexOf("#")==-1){
_77="#"+_77;
}
return jQuery(_77+" "+_76);
}else{
return jQuery(_76);
}
}
};
DR.Utils.getFirstElementByClassName=function(_78,_79){
var _7a=DR.Utils.getElementsByClassName(_78,_79);
if(_7a.length>0){
return _7a[0];
}
return null;
};
DR.Utils.getElementsBySelectorPath=function(_7b,_7c){
if(_7b.indexOf(".")==-1){
_7b="."+_7b;
}
if(typeof _7c=="object"){
return jQuery(_7b,_7c);
}else{
if(typeof _7c=="string"&&_7c!==""){
if(_7c.indexOf("#")==-1){
_7c="#"+_7c;
}
return jQuery(_7c+" "+_7b);
}else{
return jQuery(_7b);
}
}
};
DR.Utils.getFirstElementBySelectorPath=function(_7d,_7e){
var _7f=DR.Utils.getElementsBySelectorPath(_7d,_7e);
if(_7f.length>0){
return _7f[0];
}
return null;
};
DR.Utils.attachDRFrameworkCSS=function(){
var _80=navigator.appName;
var _81=(_80.indexOf("Explorer")>-1);
var _82=(navigator.appVersion.indexOf("MSIE 7")>-1);
var _83=(navigator.userAgent.indexOf("AppleWebKit")>-1);
var _84="dr-stylesheet-ff-compressed.css";
if(_82){
_84="dr-stylesheet-ie7-compressed.css";
}else{
if(_81){
_84="dr-stylesheet-ie6-compressed.css";
}
}
var url=DR.FRAMEWORK_PATH+"css/"+_84;
DR.Utils.attachCssStyleSheet(url);
};
DR.Utils.replaceHtml=function(el,_87){
var div=typeof el==="string"?document.getElementById(el):el;
return jQuery(div).html(_87);
};
DR.Utils.DragObject=function(_89){
if(typeof _89=="object"){
this.type="Absolute";
this.dragObj=_89;
this.parentObj=null;
this.moveCallback=null;
this.stopCallback=null;
this.isDragging=false;
this.isInitialized=false;
this.cursorX=0;
this.cursorY=0;
this.dragObjLeft=0;
this.dragObjTop=0;
this.mouseXOffest=14;
this.mouseYOffest=19;
this.moveDragFunc=null;
this.stopDragFunc=null;
this.snapToMouse=false;
}else{
return null;
}
};
DR.Utils.DragObject.prototype={setType:function(_8a,_8b){
if(typeof _8a=="string"){
this.type=_8a;
}
if(typeof _8b=="object"){
this.parentObj=_8b;
}
},setSnapToMouse:function(_8c){
this.snapToMouse=Boolean(_8c);
},setMoveDragCallback:function(_8d){
this.moveCallback=Boolean(_8d);
},setStopDragCallback:function(_8e){
this.stopCallback=Boolean(_8e);
},initDrag:function(_8f){
this.isDragging=false;
this.isInitialized=true;
var x,y;
if(window.event){
x=window.event.clientX+document.documentElement.scrollLeft+document.body.scrollLeft;
y=window.event.clientY+document.documentElement.scrollTop+document.body.scrollTop;
}else{
x=_8f.clientX+window.scrollX;
y=_8f.clientY+window.scrollY;
}
this.cursorX=x;
this.cursorY=y;
if(this.type=="Absolute"){
this.dragObjLeft=parseInt(this.dragObj.style.left,10);
this.dragObjTop=parseInt(this.dragObj.style.top,10);
}else{
if(this.type=="PanelSet"){
if(this.parentObj.container!==null){
this.dragObjLeft=x-parseInt(this.parentObj.container.offsetLeft,10)-parseInt(this.parentObj.staticHandle.style.left,10);
this.dragObjTop=y-parseInt(this.parentObj.container.offsetTop,10);
}
}
}
if(isNaN(this.dragObjLeft)){
this.dragObjLeft=0;
}
if(isNaN(this.dragObjTop)){
this.dragObjTop=0;
}
var _91=this;
if(this.moveDragFunc===null){
this.moveDragFunc=function(_92){
_91.moveDrag(_92);
};
this.stopDragFunc=function(_93){
_91.stopDrag(_93);
};
}
this.attachEvents();
if(!this.snapToMouse){
this.cancelEventPropagation(_8f);
}
},moveDrag:function(_94){
if(this.isInitialized){
var x,y;
if(!this.isDragging){
this.isDragging=true;
if(this.moveCallback){
if(typeof this.parentObj.moveDrag=="function"){
this.parentObj.moveDrag();
}
}
}
if(window.event){
x=window.event.clientX+document.documentElement.scrollLeft+document.body.scrollLeft;
y=window.event.clientY+document.documentElement.scrollTop+document.body.scrollTop;
}else{
x=_94.clientX+window.scrollX;
y=_94.clientY+window.scrollY;
}
if(this.type=="Absolute"){
if(this.snapToMouse){
this.dragObj.style.left=(x+this.mouseXOffest)+"px";
this.dragObj.style.top=(y+this.mouseYOffest)+"px";
}else{
this.dragObj.style.left=(this.dragObjLeft+x-this.cursorX)+"px";
this.dragObj.style.top=(this.dragObjTop+y-this.cursorY)+"px";
}
}else{
if(this.type=="PanelSet"){
if(this.parentObj.layout=="TwoColumn"){
var _96=Math.max(x-parseInt(this.parentObj.container.offsetLeft,10)-this.dragObjLeft,this.parentObj.column1MinWidth);
var _97=Math.min(_96,this.parentObj.panelWidth-this.parentObj.column2MinWidth-this.parentObj.leftPadding);
this.dragObj.style.left=_97+"px";
}else{
if(this.parentObj.layout=="TwoRow"){
this.dragObj.style.top=(this.dragObjTop+y-parseInt(this.parentObj.container.offsetTop,10))+"px";
}
}
}
}
this.cancelEventPropagation(_94);
}
},stopDrag:function(){
this.detachEvents();
if(this.stopCallback){
if(typeof this.parentObj.stopDrag=="function"){
this.parentObj.stopDrag();
}
}
},attachEvents:function(){
if(document.attachEvent){
document.attachEvent("onmousemove",this.moveDragFunc);
if(!this.snapToMouse){
document.attachEvent("onmouseup",this.stopDragFunc);
}
}else{
document.addEventListener("mousemove",this.moveDragFunc,true);
if(!this.snapToMouse){
document.addEventListener("mouseup",this.stopDragFunc,true);
}
}
},detachEvents:function(){
if(document.detachEvent){
document.detachEvent("onmousemove",this.moveDragFunc);
if(!this.snapToMouse){
document.detachEvent("onmouseup",this.stopDragFunc);
}
}else{
document.removeEventListener("mousemove",this.moveDragFunc,true);
if(!this.snapToMouse){
document.removeEventListener("mouseup",this.stopDragFunc,true);
}
}
},cancelEventPropagation:function(_98){
if(window.event){
window.event.cancelBubble=true;
window.event.returnValue=false;
}else{
_98.preventDefault();
}
}};
DR.Utils.customOnload=function(){
};
DR.Utils.addEvent=function(obj,evt,fn,_9c){
if(obj.addEventListener){
obj.addEventListener(evt,fn,Boolean(_9c));
return true;
}else{
if(obj.attachEvent){
var r=obj.attachEvent("on"+evt,fn);
return r;
}else{
return false;
}
}
};
DR.Utils.removeEvent=function(obj,evt,fn,_a1){
if(obj.removeEventListener){
obj.removeEventListener(evt,fn,Boolean(_a1));
return true;
}else{
if(obj.detachEvent){
var r=obj.detachEvent("on"+evt,fn);
return r;
}else{
return false;
}
}
};
DR.Utils.voidClick=function(){
if(DR.Utils.BrowserDetect.browser=="Explorer"&&DR.Utils.BrowserDetect.version<7){
return true;
}else{
return false;
}
};
DR.Utils.suppressKeypress=function(evt){
if(window.event){
window.event.cancelBubble=true;
return false;
}
if(evt&&evt.preventDefault){
evt.preventDefault();
}
};
DR.Utils.stopMouseClick=function(evt){
if(window.event){
event.cancelBubble=true;
return false;
}else{
if(evt&&evt.preventDefault){
evt.preventDefault();
evt.stopPropagation();
}
}
};
DR.Utils.FormUtils={getForm:function(frm){
return document.forms[frm];
},setAction:function(_a6,url){
if(_a6){
var _a8=(typeof _a6=="object")?_a6:document.forms[_a6];
_a8.setAttribute("action",url);
}
},submit:function(_a9){
if(_a9){
var _aa=(typeof _a9=="object")?_a9:document.forms[_a9];
_aa.submit();
}
},getField:function(_ab,frm){
var _ad=(typeof frm=="object")?frm:document.forms[frm];
return _ad.elements[_ab];
},getValue:function(fld,frm){
var _b0=null;
if(frm!==undefined&&typeof fld!="object"){
_b0=(typeof frm=="object")?frm:document.forms[frm];
}
if(!_b0){
return null;
}
var _b1=(typeof fld=="object")?fld:_b0.elements[fld];
if(!_b1){
return null;
}
var _b2=(!_b1.type&&!!_b1[0])?_b1[0].type:_b1.type;
if(!_b2){
return null;
}
var _b3=(_b2.substring(0,6)=="select")?"select":_b2;
var _b4=[];
var _b5=false;
if(typeof _b1.type=="undefined"){
_b5=true;
}
if(_b3=="select"){
if(_b5){
for(var i=0;i<_b1.length;i++){
_b4.push(DR.Utils.FormUtils.getSelectOptionValue(_b1[i]));
}
}else{
if(_b1.multiple){
for(var j=0;j<_b1.options.length;j++){
if(_b1.options[j].selected){
_b4.push(DR.Utils.FormUtils.getSelectOptionValue(_b1.options[j]));
}
}
}else{
try{
_b4.push(DR.Utils.FormUtils.getSelectOptionValue(_b1.options[_b1.selectedIndex]));
}
catch(err){
}
}
}
}else{
if((_b3=="checkbox")||(_b3=="radio")){
if(_b5){
for(var k=0;k<_b1.length;k++){
if(_b1[k].checked){
_b4.push(_b1[k].value);
}
}
}else{
if(_b1.checked){
_b4.push(_b1.value);
}
}
}else{
if(_b5){
for(var m=0;m<_b1.length;m++){
_b4.push(_b1[m].value);
}
}else{
_b4.push(_b1.value);
}
}
}
return _b4.join(",");
},getSelectOptionValue:function(o){
if(o){
var val="";
if(o.text!==""&&o.outerHTML&&o.outerHTML.toLowerCase().indexOf("value=")==-1){
val=o.text;
}else{
val=o.value;
}
return val;
}
},getMultiSelectTextValue:function(_bc){
if(_bc){
var a=[];
for(var i=0;i<_bc.options.length;i++){
if(_bc.options[i].selected){
a.push(_bc.options[i].text);
}
}
return a.join(", ");
}
},setSelectOptionValue:function(o,val){
var _c1=(o.value==val||o.text==val);
o.selected=_c1;
return _c1;
},checkAllowFocus:function(_c2){
var _c3=DR.Utils.getStyle(_c2,"display");
var _c4=DR.Utils.getStyle(_c2,"visibility");
if(_c4=="hidden"||_c3=="none"||_c2.disabled||_c2.readonly){
return false;
}else{
var p=_c2.parentNode;
var _c6=false;
while(p){
_c3=DR.Utils.getStyle(p,"display");
_c4=DR.Utils.getStyle(p,"visibility");
if(p.tagName=="BODY"||p.tagName=="HTML"){
break;
}
if((_c3=="none")||(_c4=="hidden")){
_c6=true;
break;
}
p=p.parentNode;
}
if(!_c6){
return true;
}else{
return false;
}
}
},setValue:function(fld,frm,_c9){
var _ca=(typeof frm=="object")?frm:document.forms[frm];
var _cb=(typeof fld=="object")?fld:_ca.elements[fld];
var i=0;
if(_cb){
var _cd=(_cb.type)?_cb.type:_cb[0].type;
switch(_cd){
case "text":
case "textarea":
case "password":
_cb.value=_c9;
break;
case "checkbox":
_cb.checked=(_c9)?true:false;
break;
case "radio":
for(i=0;i<_cb.length;i++){
if(_cb[i].value==_c9){
_cb[i].checked=true;
break;
}
}
break;
case "select-one":
case "select-multiple":
if(typeof _c9=="object"){
for(var j=0;j<_c9.length;j++){
for(i=0;i<_cb.options.length;i++){
if(_cb.options[i].value==_c9[j]){
_cb.options[i].selected=true;
}
}
}
}else{
for(i=0;i<_cb.options.length;i++){
if(_cb.options[i].value==_c9||_cb.options[i].text==_c9){
_cb.options[i].selected=true;
break;
}
}
}
break;
default:
break;
}
}
},getDisabled:function(_cf,_d0){
},setDisabled:function(_d1,_d2,_d3,_d4){
},getReadonly:function(_d5,_d6){
},setReadonly:function(_d7,_d8,_d9,_da){
},setOperationAndSubmit:function(_db,_dc){
var _dd=_db.id||_db.name;
var _de=_db.form.operation;
if(typeof _de=="object"){
_de.value=_dd;
}
DR.Utils.FormUtils.submit(_db.form);
if(_dc){
_dc.returnValue=false;
_dc.cancelBubble=true;
}
return false;
},submitActionForm:function(obj,evt){
var _e1=obj.id||obj.name;
var _e2=obj.form.action;
if(typeof _e2=="object"){
_e2.value=_e1;
}
if(obj.className.indexOf("cancel")>-1){
if(typeof obj.form.enableValidation=="function"){
obj.form.enableValidation(false);
}
}
obj.form.submit();
if(evt){
evt.returnValue=false;
evt.cancelBubble=true;
}
return false;
},getUTF8Bytes:function(val){
var _e4=val.length;
var _e5=encodeURI(val);
var _e6;
var _e7;
if(_e5.indexOf("%")!=-1){
_e6=_e5.split("%");
_e7=_e6.length-1;
if(_e7===0){
_e7++;
}
var tmp=_e5.length-(_e7*3);
_e7=_e7+tmp;
}else{
_e7=_e4;
}
if(DR.Utils.BrowserDetect.browser!="Explorer"){
var _e9=val.replace(/\n/g,"..").length;
var _ea=_e9-_e4;
_e7=_e7+_ea;
}
return {bytes:_e5,byteCount:_e7};
}};
(function($){
var _ec="yyyy-mm-dd",DATE_FORMAT_PATTERN,PARSED_DATE_SEGMENTS,DAY_POS,MONTH_POS,YEAR_POS,REG_EX_PAT;
var _ed=function(_ee,_ef){
for(var i=0;i<_ef.length;i++){
if(_ef[i].indexOf(_ee)!=-1){
return i;
}
}
return -1;
};
var _f1=function(fmt){
var _f3=/(([y]{2,4}|[m]{1,2}|[d]{1,2})|([-\/ .]+?))/gi;
return fmt.toLowerCase().match(_f3);
};
var _f4=function(_f5){
var _f6="^";
for(var i=0;i<_f5.length;i++){
if(/[mdy]/i.test(_f5[i])){
if(typeof _f5[i]!="undefined"){
var _f8=_f5[i].length;
var _f9=_f8;
if(_f8==1){
_f9=2;
}
_f6+="(\\d{"+_f8+","+_f9+"})";
}
}else{
_f6+="([\\"+_f5[i]+"]{1})";
}
}
return (_f6+"$");
};
var _fa=function(_fb){
var _fc=(_fb)?_f1(_fb):PARSED_DATE_SEGMENTS;
var _fd=(_fb)?_ed("d",_fc):DAY_POS;
var _fe=(_fb)?_ed("m",_fc):MONTH_POS;
var _ff=(_fb)?_ed("y",_fc):YEAR_POS;
var _100=(_fb)?_f4(_fc):REG_EX_PAT;
var _101={format:_fb,yearPos:_ff,monthPos:_fe,datePos:_fd,regExPat:_100,segments:_fc};
return _101;
};
var _102=function(_103,_104){
var _105=_fa(_104);
var _106=new RegExp(_105.regExPat).exec(_103);
var _107={};
var _108=false;
var date,month,year;
if(_106){
_106=_106.slice(1);
date=_106[_105.datePos];
month=Number(_106[_105.monthPos])-1;
year=_106[_105.yearPos];
_107=new Date(((year.length==2)?((year<70)?Number("20"+year):Number("19"+year)):year),month,date);
var _10a=_107.getDate();
var _10b=_107.getMonth();
var _10c=(year.length==2)?String(_107.getFullYear()).slice(2):_107.getFullYear();
if(_10a==date&&_10b==month&&_10c==year){
_108=true;
}
}
return (_108)?_107:null;
};
$.dr.date=function(_10d,fmt){
var _10f=(fmt==null||fmt==""||fmt=="undefined")?DATE_FORMAT_PATTERN:fmt;
var date=null;
if(_10d instanceof Date){
if(_10d.isValid()){
date=_10d;
}
}else{
date=_102(_10d,_10f);
}
if(date==null){
return (new Date("invalid date"));
}else{
date.format=_10f;
return date;
}
};
$.dr.date.prototype=new Date();
Date.prototype.isValid=function(){
var _111=this;
return !(_111===null||_111===undefined||(typeof _111=="object"&&_111=="Invalid Date")||(typeof _111=="object"&&_111=="NaN"));
};
Date.prototype.getFormat=function(){
return this.format;
};
Date.prototype.toFormattedString=function(_112){
var year=this.getFullYear();
var day=this.getDate();
var _115=this.getMonth()+1;
var _116=(_112)?_112:((this.format)?this.format:_ec);
var _117=_fa(_116).segments;
var _118="";
for(var i=0;i<_117.length;i++){
var s=_117[i];
var d=s;
switch(s.toLowerCase().charAt(0)){
case "m":
if(s.length==2){
_115=(_115<10)?"0"+_115:_115;
}
d=_115;
break;
case "d":
if(s.length==2){
day=(day<10)?"0"+day:day;
}
d=day;
break;
case "y":
if(s.length==2){
year=(year+"").substring(2);
}
d=year;
break;
}
_118+=d;
}
return _118;
};
$.dr.date.setDefaultFormat=function(fmt){
DATE_FORMAT_PATTERN=fmt;
PARSED_DATE_SEGMENTS=_f1(fmt);
MONTH_POS=_ed("m",PARSED_DATE_SEGMENTS);
YEAR_POS=_ed("y",PARSED_DATE_SEGMENTS);
Day_POS=_ed("d",PARSED_DATE_SEGMENTS);
REG_EX_PAT=_f4(PARSED_DATE_SEGMENTS);
}(_ec);
$.dr.date.getDefaultFormat=function(){
return DATE_FORMAT_PATTERN;
};
$.dr.date.getDateFromTime=function(time){
var arr=time.split(":");
var hh=Number(arr[0]);
var arr2=arr[1].split(" ");
var mm=arr2[0];
if(arr2.length==2){
var ampm=arr2[1].toLowerCase();
if(ampm=="pm"&&hh!=12){
hh=hh+12;
}else{
if(hh==12&&ampm=="am"){
hh=hh-12;
}
}
}
var date=new Date();
var r=new Date(date.getFullYear(),date.getMonth(),date.getDate(),hh,mm).getTime();
return r;
};
$.dr.date.getISODate=function(year,_126,day){
if(year.length==2){
year=parseInt(year,10);
year=(year<70)?Number("20"+year):Number("19"+year);
}
day=(day<10)?"0"+day:day;
_126=(_126<10)?"0"+_126:_126;
return new $.dr.date(year+"-"+_126+"-"+day,"yyyy-mm-dd");
};
$.dr.date.isLeapYear=function(year){
year=parseInt(year,10);
if(((year%4===0)&&(year%100!==0))||(year%400===0)){
return true;
}else{
return false;
}
};
var _129=function(){
if(typeof $.dr.form.addDataTypeValidator=="function"){
$.dr.form.addDataTypeValidator({date:["The value for {LABEL} is not a valid date format. Valid format is {FORMAT}.","",function(val,_12b){
if(val===null||val===undefined){
return false;
}
var date=new $.dr.date(val,_12b);
return date.isValid();
}],time12hr:["The value for {LABEL} is not a valid time. Valid format is {EXAMPLE}.","hh:mm",function(val){
var re=new RegExp("^([1-9]|[0][1-9]|[1][0,1,2])(:([0-5][0-9])){1,2}?( ([aApP][mM])?)?$");
return re.test(val);
}],time24hr:["The value for {LABEL} is not a valid time. Valid format is {EXAMPLE}.","HH:MM",function(val){
return /^(24:00)|(([0-1][0-9]|2[0-3])[:]([0-5][0-9]))$/.test(val);
}],year:["The value for {LABEL} is not a valid year. Valid format is {EXAMPLE}.","yyyy",function(val,_131){
if(val===null||val===undefined){
return false;
}
if(!_131){
_131="yyyy";
}
if(_131.toLowerCase()=="yy"&&val.length==2&&!isNaN(val)){
return true;
}else{
if(_131.toLowerCase()=="yyyy"&&val.length==4&&!isNaN(val)){
return true;
}
}
return false;
}]});
}
};
$(document).bind("beforeInitForms",_129);
})(jQuery);
DR.Utils.PageSizer=function(){
this.pageWidth=0;
this.pageHeight=0;
this.windowWidth=0;
this.windowHeight=0;
};
DR.Utils.PageSizer.prototype={initModalScroller:function(){
this.attachModalOnresize();
this.refreshModalScroller();
},attachModalOnresize:function(){
var self=this;
var _133=window.onresize;
var _134=function(){
self.refreshModalScroller();
};
window.onresize=function(){
_134();
if(typeof (_133)=="function"){
_133();
}
};
function cleanupEvents(){
window.detachEvent("onresize",_134);
}
if(DR.Utils.BrowserDetect.browser=="Explorer"){
if(window.attachEvent){
window.attachEvent("onunload",cleanupEvents);
}
}
},refresh:function(){
var _135,yScroll,pageHeight,pageWidth;
var obj={};
if(window.innerHeight&&window.scrollMaxY){
_135=document.body.scrollWidth;
yScroll=window.innerHeight+window.scrollMaxY;
}else{
if(document.body.scrollHeight>document.body.offsetHeight){
_135=document.body.scrollWidth;
yScroll=document.body.scrollHeight;
}else{
_135=document.body.offsetWidth;
yScroll=document.body.offsetHeight;
}
}
var _137,windowHeight;
if(self.innerHeight){
_137=self.innerWidth;
windowHeight=self.innerHeight;
}else{
if(document.documentElement&&document.documentElement.clientHeight){
_137=document.documentElement.clientWidth;
windowHeight=document.documentElement.clientHeight;
}else{
if(document.body){
_137=document.body.clientWidth;
windowHeight=document.body.clientHeight;
}
}
}
if(yScroll<windowHeight){
pageHeight=windowHeight;
}else{
pageHeight=yScroll;
}
if(_135<_137){
pageWidth=_137;
}else{
pageWidth=_135;
}
if(this.doc===undefined){
this.doc={};
}
this.pageWidth=pageWidth;
this.pageHeight=pageHeight;
this.windowWidth=_137;
this.windowHeight=windowHeight;
},refreshModalScroller:function(){
var d=document.getElementById("modalScroller");
if(d){
this.refresh();
var _139=this.windowHeight;
var _13a=this.windowWidth;
var _13b=d.offsetTop;
var _13c=$(".pageButtons");
var _13d=(_13c.length>0)?_13c[0].offsetHeight:0;
_13d=_13d+32;
var _13e=_139;
if(_13a<790){
}
var _13f=_13e-d.offsetTop-_13d;
if(_13f>0){
d.style.height=_13f+"px";
}
}
}};
(function($){
var _141={url:"",width:740,height:500,target:"",centered:true,type:"normal"};
$.dr.popup=function(_142){
_142=$.extend({},_141,_142);
if(_142.url==""||_142.url==null){
$.dr.utils.logError("Must supply a url");
return;
}
var s="";
switch(_142.type){
case "console":
s="resizable,scrollbars,height="+_142.height+",width="+_142.width;
break;
case "fixed":
s="status,scrollbars,height="+_142.height+",width="+_142.width;
break;
case "normal":
s="toolbar,scrollbars,resizable,location,height="+_142.height+",width="+_142.width;
break;
case "full":
s="toolbar,menubar,scrollbars,resizable,location,height="+_142.height+",width="+_142.width;
break;
default:
if(_142.type){
s=_142.type;
}
break;
}
if(_142.centered){
if(window.screen){
var l=(screen.width-parseInt(_142.width,10))/2;
var t=(screen.height-parseInt(_142.height))/2;
s+=",left="+l+",top="+t;
}
}
tg=_142.target;
return window.open(_142.url,tg,s);
};
})(jQuery);
DR.Utils.Position=function(_146){
this.obj=(typeof _146=="object")?_146:document.getElementById(_146);
this.x=this.getX();
this.y=this.getY();
this.width=this.getWidth();
this.height=this.getHeight();
this.top=this.getTop();
this.right=this.getRight();
this.left=this.getLeft();
this.bottom=this.getBottom();
};
DR.Utils.Position.ON_TOP=0;
DR.Utils.Position.ON_MIDDLE=1;
DR.Utils.Position.ON_BOTTOM=2;
DR.Utils.Position.ON_LEFT=4;
DR.Utils.Position.ON_CENTER=8;
DR.Utils.Position.ON_RIGHT=16;
DR.Utils.Position.DRAW_LEFT=32;
DR.Utils.Position.DRAW_CENTERED=64;
DR.Utils.Position.DRAW_RIGHT=128;
DR.Utils.Position.DRAW_UP=256;
DR.Utils.Position.DRAW_DOWN=1024;
DR.Utils.Position.prototype={setPosition:function(top,left){
this.obj.style.top=top;
this.obj.style.left=left;
},setRelativePosition:function(_149,_14a,_14b,_14c,_14d,_14e,_14f,_150){
this.setRelativeXPosition(_149,_14a,_14b,_14e,_150);
this.setRelativeYPosition(_149,_14c,_14d,_14f,_150);
},setRelativeXPosition:function(_151,_152,_153,_154,_155){
var _156=new DR.Utils.Position(_151);
var _157=_156.left;
var _158=DR.Utils.BrowserDetect.getAvailableContentWidth();
if(_152==DR.Utils.Position.ON_CENTER){
_157=_156.left+(Math.floor(_156.width/2));
}else{
if(_152==DR.Utils.Position.ON_RIGHT){
_157=_156.right;
}
}
if(_153==DR.Utils.Position.DRAW_LEFT){
if(_155||(_157-this.width-_154)>=0){
_157=_157-this.width-_154;
}else{
if((_157+this.width+_154)<_158){
_157=_157+this.width+_154;
}else{
_157=0;
}
}
}else{
if(_153==DR.Utils.Position.DRAW_RIGHT){
if(_155||(_157+this.width+_154)<_158){
_157=_157+_154;
}else{
if((_157-this.width-_154)>0){
_157=_157-this.width+_156.width;
}else{
_157=_158;
}
}
}else{
if(_153==DR.Utils.Position.DRAW_CENTERED){
if(_155||(_157-Math.floor((this.width-_154)/2))>0){
_157=_157-Math.floor((this.width-_154)/2);
}else{
_157=0;
}
}
}
}
this.setX(_157);
},setRelativeYPosition:function(_159,_15a,_15b,_15c,_15d){
var _15e=new DR.Utils.Position(_159);
var _15f=_15e.top;
var _160=DR.Utils.BrowserDetect.getAvailableContentHeight();
if(_15a==DR.Utils.Position.ON_MIDDLE){
_15f=_15e.top+(Math.floor(_15e.height/2));
}else{
if(_15a==DR.Utils.Position.ON_BOTTOM){
_15f=_15e.bottom;
}
}
if(_15b==DR.Utils.Position.DRAW_UP){
if(_15d||(_15f-this.height-_15c)>0){
_15f=_15f-this.height-_15c;
}else{
if((_15f+_15e.height+this.height+_15c)<_160){
_15f=_15f+_15e.height+_15c;
}else{
_15f=0;
}
}
}else{
if(_15b==DR.Utils.Position.DRAW_DOWN){
var _161=_15f+this.height+_15c;
if(_15d||(_161)<_160){
_15f=_15f+_15e.height+_15c;
}else{
if((_15f-this.height-_15c)>0){
_15f=_15f-this.height-_15c;
}else{
_15f=_160;
}
}
}else{
if(_15b==DR.Utils.Position.DRAW_CENTERED){
if(_15d||(_15f-Math.floor((this.height-_15c)/2))>0){
_15f=_15f-Math.floor((this.height-_15c)/2);
}else{
_15f=0;
}
}
}
}
this.setY(_15f);
},setX:function(left){
this.obj.style.left=left+"px";
},setY:function(top){
this.obj.style.top=top+"px";
},getX:function(){
var curX=0;
var _165=this.obj;
if(_165.offsetParent){
while(_165.offsetParent){
curX+=_165.offsetLeft;
if(_165.clientLeft&&(_165.tagName=="TD")||(_165.tagName=="TH")){
curX+=_165.clientLeft;
}
_165=_165.offsetParent;
}
}
if(document.compatMode=="CSS1Compat"&&!window.getComputedStyle){
curX+=(isNaN(parseInt(document.body.currentStyle.marginLeft,10)))?0:parseInt(document.body.currentStyle.marginLeft,10);
}
return curX;
},getY:function(){
var curY=0;
var _167=this.obj;
if(_167.offsetParent){
while(_167.offsetParent){
curY+=_167.offsetTop;
if(_167.clientTop&&(_167.tagName=="TD")||(_167.tagName=="TH")){
curY+=_167.clientTop;
}
_167=_167.offsetParent;
}
}
if(document.compatMode=="CSS1Compat"&&!window.getComputedStyle){
curY+=(isNaN(parseInt(document.body.currentStyle.marginTop,10)))?0:parseInt(document.body.currentStyle.marginTop,10);
}
return curY;
},getWidth:function(){
return this.obj.offsetWidth;
},getHeight:function(){
return this.obj.offsetHeight;
},getTop:function(){
return this.y;
},getRight:function(){
return this.x+this.width;
},getBottom:function(){
return this.y+this.height;
},getLeft:function(){
return this.x;
}};
DR.Utils.Position.snapTo=function(_168,_169,_16a,_16b,_16c,_16d,_16e,_16f,_170){
sourceObj=(typeof _168=="object")?_168:document.getElementById(_168);
targetObj=(typeof _169=="object")?_169:document.getElementById(_169);
_16a=(_16a!==undefined)?_16a:0;
_16b=(_16b!==undefined)?_16b:0;
_16c=(_16c!==undefined)?_16c:"Right";
_16d=(_16d!==undefined)?_16d:"Top";
_16e=(_16e!==undefined)?_16e:"Right";
_16f=(_16f!==undefined)?_16f:"Down";
_170=(_170==false)?false:true;
var _171=sourceY=0,_width,_height;
var obj=sourceObj;
while(obj.offsetParent){
_171+=obj.offsetLeft;
if(obj.scrollLeft){
_171-=obj.scrollLeft;
}
sourceY+=obj.offsetTop;
if(obj.scrollTop){
sourceY-=obj.scrollTop;
}
obj=obj.offsetParent;
}
obj=sourceObj;
while(obj.offsetParent){
if(obj.scrollLeft){
_171-=obj.scrollLeft;
}
if(obj.scrollTop){
sourceY-=obj.scrollTop;
}
if(DR.Utils.BrowserDetect.browser=="Explorer"){
if((obj.tagName=="TD")||(obj.tagName=="TH")){
if(obj.clientTop){
sourceY+=obj.clientTop;
}
if(obj.clientLeft){
_171+=obj.clientLeft;
}
}
if(DR.Utils.hasCSSClass(obj,"searchBody")){
_171-=11;
}
}
obj=obj.parentNode;
}
sourceWidth=sourceObj.offsetWidth;
sourceHeight=sourceObj.offsetHeight;
targetX=_171;
targetY=sourceY;
if(_16c=="Right"){
targetX=_171+sourceWidth;
}
if(_16d=="Bottom"){
targetY=sourceY+sourceHeight;
}
if(_170){
var _173,scrollY;
if(window.scrollX){
_173=window.scrollX;
scrollY=window.scrollY;
}else{
_173=document.documentElement.scrollLeft+document.body.scrollLeft;
scrollY=document.documentElement.scrollTop+document.body.scrollTop;
}
targetWidth=targetObj.offsetWidth;
targetHeight=targetObj.offsetHeight;
var _174=DR.Utils.BrowserDetect.getAvailableContentWidth();
var _175=DR.Utils.BrowserDetect.getAvailableContentHeight();
var _176=_171+targetWidth+_16a;
var _177=_171-targetWidth-_16a;
var _178=false;
var _179=false;
if(_176<=(_174+_173-sourceWidth)){
_178=true;
}
if(_177>_173){
_179=true;
}
if((_16e=="Right"&&_178)||(_16e=="Left"&&!_179&&_178)){
targetX+=_16a;
}else{
if(_179){
targetX=_171-targetWidth-_16a;
}
}
var _17a=sourceY+targetHeight+_16b;
var _17b=sourceY-targetHeight-_16b;
var _17c=false;
var _17d=false;
if(_17a<=(_175+scrollY-sourceHeight)){
_17c=true;
}
if(_17b>scrollY){
_17d=true;
}
if((_16f=="Down"&&_17c)||(_16f=="Up"&&!_17d&&_17c)){
targetY+=_16b;
}else{
if(_17d){
targetY=sourceY-targetHeight-_16b;
}
}
}else{
targetX+=_16a;
targetY+=_16b;
}
targetObj.style.left=targetX+"px";
targetObj.style.top=targetY+"px";
};
DR.Utils.Querystring=function(qs){
this.params={};
if(qs===null){
qs=location.search.substring(1,location.search.length);
}else{
qs=(qs.indexOf("?")!=-1)?qs.substring(1,qs.length):qs;
}
if(qs.length===0){
return;
}
qs=qs.replace(/\+/g," ");
var args=qs.split("&");
var val;
for(var i=0;i<args.length;i++){
var _182;
alert(args[i]);
var pair=args[i].split("=");
var _184=unescape(pair[0]);
if(pair.length==2){
val=unescape(pair[1]);
}else{
val=_184;
}
this.params[_184]=val;
}
};
DR.Utils.Querystring.prototype.get=function(_185){
var val=this.params[_185];
return val;
};
String.prototype.stripSpaces=function(){
return this.replace(/ /g,"");
};
String.prototype.stripLineBreaksAndTabs=function(){
var s=this.replace(/\n/g,"");
return s.replace(/\t/g,"");
};
String.prototype.trim=function(){
return this.replace(/^\s+|\s+$/,"");
};
String.prototype.ltrim=function(){
return this.replace(/^(\\s*)(\\b[\\w\\W]*)$/,"");
};
String.prototype.rtrim=function(){
return this.replace(/^([\\w\\W]*)(\\b\\s*)$/,"");
};
String.prototype.replaceBreaks=function(){
return this.replace(/\{0\}/g,"<br/><br/>");
};
String.prototype.trimLastLetter=function(){
var _188=this.length;
var _189=encodeURI(this.substr(_188-1,_188));
var _18a=1;
if(DR.Utils.BrowserDetect.browser=="Explorer"&&_189=="%0A"){
_18a=2;
}
return this.substr(0,_188-_18a);
};
String.prototype.stripDoubleQuotes=function(){
return this.replace(/"/g,"");
};
String.prototype.isBlank=function(){
return Boolean(/^\s*$/.test(this));
};
String.prototype.makeUT8CharsFitLength=function(_18b,_18c){
if(_18b===0||_18b==_18c){
return this;
}
var _18d=false;
var _18e=this.length;
var _18f=_18e/_18b;
var _190=Math.round(_18c*_18f,0);
var _191;
var _192="";
var _193=false;
var _194=_190;
var i=0;
while(!_18d&&i<100){
var _196=this.substr(0,_194);
var _197=DR.Utils.FormUtils.getUTF8Bytes(_196).byteCount;
if(_197==_18c){
_18d=true;
_191=_196;
}else{
if(_197<_18c&&_193){
_18d=true;
_191=_196;
}else{
if(_197<_18c){
if(_192=="negative"){
_193=true;
}
_194++;
_192="positive";
}else{
if(_197>_18c){
if(_192=="positive"){
_193=true;
}
_194--;
_192="negative";
}
}
}
}
}
return _191;
};
DR.Utils.Toggle=function(){
};
DR.Utils.Toggle.disabledFromCheckbox=function(_198,_199){
var _19a=(typeof _198=="object")?_198:document.getElementById(_198);
if(typeof _199=="string"){
_199=_199.stripSpaces().split(",");
for(var i=0;i<_199.length;i++){
DR.Utils.Toggle.setDisabled(_199[i],!DR.Utils.Toggle.isChecked(_198));
}
}
};
DR.Utils.Toggle.disabledFromRadioButton=function(_19c,_19d){
var _19e=(typeof _19c=="object")?_19c:document.getElementById(_19c);
var _19f=(_19e.value=="true"||_19e.value==true)?false:true;
if(typeof _19d=="string"){
_19d=_19d.stripSpaces().split(",");
for(var i=0;i<_19d.length;i++){
DR.Utils.Toggle.setDisabled(_19d[i],_19f);
}
}
};
DR.Utils.Toggle.isChecked=function(_1a1){
var _1a2=(typeof _1a1=="object")?_1a1:document.getElementById(_1a1);
if(_1a2){
return (_1a2.checked)?true:false;
}else{
return false;
}
};
DR.Utils.Toggle.setDisabled=function(_1a3,_1a4){
var _1a5=(typeof _1a3=="object")?_1a3:document.getElementById(_1a3);
if(_1a5){
_1a5.disabled=(_1a4=="true"||_1a4==true)?true:false;
}
};
DR.Utils.Toggle.setVisibility=function(_1a6,_1a7){
var _1a8=(typeof _1a6=="object")?_1a6:document.getElementById(_1a6);
if(_1a8){
if(_1a7){
$(_1a8).fadeIn();
}else{
$(_1a8).hide();
}
}
};
DR.Utils.Toggle.enableTab=function(_1a9){
var _1aa=(typeof _1a9=="object")?_1a9:document.getElementById(_1a9);
_1aa=_1aa.parentNode;
var tabs=(_1aa.parentNode.parentNode).getElementsByTagName("LI");
for(var i=0;i<tabs.length;i++){
DR.Utils.removeCSSClass(tabs[i],"selected");
DR.Utils.Toggle.setVisibility("tabContent_"+tabs[i].id,false);
}
DR.Utils.addCSSClass(_1aa,"selected");
DR.Utils.Toggle.setVisibility("tabContent_"+_1aa.id,true);
};
DR.Utils.Toggle.visibilityFromLink=function(_1ad,_1ae,_1af){
var _1b0=(typeof _1ad=="object")?_1ad:document.getElementById(_1ad);
var _1b1=(_1b0.className=="collapsedImage")?true:false;
var _1b2=(_1b0.className=="collapsedImage")?"expandedImage":"collapsedImage";
if(typeof _1ae=="string"){
_1ae=_1ae.stripSpaces().split(",");
for(var i=0;i<_1ae.length;i++){
DR.Utils.Toggle.setVisibility(_1ae[i],_1b1);
}
}
if(typeof _1af=="string"){
_1af=_1af.stripSpaces().split(",");
for(var j=0;j<_1af.length;j++){
DR.Utils.Toggle.setVisibility(_1af[j],!_1b1);
}
}
DR.Utils.replaceCSSClass(_1b0,_1b0.className,_1b2);
};
DR.Utils.Toggle.visibilityFromCheckbox=function(_1b5,_1b6,_1b7){
var _1b8=(typeof _1b5=="object")?_1b5:document.getElementById(_1b5);
var _1b9=(_1b8.checked)?true:false;
if(typeof _1b6=="string"){
_1b6=_1b6.stripSpaces().split(",");
for(var i=0;i<_1b6.length;i++){
DR.Utils.Toggle.setVisibility(_1b6[i],_1b9);
}
}
if(typeof _1b7=="string"){
_1b7=_1b7.stripSpaces().split(",");
for(var j=0;j<_1b7.length;j++){
DR.Utils.Toggle.setVisibility(_1b7[j],!_1b9);
}
}
};
DR.Utils.Toggle.visibilityFromRadioButton=function(_1bc,_1bd,_1be){
var _1bf=(typeof _1bc=="object")?_1bc:document.getElementById(_1bc);
if(typeof _1bd=="string"){
_1bd=_1bd.stripSpaces().split(",");
for(var i=0;i<_1bd.length;i++){
DR.Utils.Toggle.setVisibility(_1bd[i],true);
}
}
if(typeof _1be=="string"){
_1be=_1be.stripSpaces().split(",");
for(var j=0;j<_1be.length;j++){
DR.Utils.Toggle.setVisibility(_1be[j],false);
}
}
};
DR.Utils.Toggle.childTable=function(_1c2,_1c3){
var _1c4=document.getElementById(_1c3);
var _1c5=(_1c4.style.display!="none");
if(_1c5){
_1c4.style.display="none";
_1c2.className="first collapsed";
}else{
_1c4.style.display="";
_1c2.className="first expanded";
}
};
DR.Utils.Toggle.childTableFromCheckbox=function(_1c6,_1c7,_1c8){
var _1c9=document.getElementById(_1c8);
var _1ca=(_1c9.style.display!="none");
if(!_1c6.checked){
_1c9.style.display="none";
_1c7.className="first collapsed";
}else{
_1c9.style.display="";
_1c7.className="first expanded";
}
};
DR.Widgets.AjaxPanel=function(_1cb,_1cc){
this.settingName="";
this.newSettingName="";
this.panelId=_1cb;
this.content=getElem(_1cb);
this.currentForm=null;
this.loaded=false;
this.loading=false;
this.saving=false;
this.url="";
this.queryStringData="";
this.errors=[];
this.showSuccessMessage=true;
this.saveCallback=null;
this.loadCallback=null;
this.checkChangeCallback=null;
this.isModal=(_1cc)?true:false;
};
DR.Widgets.AjaxPanel.prototype={get:function(url,_1ce){
this.markLoading();
this.url=url;
this.queryStringData=(_1ce)?_1ce:"";
var _1cf=this;
jQuery.ajax({url:this.url,data:this.queryStringData+"&ajaxTime="+new Date().getTime(),type:"GET",dataType:"html",success:function(_1d0){
if($.browser.msie){
_1d0=_1d0.replace("<script","<br style=\"display:none\"/> <script");
}
_1cf.content.innerHTML=_1d0;
_1cf.loaded=true;
_1cf.loading=false;
_1cf.prepare();
_1cf.runScripts();
if(typeof _1cf.loadCallback=="function"){
_1cf.loadCallback(_1d0);
}
},error:function(xhr){
if(xhr.status=="500"){
DR.Utils.replaceHtml(_1cf.content,xhr.responseText);
_1cf.loaded=true;
_1cf.loading=false;
_1cf.saving=false;
_1cf.prepare();
_1cf.runScripts();
}else{
if(xhr.status=="403"){
window.location=DR.LOGIN_URL;
}
}
}});
if(typeof _1cf.beforeLoadCallback=="function"){
_1cf.beforeLoadCallback();
}
this.loading=true;
},refresh:function(){
this.get(this.url,this.queryStringData);
},prepare:function(){
if(this.currentForm!==null){
$(this.currentForm).dr.form.destroy();
}
$.dr.triggerUnobtrusiveEvents(this.content);
var _1d2=jQuery("form",this.content);
if(_1d2.length==0&&this.currentForm!==null){
_1d2.dr.form.destroy();
this.currentForm=null;
}else{
for(var i=0;i<_1d2.length;i++){
var _1d4=_1d2[i];
this.currentForm=_1d4;
this.addHijackForm();
}
}
},addHijackForm:function(){
var _1d5=this;
var _1d6=this.currentForm.onsubmit;
var _1d7;
if(typeof _1d6!="function"){
_1d7=function(_1d8){
if(_1d8!==false){
_1d5.hijackForm();
return false;
}else{
return true;
}
};
}else{
_1d7=function(_1d9){
var test=_1d6();
if(test){
if(_1d9!==false){
_1d5.hijackForm();
return false;
}else{
return true;
}
}
return false;
};
}
this.currentForm.onsubmit=_1d7;
},runScripts:function(){
var div=this.content;
var _1dc=$("script",div);
this.errors=[];
var _1dd=[];
var _1de=(navigator.userAgent.indexOf("Safari")>-1&&navigator.userAgent.indexOf("Chrome")==-1)?true:false;
for(var i=0;i<_1dc.length;i++){
var _1e0=_1dc[i];
var h=_1e0.innerHTML;
if(h.indexOf("document.write")==-1){
if(_1e0.src){
var head=document.getElementsByTagName("head")[0];
var _1e3=document.createElement("script");
_1e3.setAttribute("type","text/javascript");
_1e3.setAttribute("src",_1e0.src);
head.appendChild(_1e3);
}else{
if(h){
if(_1de){
_1dd.push(h);
}else{
try{
if(window.execScript){
window.execScript(h);
}else{
eval.call(window,h);
}
}
catch(e){
this.errors[this.errors.length]=e;
}
this.displayScriptErrors();
}
}
}
}
}
if(_1de){
var s=[];
for(var i=0;i<_1dd.length;i++){
s.push("try{"+_1dd[i]+"}catch(e){"+this.panelId+".errors.push(e)};");
}
var f=s.join("")+this.panelId+".displayScriptErrors()";
window.setTimeout(f,0);
}
},displayScriptErrors:function(){
if(this.errors.length>0&&DR.IS_INTERNAL_USER){
DR.Utils.alert("There were javascript errors when loading "+this.settingName+":<br/><br/>"+this.errors.join("<br/><br/>"));
}
},hijackForm:function(_1e6){
var url=this.url+"?"+this.queryStringData+"&ajaxTime="+new Date().getTime();
var _1e8=jQuery(this.currentForm).serialize();
var _1e9=this;
var _1ea=function(o){
_1e9.hijackFailureCallback(o);
};
var _1ec;
this.loaded=false;
_1ec=function(data,o){
_1e9.hijackSaveCallback(data,o);
if(typeof _1e6=="function"){
_1e6();
}
};
$.ajax({type:"POST",url:url,success:_1ec,error:_1ea,data:_1e8});
$(this.currentForm).dr.form.reIndex();
this.saving=true;
this.markSaving();
},hijackSaveCallback:function(data,o){
if(data!==undefined){
this.saving=false;
this.loaded=true;
if(typeof $.dr.processingDialog=="object"){
$.dr.processingDialog.hide();
}
if(this.showSuccessMessage){
var msg=this.SAVE_SUCCESSFUL.replace("{0}",this.settingName);
DR.Utils.success(msg);
}
if(typeof this.checkChangeCallback=="function"){
this.checkChangeCallback();
}else{
var _1f2=data;
if($.browser.msie){
_1f2=_1f2.replace("<script","<br style=\"display:none\"/> <script");
}
this.content.innerHTML=_1f2;
this.prepare();
this.runScripts();
if(typeof this.saveCallback=="function"){
this.saveCallback();
}
}
}
},hijackFailureCallback:function(o){
if(o.status=="403"){
window.location=DR.LOGIN_URL;
}else{
if(o.status=="500"){
this.content.innerHTML=o.responseText;
}
}
},markLoading:function(){
if(!this.saving){
var _1f4=(!this.loaded)?0:250;
this.loaded=false;
var _1f5=this;
var func=function(){
_1f5.markLoadingST();
};
window.setTimeout(func,_1f4);
}
},markLoadingST:function(){
if(!this.loaded){
var msg=AJAX_LOADING.replace("..."," "+this.settingName+"...");
var h="<div class=\"loadingTabContent\" ><div><span>"+msg+"</span><div></div>";
this.content.innerHTML=h;
}
},markSaving:function(){
if(!this.loading){
var _1f9=150;
this.saving=true;
var _1fa=this;
var func=function(){
_1fa.markSavingST();
};
window.setTimeout(func,_1f9);
}
},markSavingST:function(){
if(!this.loaded){
if(this.isModal){
var msg=this.SAVING_CHANGES.replace("{0}"," "+this.settingName+"...");
var h="<div class=\"loadingTabContent\" ><div><span>"+msg+"</span><div></div>";
this.content.innerHTML=h;
}else{
if(typeof $.dr.processingDialog=="object"){
$.dr.processingDialog.show();
}
}
}
},checkChanges:function(_1fe){
if(this.currentForm==null){
_1fe();
return false;
}
var _1ff=this.checkFormChanges();
if(_1ff){
if(this.currentForm!==undefined){
var _200=this.currentForm.onsubmit;
if(typeof _200=="function"){
var _201=_200(false);
if(_201===false){
return false;
}
}
}
this.checkChangeCallback=_1fe;
var _202=this;
var _203=function(_204){
_202.checkChangesConfirmCallback(_204);
};
var q;
if(this.settingName==this.newSettingName){
q=this.UNSAVED_CHANGES_CONFIRM_QUESTION;
q=q.replace("{0}",this.settingName);
}else{
q=this.UNSAVED_CHANGES_CONFIRM_QUESTION_LOAD;
q=q.replace("{0}",this.settingName);
q=q.replace("{1}",this.newSettingName);
}
DR.Utils.warning(q,_203,this.UNSAVED_CHANGES_CONFIRM_TITLE);
return true;
}else{
_1fe();
return false;
}
},checkFormChanges:function(){
var _206=this.currentForm;
if(!_206){
return false;
}
if(_206._behavior.checkChanges){
if(_206.checkForChanges()){
return true;
}
}
return false;
},checkChangesConfirmCallback:function(_207){
var _208=false;
if(_207){
if(this.currentForm.validateForm()){
this.hijackForm();
return;
}else{
_208=true;
}
}
if(!_208){
this.checkChangeCallback();
}
}};
DR.Widgets.AjaxPanel.prototype.SAVING_CHANGES="Saving changes to {0}";
DR.Widgets.AjaxPanel.prototype.SAVE_SUCCESSFUL="Changes to {0} were saved successfully.";
DR.Widgets.AjaxPanel.prototype.UNSAVED_CHANGES_CONFIRM_TITLE="Unsaved Changes";
DR.Widgets.AjaxPanel.prototype.UNSAVED_CHANGES_CONFIRM_QUESTION="Do you want to save your changes to {0} before performing the requested action?";
DR.Widgets.AjaxPanel.prototype.UNSAVED_CHANGES_CONFIRM_QUESTION_LOAD="Do you want to save your changes to {0} before loading {1}?";
(function($){
var _20a={comboBox:false,minChars:1,delay:400,matchCase:false,matchSubset:true,matchContains:false,cacheLength:10,max:10000,mustMatch:false,extraParams:{},selectFirst:false,formatItem:function(row){
return row[0];
},formatMatch:null,autoFill:false,width:0,multiple:false,multipleSeparator:", ",highlight:function(_20c,term){
return _20c.replace(new RegExp("(?![^&;]+;)(?!<[^<>]*)("+term.replace(/([\^\$\(\)\[\]\{\}\*\.\+\?\|\\])/gi,"\\$1")+")(?![^<>]*>)(?![^&;]+;)","gi"),"<strong>$1</strong>");
},scroll:true,scrollHeight:180};
var _20e=function(_20f,_210,end){
if(_20f.createTextRange){
var _212=_20f.createTextRange();
_212.collapse(true);
_212.moveStart("character",_210);
_212.moveEnd("character",end);
_212.select();
}else{
if(_20f.setSelectionRange){
_20f.setSelectionRange(_210,end);
}else{
if(_20f.selectionStart){
_20f.selectionStart=_210;
_20f.selectionEnd=end;
}
}
}
_20f.focus();
};
var _213=function(_214){
var data={};
var _216=0;
function matchSubset(s,sub){
if(!_214.matchCase){
s=s.toLowerCase();
}
var i=s.indexOf(sub);
if(i==-1){
return false;
}
return i==0||_214.matchContains;
}
function add(q,_21b){
if(_216>_214.cacheLength){
flush();
}
if(!data[q]){
_216++;
}
data[q]=_21b;
}
function populate(){
if(!_214.data){
return false;
}
var _21c={},nullData=0;
if(!_214.url){
_214.cacheLength=1;
}
_21c[""]=[];
for(var i=0,ol=_214.data.length;i<ol;i++){
var _21e=_214.data[i];
_21e=(typeof _21e=="string")?[_21e]:_21e;
var _21f=_214.formatMatch(_21e,i+1,_214.data.length);
if(_21f===false){
continue;
}
var _220=_21f.charAt(0).toLowerCase();
if(!_21c[_220]){
_21c[_220]=[];
}
var row={value:_21f,data:_21e,result:_214.formatResult&&_214.formatResult(_21e)||_21f};
_21c[_220].push(row);
if(nullData++<_214.max){
_21c[""].push(row);
}
}
$.each(_21c,function(i,_223){
_214.cacheLength++;
add(i,_223);
});
}
setTimeout(populate,25);
function flush(){
data={};
_216=0;
}
return {flush:flush,add:add,populate:populate,load:function(q){
if(!_214.cacheLength||!_216){
return null;
}
if(!_214.url&&_214.matchContains){
var csub=[];
for(var k in data){
if(k.length>0){
var c=data[k];
$.each(c,function(i,x){
if(matchSubset(x.value,q)){
csub.push(x);
}
});
}
}
return csub;
}else{
if(data[q]){
return data[q];
}else{
if(_214.matchSubset){
for(var i=q.length-1;i>=_214.minChars;i--){
var c=data[q.substr(0,i)];
if(c){
var csub=[];
$.each(c,function(i,x){
if(matchSubset(x.value,q)){
csub[csub.length]=x;
}
});
return csub;
}
}
}
}
}
return null;
}};
};
var _22d=function(_22e,_22f,_230,_231,_232,_233){
var _234={ACTIVE:"ac_over"};
var _235,active=-1,data,term="",needsInit=true,popup,list,shadow;
function init(){
if(!needsInit){
return;
}
popup=$("<div />").addClass("ac_popup");
_233.append(popup);
popup.dr.shadows();
shadow=$(".shadow",_233);
if(shadow.length==0){
shadow=popup;
}
var _236=$(".topRight",shadow);
list=$("<ul/>").appendTo(popup).mouseover(function(_237){
if(target(_237).nodeName&&target(_237).nodeName.toUpperCase()=="LI"){
active=$("li",list).removeClass(_234.ACTIVE).index(target(_237));
$(target(_237)).addClass(_234.ACTIVE);
}
}).click(function(_238){
$(target(_238)).addClass(_234.ACTIVE);
var _239=_230();
if(_239!==null){
_232(_239);
}
_22f.focus();
return false;
}).mousedown(function(){
_231.mouseDownOnSelect=true;
}).mouseup(function(){
_231.mouseDownOnSelect=false;
});
if(_22e.width>0){
popup.css("width",_22e.width);
}
needsInit=false;
}
function target(_23a){
var _23b=_23a.target;
while(_23b&&_23b.tagName!="LI"){
_23b=_23b.parentNode;
}
if(!_23b){
return [];
}
return _23b;
}
function moveSelect(step){
_235.slice(active,active+1).removeClass(_234.ACTIVE);
movePosition(step);
var _23d=_235.slice(active,active+1).addClass(_234.ACTIVE);
if(_22e.scroll){
var _23e=0;
_235.slice(0,active).each(function(){
_23e+=this.offsetHeight;
});
if((_23e+_23d[0].offsetHeight-list.scrollTop())>list[0].clientHeight){
list.scrollTop(_23e+_23d[0].offsetHeight-list.innerHeight());
}else{
if(_23e<list.scrollTop()){
list.scrollTop(_23e);
}
}
}
}
function movePosition(step){
active+=step;
if(active<0){
active=0;
}else{
if(active>=_235.size()){
active=_235.size()-1;
}
}
}
function limitNumberOfItems(_240){
return _22e.max&&_22e.max<_240?_22e.max:_240;
}
function fillList(){
list.empty();
var max=limitNumberOfItems(data.length);
for(var i=0;i<max;i++){
if(!data[i]){
continue;
}
var _243=_22e.formatItem(data[i].data,i+1,max,data[i].value,term);
if(_243===false){
continue;
}
var li=$("<li/>").html(_22e.highlight(_243,term)).addClass(i%2==0?"ac_even":"ac_odd").appendTo(list)[0];
$.data(li,"ac_data",data[i]);
}
_235=list.find("li");
if(_22e.selectFirst){
_235.slice(0,1).addClass(_234.ACTIVE);
active=0;
}
if($.fn.bgiframe){
shadow.bgiframe();
}
}
return {display:function(d,q){
if(active!=-1){
active=0;
}
init();
data=d;
term=q;
fillList();
},next:function(){
moveSelect(1);
},prev:function(){
moveSelect(-1);
},pageUp:function(){
if(active!=0&&active-9<0){
moveSelect(-active);
}else{
moveSelect(-9);
}
},pageDown:function(){
if(active!=_235.size()-1&&active+9>_235.size()){
moveSelect(_235.size()-1-active);
}else{
moveSelect(9);
}
},hide:function(){
shadow&&shadow.slideUp(function(){
_233.parent().removeClass("ac_open");
});
_235&&_235.removeClass(_234.ACTIVE);
active=-1;
},visible:function(){
return shadow&&shadow.is(":visible");
},current:function(){
return this.visible()&&(_235.filter("."+_234.ACTIVE)[0]||_22e.selectFirst&&_235[0]);
},show:function(){
var _247=_22f.offsetWidth-2;
var _248=$(_22f).offset();
_233.parent().addClass("ac_open");
popup.css({width:typeof _22e.width=="string"||_22e.width>0?_22e.width:_247});
shadow.css({top:_22f.offsetHeight-1}).show();
if(_22e.scroll){
list.scrollTop(0);
list.css({maxHeight:_22e.scrollHeight,overflow:"auto"});
if($.browser.msie&&typeof document.body.style.maxHeight==="undefined"){
var _249=0;
_235.each(function(){
_249+=this.offsetHeight;
});
var _24a=_249>_22e.scrollHeight;
list.css("height",_24a?_22e.scrollHeight:_249);
if(!_24a){
_235.width(list.width()-parseInt(_235.css("padding-left"))-parseInt(_235.css("padding-right")));
}
}
}
},selected:function(){
var _24b=_235&&_235.filter("."+_234.ACTIVE).removeClass(_234.ACTIVE);
return _24b&&_24b.length&&$.data(_24b[0],"ac_data");
},emptyList:function(){
list&&list.empty();
},unbind:function(){
popup&&popup.remove();
}};
};
var _24c=function(_24d,_24e,_24f){
var KEY={UP:38,DOWN:40,DEL:46,TAB:9,RETURN:13,ESC:27,COMMA:188,PAGEUP:33,PAGEDOWN:34,BACKSPACE:8};
var _251=$(_24d),originalInput=_24d,boundInput=null;
var _252=$("<div class=\"ac_wrapper\" style=\"width:"+(_24d.offsetWidth)+"px;height:"+_24d.offsetHeight+"px;\" />");
boundInput=_251.clone();
boundInput.removeAttr("name").removeAttr("id");
if(_24d.tagName.toLowerCase()=="textarea"){
boundInput.css("max-width",_24d.offsetWidth+"px").css("max-height",_24d.offsetHeight+"px");
_252.addClass("ac_textareaWrapper");
}
boundInput.appendTo(_252);
boundInput.val(_251.val());
boundInput.attr("data-expand-collapse","false");
_251.attr("data-expand-collapse","false");
_251.data("validationEnabled",false);
_252.insertBefore(_251);
_252.wrap("<div class=\"autocomplete\" />");
_251.hide();
_251=boundInput;
_24d=boundInput[0];
var _253=_24d;
var _254=$("<span class=\"loading\" />").appendTo(_252).hide();
if(_24e.comboBox){
_252.addClass("ac_comboBox");
var _255=$("<span class=\"handle\" />").appendTo(_252).mousedown(function(evt){
evt.preventDefault();
}).click(function(evt){
var func=function(){
var show=true;
if(typeof select!=="undefined"){
if(select.visible()){
select.hide();
show=false;
}
}
if(show){
_24d.focus();
hasFocus=1;
onChange(0,true);
}
};
setTimeout(func,20);
evt.preventDefault();
});
}
var _25a=function(){
if(boundInput!==null){
$(originalInput).val(boundInput.val());
}
};
var _25b=function(){
if($.dr&&$.dr.form&&$.dr.form.validateField){
$.dr.form.validateField(_24d,true);
}
};
_251=$(_24d).attr("autocomplete","off");
var _25c,previousValue="",cache=new _213(_24e),hasFocus=0,lastKeyPressCode,config={mouseDownOnSelect:false},select=new _22d(_24e,_24d,selectCurrent,config,doCallback,_252),blockSubmit;
$.browser.opera&&$(_24d.form).bind("submit.autocomplete",function(){
if(blockSubmit){
blockSubmit=false;
return false;
}
});
function doCallback(_25d){
_25b();
if(!_25d){
return;
}
_25a();
if(typeof _24e.callback=="function"){
var func=function(){
_24e.callback(_25d[0],_25d[1]);
};
setTimeout(func,10);
}
}
_251.bind(($.browser.opera?"keypress":"keydown")+".autocomplete",function(_25f){
lastKeyPressCode=_25f.keyCode;
switch(_25f.keyCode){
case KEY.UP:
_25f.preventDefault();
if(select.visible()){
select.prev();
}else{
onChange(0,true);
}
break;
case KEY.DOWN:
_25f.preventDefault();
if(select.visible()){
select.next();
}else{
onChange(0,true);
}
break;
case KEY.PAGEUP:
_25f.preventDefault();
if(select.visible()){
select.pageUp();
}else{
onChange(0,true);
}
break;
case KEY.PAGEDOWN:
_25f.preventDefault();
if(select.visible()){
select.pageDown();
}else{
onChange(0,true);
}
break;
case _24e.multiple&&$.trim(_24e.multipleSeparator)==","&&KEY.COMMA:
case KEY.TAB:
case KEY.RETURN:
var _260=selectCurrent();
if(_260!==null){
blockSubmit=true;
if(!_24e.multiple){
if(_25f.keyCode==KEY.RETURN){
_25f.keyCode=KEY.TAB;
_25f.preventDefault();
}else{
_25f.keyCode=KEY.TAB;
}
}else{
_25f.preventDefault();
}
doCallback(_260);
}
break;
case KEY.ESC:
select.hide();
break;
default:
clearTimeout(_25c);
_25c=setTimeout(onChange,_24e.delay);
break;
}
_25a();
_25b();
}).focus(function(){
hasFocus++;
}).blur(function(evt){
_25b();
_25a();
hasFocus=0;
if(!config.mouseDownOnSelect){
hideResults();
}
}).click(function(){
if(hasFocus++>1&&!select.visible()){
onChange(0,true);
}
}).bind("search",function(){
var fn=(arguments.length>1)?arguments[1]:null;
function findValueCallback(q,data){
var _265;
if(data&&data.length){
for(var i=0;i<data.length;i++){
if(data[i].result.toLowerCase()==q.toLowerCase()){
_265=data[i];
break;
}
}
}
if(typeof fn=="function"){
fn(_265);
}else{
doCallback(_265);
}
}
$.each(trimWords(_251.val()),function(i,_268){
request(_268,findValueCallback,findValueCallback);
});
}).bind("flushCache",function(){
cache.flush();
}).bind("setOptions",function(){
$.extend(_24e,arguments[1]);
if("data" in arguments[1]){
cache.populate();
}
}).bind("unautocomplete",function(){
select.unbind();
_251.unbind();
$(_24d.form).unbind(".autocomplete");
});
function selectCurrent(){
var _269=select.selected();
if(!_269){
return false;
}
var v=_269.result;
previousValue=v;
if(_24e.multiple){
var _26b=trimWords(_251.val());
if(_26b.length>1){
v=_26b.slice(0,_26b.length-1).join(_24e.multipleSeparator)+_24e.multipleSeparator+v;
}
v+=_24e.multipleSeparator;
}
_251.val(v);
hideResultsNow();
return [_269.data,_269.value];
}
function onChange(arg1,_26d){
if(lastKeyPressCode==KEY.DEL){
select.hide();
return;
}
var _26e=_251.val();
if(!_26d&&_26e==previousValue){
return;
}
previousValue=_26e;
_26e=lastWord(_26e);
if(_26e.length>=_24e.minChars){
_254.show();
if(!_24e.matchCase){
_26e=_26e.toLowerCase();
}
request(_26e,receiveData,hideResultsNow);
}else{
stopLoading();
select.hide();
}
}
function trimWords(_26f){
if(!_26f){
return [""];
}
var _270=_26f.split(_24e.multipleSeparator);
var _271=[];
$.each(_270,function(i,_273){
if($.trim(_273)){
_271[i]=$.trim(_273);
}
});
return _271;
}
function lastWord(_274){
if(!_24e.multiple){
return _274;
}
var _275=trimWords(_274);
return _275[_275.length-1];
}
function autoFill(q,_277){
if(_24e.autoFill&&(lastWord(_251.val()).toLowerCase()==q.toLowerCase())&&lastKeyPressCode!=KEY.BACKSPACE){
_251.val(_251.val()+_277.substring(lastWord(previousValue).length));
_20e(_24d,previousValue.length,previousValue.length+_277.length);
}
}
function hideResults(){
clearTimeout(_25c);
_25c=setTimeout(hideResultsNow,200);
}
function hideResultsNow(){
var _278=select.visible();
select.hide();
clearTimeout(_25c);
stopLoading();
if(_24e.mustMatch){
_251.dr.autocomplete.search(function(_279){
if(!_279){
if(_24e.multiple){
var _27a=trimWords(_251.val()).slice(0,-1);
_251.val(_27a.join(_24e.multipleSeparator)+(_27a.length?_24e.multipleSeparator:""));
}else{
_251.val("");
}
}
});
}
if(_278){
_20e(_24d,_24d.value.length,_24d.value.length);
}
}
function receiveData(q,data){
if(data&&data.length&&hasFocus){
stopLoading();
select.display(data,q);
autoFill(q,data[0].value);
select.show();
}else{
hideResultsNow();
}
}
function request(term,_27e,_27f){
if(!_24e.matchCase){
term=term.toLowerCase();
}
var data=cache.load(term);
if(data&&data.length){
_27e(term,data);
}else{
if((typeof _24e.url=="string")&&(_24e.url.length>0)){
var _281={ajaxTime:new Date()};
$.each(_24e.extraParams,function(key,_283){
_281[key]=typeof _283=="function"?_283():_283;
});
$.ajax({mode:"abort",port:"autocomplete"+_24d.name,dataType:_24e.dataType,url:_24e.url,data:$.extend({query:lastWord(term),limit:_24e.max},_281),success:function(data){
var _285=_24e.parse&&_24e.parse(data)||parse(data);
cache.add(term,_285);
_27e(term,_285);
},error:function(_286,_287,_288){
if(typeof _24e.errorCallback=="function"){
_24e.failureCallback(_286,_287,_288);
}
}});
}else{
select.emptyList();
_27f(term);
}
}
}
function parse(data){
var _28a=[];
var rows=data.split("\n");
for(var i=0;i<rows.length;i++){
var row=$.trim(rows[i]);
if(row){
row=row.split("|");
_28a[_28a.length]={data:row,value:row[0],result:_24e.formatResult&&_24e.formatResult(row,row[0])||row[0]};
}
}
return _28a;
}
function stopLoading(){
_254.hide();
}
return {boundInput:_251};
};
var _28e=function(evt,_290){
var a=$(".autocomplete, .comboBox",_290);
if(a.length>0){
a.dr.autocomplete();
}
};
$("form").live("beforeIndexFields",_28e);
$.dr.autocomplete={setDefaults:function(_292){
if(_292){
$.extend(_20a,_292);
}
}};
$.namespace("dr",{autocomplete:function(_293,_294){
var _295=false,isUrl=(typeof _293=="string")?true:false;
if(!_294){
_294={};
}
if(arguments.length==0){
_295=true;
}
return this.filter(function(){
var _296=$(this);
if(_296.data("autocomplete_inited")||(!_296.hasClass("autocomplete")&&!_296.hasClass("comboBox"))){
return false;
}else{
return true;
}
}).each(function(){
var jObj=$(this);
var _298=_294;
if(_295){
isUrl=false;
_293=this.getAttribute("data-source");
var _299=this.getAttribute("data-url");
dataOptions=this.getAttribute("data-options");
if(!_293){
if(!_299){
$.dr.utils.logError("("+this.id+") did not contain a data-url or data-source attribute");
return;
}else{
isUrl=true;
_293=_299;
}
}else{
_293=$.dr.utils.evalString(_293,"The referenced data-source for ("+this.id+") does not exist.");
if(typeof _293=="error"){
return;
}
}
if(dataOptions){
_298=$.dr.utils.evalString(dataOptions,"Error parsing autocomplete data-options for ("+this.id+")");
if(typeof _298=="error"){
return;
}
}
}
if(this.tagName.toLowerCase()=="textarea"){
if(typeof _298.multiple=="undefined"){
_298.multiple=true;
}
}
var _29a=$.extend({},_20a,{url:isUrl?_293:null,data:isUrl?null:_293,delay:isUrl?_20a.delay:10},_298);
_29a.highlight=_29a.highlight||function(_29b){
return _29b;
};
_29a.formatMatch=_29a.formatMatch||_29a.formatItem;
jObj.data("autocomplete_inited","true");
var ac=new _24c(this,_29a);
jObj.data("autocomplete",ac);
if(!_295){
$(this.form).dr.form.initFields(ac.boundInput);
}
});
}});
$.namespace("dr.autocomplete",{search:function(_29d){
return this.trigger("search",[_29d]);
},flushCache:function(){
return this.trigger("flushCache");
},setOptions:function(_29e){
return this.trigger("setOptions",[_29e]);
},destroy:function(){
return this.trigger("unautocomplete");
}});
})(jQuery);
(function($){
$.namespace("dr.button",{disable:function(_2a0){
if(typeof $.dr.processingDialog=="object"){
$.dr.processingDialog.disable();
}
return this.each(function(){
var _2a1=$(this);
if(this.tagName.toLowerCase()=="button"){
var text=(_2a0)?_2a0:(_2a1.hasClass("search"))?BUTTON_SEARCHING:(_2a1.hasClass("login"))?BUTTON_AUTHORIZING:BUTTON_PROCESSING;
this.innerHTML="<span><span><span>"+text+"</span></span></span>";
_2a1.addClass("processing");
this.disabled=true;
}
});
},changeText:function(_2a3,_2a4,_2a5,_2a6){
return this.each(function(){
if(this.tagName.toLowerCase()=="button"){
var _2a7="";
if(_2a3){
_2a7=_2a3;
}
if(_2a6){
this.innerHTML="<span><span><span>"+_2a7+"</span></span></span>";
$(this).addClass("rightAlign");
}else{
this.innerHTML="<span><span><span>"+_2a7+"</span></span></span>";
}
if(_2a5){
$(this).removeClass(_2a4);
$(this).addClass(_2a5);
}
}
});
}});
})(jQuery);
DR.Widgets.FauxTree=function(_2a8,guid,_2aa,_2ab,_2ac,_2ad){
this.childNodes=[];
this.parentNode=_2a8;
this.isExpanded=false;
if(_2ac!==undefined){
this.saveState=_2ac;
this.cookieName=_2ad;
}else{
this.saveState=false;
this.cookieName=null;
}
this.isDirectory=_2aa;
this.hasCheckbox=(_2ab===true)?true:false;
this.guid=guid;
this.obj=document.getElementById(this.guid);
var _2ae=guid.split(DR.Widgets.FauxTree.PATH_SEPARATOR);
this.level=_2ae.length;
this.shortId=_2ae[_2ae.length-1];
};
DR.Widgets.FauxTree.PATH_SEPARATOR=".";
DR.Widgets.FauxTree.INDENTED_COLUMN_POSITION=0;
DR.Widgets.FauxTree.EXPANDED_CHILDREN_DISPLAY_VALUE="";
DR.Widgets.FauxTree.COLLAPSED_CHILDREN_DISPLAY_VALUE="none";
DR.Widgets.FauxTree.EMPTY_DIRECTORY_STYLE="empty";
DR.Widgets.FauxTree.EXPANDED_DIRECTORY_STYLE="expanded";
DR.Widgets.FauxTree.COLLAPSED_DIRECTORY_STYLE="collapsed";
DR.Widgets.FauxTree.ITEM_STYLE="item";
DR.Widgets.FauxTree.FAUX_TREE_ROOT="FauxTreeRoot";
DR.Widgets.FauxTree.NODE_LOOKUP_TABLE=[];
DR.Widgets.FauxTree.countNodes=function(){
var num=0;
for(var i in DR.Widgets.FauxTree.NODE_LOOKUP_TABLE){
num++;
}
alert(num);
};
DR.Widgets.FauxTree.isNode=function(node){
return node.guid;
};
DR.Widgets.FauxTree.initConstants=function(_2b2){
DR.Widgets.FauxTree.INDENTED_COLUMN_POSITION=(_2b2)?_2b2:0;
};
DR.Widgets.FauxTree.prototype={refreshTreeState:function(){
if(this.saveState){
DR.Widgets.FauxTree.NODE_LOOKUP_TABLE[DR.Widgets.FauxTree.FAUX_TREE_ROOT]=this;
this.stateCookie=new DR.Utils.Cookie(this.cookieName);
this.stateCookie.type="Array";
this.stateCookie.load();
this.findChild().revertState();
}
},addItem:function(path,_2b4){
var _2b5=path.split(DR.Widgets.FauxTree.PATH_SEPARATOR);
var _2b6=true;
if(_2b5.length>1){
_2b6=true;
}else{
_2b6=(_2b4)?true:false;
}
var _2b7=_2b5.shift();
var guid=null;
if(this.guid===""){
guid=_2b7;
}else{
guid=this.guid+DR.Widgets.FauxTree.PATH_SEPARATOR+_2b7;
}
if(!this.childNodes[_2b7]){
this.childNodes[_2b7]=new DR.Widgets.FauxTree(this,guid,_2b6,this.hasCheckbox,this.saveState);
DR.Widgets.FauxTree.NODE_LOOKUP_TABLE[guid]=this.childNodes[_2b7];
}
if(_2b5.length>0){
this.childNodes[_2b7].addItem(_2b5.join(DR.Widgets.FauxTree.PATH_SEPARATOR),_2b4);
}
},findItem:function(path){
return DR.Widgets.FauxTree.NODE_LOOKUP_TABLE[path];
},toggleDirectory:function(_2ba){
var _2bb=document.getElementById(_2ba);
var _2bc=(_2bb.className.indexOf(DR.Widgets.FauxTree.EXPANDED_DIRECTORY_STYLE)!=-1)?true:false;
var _2bd=this.findItem(_2ba);
if(_2bd.isDirectory){
if(_2bc){
_2bd.collapse();
if(this.saveState){
this.stateCookie.removeArrayValue(_2bd.shortId);
}
}else{
_2bd.expand();
if(this.saveState){
this.stateCookie.addArrayValue(_2bd.shortId);
}
}
}
},findChild:function(){
var _2be;
for(var i in this.childNodes){
_2be=this.childNodes[i];
break;
}
return _2be;
},expandAll:function(){
this.obj.style.display=DR.Widgets.FauxTree.EXPANDED_CHILDREN_DISPLAY_VALUE;
if(this.isDirectory){
if(this.hasChildren()===0){
this.obj.className=DR.Widgets.FauxTree.EMPTY_DIRECTORY_STYLE;
}else{
this.obj.className=(this.isExpanded)?DR.Widgets.FauxTree.EXPANDED_DIRECTORY_STYLE:DR.Widgets.FauxTree.COLLAPSED_DIRECTORY_STYLE;
}
}else{
this.obj.className=DR.Widgets.FauxTree.ITEM_STYLE;
}
if(this.hasCheckbox){
this.obj.getElementsByTagName("td")[1].className="first level"+this.level;
}else{
this.obj.getElementsByTagName("td")[0].className="first level"+this.level;
}
if(this.isDirectory){
this.expand();
for(var i in this.childNodes){
if(DR.Widgets.FauxTree.isNode(this.childNodes[i])){
var _2c1=this.childNodes[i];
_2c1.expandAll();
}
}
}
},revertState:function(){
if(this.saveState){
var _2c2=this.getCookieArray();
if(this.isDirectory){
var _2c3=false;
if(_2c2.length>0){
var i=0;
while(!_2c3&&i<_2c2.length){
if(_2c2[i]==this.shortId){
_2c3=true;
this.expand();
}
i++;
}
}
if(_2c3){
for(var j in this.childNodes){
if(DR.Widgets.FauxTree.isNode(this.childNodes[j])){
var _2c6=this.childNodes[j];
_2c6.revertState();
}
}
}
}
}
},expandNRestoreChildrenState:function(){
this.obj.style.display=DR.Widgets.FauxTree.EXPANDED_CHILDREN_DISPLAY_VALUE;
if(this.isDirectory){
if(this.hasChildren()===0){
this.obj.className=DR.Widgets.FauxTree.EMPTY_DIRECTORY_STYLE;
}else{
this.obj.className=(this.isExpanded)?DR.Widgets.FauxTree.EXPANDED_DIRECTORY_STYLE:DR.Widgets.FauxTree.COLLAPSED_DIRECTORY_STYLE;
}
}else{
this.obj.className=DR.Widgets.FauxTree.ITEM_STYLE;
}
if(this.hasCheckbox){
this.obj.getElementsByTagName("td")[1].className="first level"+this.level;
}else{
this.obj.getElementsByTagName("td")[0].className="first level"+this.level;
}
if(this.saveState){
var _2c7=this.getCookieArray();
var _2c8=false;
if(_2c7.length>0){
var i=0;
while(!_2c8&&i<_2c7.length){
if(_2c7[i]==this.shortId){
this.isExpanded=true;
}
i++;
}
}
}
if(this.isExpanded){
for(var j in this.childNodes){
if(DR.Widgets.FauxTree.isNode(this.childNodes[j])){
var _2cb=this.childNodes[j];
_2cb.expandNRestoreChildrenState();
}
}
}
},hasChildren:function(){
for(var i in this.childNodes){
if(DR.Widgets.FauxTree.isNode(this.childNodes[i])){
return true;
}
}
return false;
},collapseNStoreChildrenState:function(){
for(var i in this.childNodes){
if(DR.Widgets.FauxTree.isNode(this.childNodes[i])){
this.childNodes[i].obj.style.display=DR.Widgets.FauxTree.COLLAPSED_CHILDREN_DISPLAY_VALUE;
this.childNodes[i].collapseNStoreChildrenState();
}
}
},expand:function(){
this.isExpanded=true;
this.expandNRestoreChildrenState();
},getCookieArray:function(){
return DR.Widgets.FauxTree.NODE_LOOKUP_TABLE[DR.Widgets.FauxTree.FAUX_TREE_ROOT].stateCookie.arrayValues;
},collapse:function(){
this.isExpanded=false;
this.obj.className=DR.Widgets.FauxTree.COLLAPSED_DIRECTORY_STYLE;
this.collapseNStoreChildrenState();
}};
(function($){
var _2cf=[];
var _2d0=false;
var _2d1={INPUT_FOCUS_CLASS:"inputFocus"};
var _2d2={WINDOW_ON_BEFORE_UNLOAD:"There have been changes made to the form that have not been saved."};
$.dr.form={getMessages:function(){
return _2d2;
},getDefaults:function(){
return _2d1;
},setDefaults:function(_2d3){
if(_2d3){
$.extend(_2d1,_2d3);
}
$(document).trigger("afterFormSetDefaults",[_2d3]);
},setMessages:function(_2d4){
if(_2d4){
$.extend(_2d2,_2d4);
}
$(document).trigger("afterFormSetMessages",[_2d4]);
}};
window.customFormIndexerCallBack=function(){
};
var _2d5=function(_2d6){
$("form",_2d6).dr.form();
customFormIndexerCallBack();
customFormIndexerCallBack=function(){
};
};
var _2d7=function(_2d8){
if(parent.overlayStack){
var _2d9=parent.overlayStack.getCurrent();
}
var _2da=(typeof _2d9!=="undefined")?_2d9.loading:false;
if(_2da){
var func=function(){
_2d7(_2d8);
};
window.setTimeout(func,50);
}else{
_2d5(_2d8);
}
};
var _2dc=function(evt,_2de){
$.dr.form.setDefaults({});
$.dr.form.setMessages({});
$(document).trigger("beforeInitForms");
if($.browser.msie&&$("body.modalPage").length>0){
_2d7(_2de);
}else{
_2d5(_2de);
}
};
$.dr.addUnobtrusiveEvent(_2dc);
var _2df=function(evt){
if(!this.getAttribute("readonly")&&!this.disabled&&this.type!="file"){
if(!(this.type=="select-one"&&DR.Utils.BrowserDetect.version>6)){
$(this).addClass(_2d1.INPUT_FOCUS_CLASS);
}
}
};
var _2e1=function(evt){
var _2e3=this;
var func=function(){
if(!_2e3.getAttribute("readonly")&&!_2e3.disabled&&_2e3.type!="file"){
$(_2e3).removeClass(_2d1.INPUT_FOCUS_CLASS);
}
};
window.setTimeout(func,50);
};
$.dr.utils.getSelectOptionValue=function(_2e5){
if(_2e5){
if(_2e5.text!==""&&_2e5.outerHTML&&_2e5.outerHTML.toLowerCase().indexOf("value=")==-1){
return _2e5.text;
}else{
return _2e5.value;
}
}
};
$.dr.utils.hasFieldChanged=function(obj){
var type=obj.type;
if(type=="checkbox"||type=="radio"){
if(obj.defaultChecked!=obj.checked){
return true;
}
}else{
if(type=="select-one"){
if($(obj).dr.form.field.getDefaultValue()!=$(obj).val()){
return true;
}
}else{
if(type=="select-multiple"){
var _2e8=$(obj).val();
_2e8=(_2e8===null)?"":_2e8.join(",");
if($(obj).dr.form.field.getDefaultValue()!=_2e8){
return true;
}
}else{
if($(obj).dr.form.field.getDefaultValue()!=$(obj).val()){
return true;
}
}
}
}
return false;
};
$.dr.utils.getLabel=function(obj){
var _2ea;
if($(obj).data("label")===undefined){
var _2eb=$(obj.form).data("labels");
if(_2eb===undefined){
_2eb=$("label",obj.form);
$(obj.form).data("labels",_2eb);
}
var _2ec=_2eb.filter("[for="+obj.id+"]");
_2ea=(_2ec.length)?_2ec.text().replace(":",""):obj.name;
$(obj).data("label",_2ea);
}
return _2ea;
};
var _2ed=function(_2ee){
var _2ef=_2ee.onsubmit;
_2ee.onsubmit=function(){
var _2f0=true;
if(typeof _2ef=="function"){
var test=_2ef();
_2f0=(typeof test=="undefined"||test)?true:false;
}
var _2f2=$(_2ee).data("behavior");
var _2f3=(_2f0&&$(_2ee).dr.form.validate()&&!_2f2.forceCheckChanges)?true:false;
if(_2f2.checkChanges&&_2f3){
$(_2ee).dr.form.enableCheckChanges(false);
}
return _2f3;
};
var _2f4=_2ee.onsubmit;
_2ee._nativeFormSubmit=_2ee.submit;
_2ee.submit=function(){
if(_2f4()){
if($.browser.msie){
_2ee._nativeFormSubmit();
}else{
_2ee.submit=_2ee._nativeFormSubmit;
if(_2ee.submit!==undefined){
_2ee.submit();
}
}
}
};
};
var _2f5=function(_2f6,_2f7){
this.formObj=_2f6;
this.options=_2f7;
this.init();
};
_2f5.prototype={init:function(){
this.firstField=null;
this.normalizeName();
this.bindBehavior();
},normalizeName:function(){
var _2f8=this.formObj;
var _2f9="name";
var n=_2f8.attributes[_2f9];
var f="form_"+new Date().getTime();
if(n){
if(!($.browser.msie&&n.value==="")){
f=n.value;
}
}
_2f8.setAttribute("name",f);
_2f8._formName=f;
this.formIndex=_2cf.length;
_2cf.push(_2f8);
},bindBehavior:function(){
var _2fc=this.formObj;
var _2fd=$(this.formObj);
var _2fe=(_2fd.attr("data-behavior")=="standard")?true:false;
var _2ff=(_2fd.attr("data-behavior")=="search")?true:false;
var _300=(_2fd.attr("data-enable-field-events")=="false")?false:true;
var _301=(_2fd.attr("data-check-changes")=="false")?false:true;
var _302=(_2fd.attr("data-auto-focus")=="false")?false:true;
var _303=(_2fd.attr("data-force-check-changes")=="true")?true:false;
this.checkChanges=(_2fe&&(_301||_303))?true:false;
this.autoFocus=((_2fe||_2ff)&&_302)?true:false;
this.enableFieldEvents=((_2fe||_2ff)&&_300)?true:false;
this.forceCheckChanges=_303;
if(_2fe||_2ff){
var _304=($.browser.msie)?$(":input",this.formObj):$(this.formObj.elements);
this.initFields(_304);
if(_301||_303){
this.addUnloadEvent();
}
if(this.autoFocus){
this.focusFirstElement();
}
_2ed(_2fc);
}
},initFields:function(_305,_306){
if(this.formObj.getAttribute("_inited")===null||_306){
var _307=this;
var _308=_305.length;
var _309=$.dr.getPlugins("form");
for(var i=0;i<_309.length;i++){
_309[i].call(this,_305);
}
_305.filter("input[type=text], select, textarea").focus(_2df).blur(_2e1).end();
if(this.autoFocus&&this.firstField===null&&!_2d0&&$(this.formObj).filter(":visible").length>0){
_305.filter("input[type=text],select, textarea").filter(":visible").filter(":first").each(function(i){
_307.firstField=this;
_2d0=true;
return false;
});
}
}
this.formObj.setAttribute("_inited","true");
},focusFirstElement:function(){
var obj=this.firstField;
if(obj!==null){
try{
obj.focus();
if(obj.type=="text"||obj.type=="textarea"){
obj.select();
}
}
catch(e){
}
}
},addUnloadEvent:function(){
if(typeof window.onbeforeunload!="function"){
var _30d=function(){
var _30e=false;
for(var i=0;i<_2cf.length;i++){
var _310=_2cf[i];
if($(_310).data("behavior")){
if($(_310).data("behavior").checkChanges&&!$(_310).data("behavior").forceCheckChanges){
if($(_310).dr.form.checkForChanges()){
_30e=true;
break;
}
}
}
}
if(_30e){
if($.browser.msie){
window.onerror=function(err){
window.event.returnValue=(err.toLowerCase().indexOf("unspecified error")>=0)?true:false;
};
}
var m=_2d2.WINDOW_ON_BEFORE_UNLOAD;
if(!$.browser.safari){
m="\n"+m+"\n";
}
if(typeof evt=="undefined"){
evt=window.event;
}
if(evt){
evt.returnValue=m;
}
$(document).trigger("showChangesWarning");
return m;
}
};
window.onbeforeunload=_30d;
}
}};
$.namespace("dr",{form:function(_313){
try{
_313=(typeof _313=="object")?$.extend(_2d1,_313):_2d1;
var _314=this.each(function(){
if(this.tagName.toLowerCase()=="form"){
$(this).trigger("beforeIndexFields");
$(this).data("behavior",new _2f5(this,_313));
$(this).trigger("afterIndexFields");
}
});
_2d0=false;
return _314;
}
catch(e){
$.dr.utils.logError("Error when binding form behavior",e);
}
}});
function getFormObj(_315){
if(_315.length>0){
var f=$(_315[0]).data("behavior");
return (f)?f:{};
}
}
$.namespace("dr.form",{get:function(){
return getFormObj(this);
},setOptions:function(_317){
if(_317){
$.extend(getFormObj(this).options,_317);
}
$(document).trigger("afterFormSetOptions",[_317]);
},getChangedFields:function(){
var _318=this[0];
return $(":input",_318).not(":button").not(":hidden").filter(function(){
if($.dr.utils.hasFieldChanged(this)){
return true;
}
return false;
});
},enableCheckChanges:function(flag){
getFormObj(this).checkChanges=flag;
},enableAutoFocus:function(flag){
getFormObj(this).autoFocus=flag;
},reIndex:function(flag){
var _31c=getFormObj(this);
_31c.fieldsWithValidation=[];
_31c.initFields(($.browser.msie)?$(":input",_31c):$(_31c.elements));
},initFields:function(_31d,_31e){
var _31f=getFormObj(this);
_31e=(_31e===false)?false:true;
_31f.initFields(_31d,_31e);
},checkForChanges:function(){
var _320=$(this).dr.form.getChangedFields();
return (_320.length>0)?true:false;
},displayChangedFields:function(){
return this.each(function(){
var _321=$(this).dr.form.getChangedFields();
console.log("Changed Fields for "+this._formName);
if(_321.length>0){
for(var i=0;i<_321.length;i++){
var _323=_321[i];
console.log("ID: <b>"+_323.id+"</b>");
console.log("     VALUE:"+$(_323).dr.form.field.getDefaultValue());
console.log("     NEW_VALUE:"+$(_323).val());
}
}else{
console.log("None");
}
});
},destroy:function(){
return this.each(function(){
if($(this).data("behavior")){
$(this).data("behavior",null);
}
});
}});
$.namespace("dr.form.field",{getDefaultValue:function(){
if(this.length){
var elem=this[0];
var type=elem.type;
if(type=="checkbox"||type=="radio"){
if(elem.defaultChecked){
return true;
}else{
return false;
}
}else{
if($.nodeName(elem,"select")){
var _326=[];
var _327=elem.options;
for(var i=0;i<_327.length;i++){
if(_327[i].defaultSelected){
var val=$.dr.utils.getSelectOptionValue(_327[i]);
if(type=="select-one"){
return val;
}else{
_326.push(val);
}
}
}
if(type=="select-one"&&_326.length===0){
return $.dr.utils.getSelectOptionValue(_327[0]);
}
return (_326.length>0)?_326.join(","):"";
}else{
return elem.defaultValue.replace(/\r/g,"");
}
}
}
}});
})(jQuery);
(function($){
var _32b={PAGES_START_AT_ZERO:false,PAGING_OVERRIDE:null,SELECT_ALL_ACROSS_PAGES_ENABLED:true,SELECT_ALL_RESULTS:"all",SUBMIT_TYPE:"get"};
var _32c={SORT_BY:"Sort by {0}",INVALID_NUMBER:"Please enter a valid number.",VIEW_SELECTIONS:"View Selections",CLEAR_SELECTIONS:"Clear Selections",VIEW_ALL_MSG:"Only Selected {0} are Visible",VIEW_ALL_LINK:"Remove This Filter",ITEMS:"Items",ITEM:"Item",SELECTED:"Selected",SELECT_ALL:"Select/Clear All",ALL_ITEMS_SELECTED:"All {0} Selected",SELECT_ALL_ITEMS:"Select All {0} {1}"};
var _32d="TD.actionCol input[type=checkbox], TD.actionCol input[type=radio]";
var _32e=function(_32f,_330){
var _331=$("input.listAction",_32f.container).val(_330);
if(_331.length==1){
_331[0].form.submit();
}
};
var list=function(_333){
this.containerId=_333;
this.searchPanel=null;
this.container=(typeof _333=="string")?$("#"+_333):_333;
this.actionRowTop=$("DIV.actionRow",this.container);
this.actionRowBottom=$("DIV.actionRowBottom",this.container);
this.submitType=_32b.SUBMIT_TYPE;
this.hasRadios=false;
this.buttonsTop=[];
this.buttonsBottom=[];
this.currentSelectedItem=null;
this.selectedItems=[];
this.disabledBtnArray=[];
this.disabledButtons=[];
this.selectedItemsValues=[];
this.persistedSelectionCount=0;
this.paddedList="";
this.persistedSelections="";
this.init();
};
list.prototype={init:function(){
this.initPaging();
this.initCheckboxes(true);
this.initSelectAll();
this.initButtons();
this.initSearchPanel();
this.refreshState(true);
this.initSelectionCounter();
this.initSortableColumns();
this.initTabs();
},initCheckboxes:function(init){
var _335=this;
if(init){
this.items=$(_32d,this.container).click(function(){
_335.toggle(this);
}).addClass("initalized");
}else{
$("TD.actionCol input[type=checkbox]:not(.initalized), TD.actionCol input[type=radio]:not(.initalized)",this.container).click(function(){
_335.toggle(this);
}).addClass("initalized");
this.items=$(_32d,this.container);
}
this.hasRadios=(this.items.filter(":radio:first").length>0)?true:false;
},initTabs:function(){
var _336=$(".listTabsContent",this.container);
var _337=$(".listTabs",this.container);
var _338=this;
$(".search",_337).click(function(){
_338.toggleTab("search");
return false;
});
$(".columns",_337).click(function(){
_338.toggleTab("columns");
return false;
});
this.listTabsContent=_336;
this.listTabs=_337;
if($(".searchExpanded",this.container).val()=="true"&&!$(".listTabsContent",this.container).is(":visible")){
$(".search",_337).removeClass("selected");
_338.toggleTab("search");
}
},toggleTab:function(id){
var _33a=this.listTabsContent;
var _33b=this.listTabs;
var _33c=$(".search",_33b);
var _33d=$(".columns",_33b);
var _33e=(_33c.hasClass("selected"))?"search":(_33d.hasClass("selected"))?"columns":null;
$("div",_33b).removeClass("selected");
var _33f=$(".searchExpanded",this.container);
if(_33e==id){
_33a.hide();
_33f.val("false");
}else{
_33a.show();
$("."+id,_33b).addClass("selected");
$("."+id,_33a).show();
_33e=(id=="search")?"columns":"search";
if(id=="search"){
_33f.val("true");
}else{
_33f.val("false");
}
$("."+_33e,_33a).hide();
var _340=$("."+id+" :input",_33a).filter("input[type=text], textarea, select");
if(_340.length>0){
_340[0].focus();
}
}
},initSelectAll:function(){
var _341=this;
$("thead th.actionCol:first",this.container).html("<input title=\""+_32c.SELECT_ALL+"\" type=\"checkbox\" class=\"selectAll\" />");
this.selectAllCheckbox=$("INPUT.selectAll",this.container).click(function(){
_341.toggleSelectAll();
}).get(0);
if(this.hasRadios){
$(this.selectAllCheckbox).hide().insertAfter("<span>&nbsp;</span>");
}
},initButtons:function(){
var _342=(this.actionRowTop)?this.actionRowTop:this.actionRowBottom;
var _343=this;
if(_342){
var _344=$("BUTTON.single,BUTTON.multiple",this.actionRowBottom);
var _345=$("BUTTON.single,BUTTON.multiple",_342).each(function(i){
var btn=$(this);
var _348="_single";
var _349=btn.hasClass("single");
var _34a=btn.hasClass("multiple");
if(_349||_34a){
_343.buttonsTop[_343.buttonsTop.length]={buttonObj:this,name:this.name,isSingle:_349,isMultiple:_34a};
if(_344.length>0){
_343.buttonsBottom[_343.buttonsBottom.length]={buttonObj:_344[i],name:_344[i].name,isSingle:_349,isMultiple:_34a};
}
}
});
}
$("UL.buttons BUTTON[name]",this.container).not("[onclick]").click(function(){
var _34b=$(this);
var name=_34b.attr("name");
var _34d=$(this).attr("data-confirm-action");
if(_34d){
var func=function(ok){
if(ok){
_343.submitActionButton(_34b[0],name);
}
};
$.dr.confirm(_34d,func);
}else{
_343.submitActionButton(this,name);
}
});
},submitActionButton:function(btn,_351){
btn=(typeof btn=="String")?document.getElementById(btn):btn;
_351=(_351)?_351:btn.name;
_32e(this,_351);
},initSortableColumns:function(){
var _352=$("TABLE.clientSideSort:first",this.container);
var _353=$("TABLE THEAD A",this.container).each(function(){
$(this).attr("title",_32c.SORT_BY.replace("{0}",$(this).text()));
});
if(_352.length>0||this.totalPages==1){
if(typeof $.fn.tablesorter=="function"){
if(_352.length==0){
_352=$("TABLE.dataTable",this.container);
}
var _354=0;
var _355=0;
var _356=($("TABLE THEAD TH.actionCol",this.container).length>0)?1:0;
$("TABLE THEAD TH",this.container).not("TH.actionCol").each(function(_357){
var td=$(this);
if(td.hasClass("ascending")){
_354=_357+_356;
}else{
if(td.hasClass("descending")){
_354=_357+_356;
_355=1;
}
}
});
var _359={sortList:[[_354,_355]]};
if(_356){
_359.headers={0:{sorter:false}};
}
_352.tablesorter(_359);
}
}else{
var _35a=this;
_353.click(function(){
var _35b=$(this).attr("data-sort-column");
_35a.changeSortColumn(this,_35b);
return false;
});
}
},initSelectionCounter:function(){
this.persistedSelections=$(".persistedSelections",this.container);
var _35c=$(".itemCount",this.container);
this.allSelected=false;
if(this.persistedSelections.length>0&&_35c.length){
this.submitType="post";
var val=this.persistedSelections.val();
if(val=="all"){
this.allSelected=true;
this.persistedSelectionCount=this.totalItems-this.items.length;
}else{
var _35e=val.replace(/,\s/g,",");
var _35f=","+_35e+",";
this.items.each(function(){
var _360=new RegExp(","+this.value+",");
if(_360.test(_35f)){
_35f=_35f.replace(_360,",");
}
});
var _361="";
var _362=_35f.length;
if(_362>2){
_361=_35f.substring(1,_35f.length-1);
}
$(".persistedSelections",_35c).val(_361);
this.persistedSelectionCount=(_361.length==0)?0:_361.split(",").length;
}
var _363=$(".itemType",_35c);
this.itemType=(_363.length>0)?_363.val():_32c.ITEMS;
this.viewingOnlySelections=($(".viewingOnlySelections",_35c).val()=="true")?true:false;
var _364=$(".itemTypeSingular",_35c);
this.itemTypeSingular=(_364.length>0)?_364.val():_32c.ITEM;
var _365=$(".allSelectedMessage",_35c).val();
if(!_365){
_365=_32c.ALL_ITEMS_SELECTED.replace("{0}",this.itemType);
}
var _366=$(".viewingOnlySelectionsMessage",_35c).val();
if(!_366){
_366=_32c.VIEW_ALL_MSG.replace("{0}",this.itemType);
}
var _367=$(".viewingOnlySelectionsLink",_35c).val();
if(!_367){
_367=_32c.VIEW_ALL_LINK;
}
var _368=_32c.SELECT_ALL_ITEMS.replace("{0}","<strong>"+this.totalItems+"</strong>").replace("{1}",this.itemType);
var _369=_32c.VIEW_ALL_MSG.replace("{0}",this.itemType);
var s=[];
s.push("<table cellpadding=\"0\" cellspacing=\"0\" border=\"0\"><tr>");
s.push("<td class=\"count\">"+this.persistedSelectionCount+this.selectedItems.length+"</td>");
s.push("<td class=\"itemLabel\">"+this.itemType+"</td>");
s.push("<td>");
s.push("<div class=\"selectAll\" style=\"display:none\"><span class=\"link\">"+_368+"</span></div>");
s.push("<div class=\"selected\" style=\"display:none\"><span class=\"msg\">"+_365+"</span></div>");
s.push("</td>");
if(this.viewingOnlySelections){
s.push("<td><div class=\"selectedFilter\" ><span class=\"msg\">"+_366+" &nbsp;  | &nbsp; <span class=\"msgLink\">"+_367+"</span></span></div></td>");
}else{
s.push("<td class=\"view\"><span class=\"link\">"+_32c.VIEW_SELECTIONS+"</span></td>");
}
s.push("<td class=\"clear\"><span class=\"link\">"+_32c.CLEAR_SELECTIONS+"</span></td>");
s.push("</tr></table>");
_35c.append(s.join(""));
this.itemLabel=$(".itemLabel",_35c);
if(this.persistedSelectionCount>0){
$(".clear, .view",_35c).show();
}else{
$(".clear, .view",_35c).hide();
}
this.refreshSelectionCount();
var _36b=this;
$(".selectAll .link",_35c).click(function(){
var _36c=_32b.SELECT_ALL_RESULTS;
if(_36b.totalPages==1){
_36c=_36b.persistedSelections;
}
$(".persistedSelections",_35c).val(_36c);
$(".clear, .selected",_35c).show();
$(".selectAll, .view",_35c).hide();
$(".count",_35c).text(_36b.totalItems);
});
$(".clear .link",_35c).click(function(){
_36b.selectAllCheckbox.checked=false;
_36b.toggleSelectAll();
_36b.persistedSelectionCount=0;
$(".persistedSelections",_35c).val("");
$(".count",_35c).text(0);
$("div, .selected, .clear, .view, .selectAll",_35c).hide();
if(_36b.viewingOnlySelections){
_32e(_36b,"viewAll");
}
});
if(this.allSelected){
$(".selected",_35c).show();
}
$(".view .link",_35c).click(function(){
_32e(_36b,"viewSelections");
});
$(".msgLink",_35c).click(function(){
_32e(_36b,"viewAll");
});
}
},refreshSelectionCount:function(){
var _36d=this.persistedSelectionCount+this.selectedItems.length;
$(".itemCount .count",this.container).text(_36d);
if(this.itemLabel){
var _36e=this.itemType;
if(_36d==1){
_36e=this.itemTypeSingular;
}
this.itemLabel.text(_36e+" "+_32c.SELECTED);
}
var view=$(".itemCount .view",this.container);
if(_36d==0||$(".persistedSelections",this.container).val()==_32b.SELECT_ALL_RESULTS){
view.hide();
}else{
view.show();
}
},toggleSelectAllMsg:function(_370){
if(_32b.SELECT_ALL_ACROSS_PAGES_ENABLED){
var _371=$(".itemCount",this.container);
if(_370){
if(!this.viewingOnlySelections){
$(".selectAll").show();
$(".selected",_371).hide();
}
}else{
if(this.allSelected){
this.persistedSelectionCount==0;
this.allSelected=false;
$(".count",_371).text(0);
}
if(this.persistedSelectionCount==0){
$(".clear",_371).hide();
}
$("div:not(.selectedFilter)",_371).hide();
if($(".persistedSelections",this.container).val()==_32b.SELECT_ALL_RESULTS){
$(".persistedSelections",this.container).val("");
this.persistedSelectionCount=0;
}
}
}
},initSearchPanel:function(){
},refreshState:function(init){
this.disabledBtnArray=[];
this.disabledButtons=[];
this.disabledButtonNameArray=[];
var _373=this;
this.selectedItems=this.items.filter(":checked").each(function(){
if(typeof this.onclick=="function"){
this.onclick();
}
_373.updateDisabledButtons(this,true,false);
if(init){
_373.highlightRow(this);
}
});
this.refreshButtonState();
this.refreshSelectAllState(false);
},updateDisabledButtons:function(item,add,_376){
var _377=item.getAttribute("data-disabled-buttons");
if(_377!==undefined&&_377!==null){
var _377=_377.trim().split(" ");
for(var i=0;i<_377.length;i++){
var _379=_377[i];
var _37a=0;
var _37b=this.disabledButtons[_379];
if(_37b!==undefined){
if(_376&&!add){
_37a=_37b-1;
}else{
_37a=_37b+1;
}
}else{
if(add){
_37a=1;
}
}
this.disabledButtons[_379]=_37a;
}
}
},refreshButtonState:function(){
for(var j=0;j<this.buttonsTop.length;j++){
var btn=this.buttonsTop[j];
var _37e=(this.selectedItems.length==0)?true:false;
if(this.disabledButtons[btn.name]!==undefined){
if(this.disabledButtons[btn.name]>0){
_37e=true;
}
}
if(!_37e){
if(this.selectedItems.length>=2&&btn.isSingle){
_37e=true;
}
}
btn.buttonObj.disabled=_37e;
if(this.buttonsBottom.length>0){
this.buttonsBottom[j].buttonObj.disabled=_37e;
}
}
},refreshSelectAllState:function(_37f){
if(this.selectAllCheckbox){
if(!this.selectAllCheckbox.disabled){
this.selectAllCheckbox.checked=(this.selectedItems.length==this.items.length)?true:false;
}
}
if(!_37f){
this.refreshSelectionCount();
}
},toggle:function(item){
if(item.type=="radio"){
if(this.currentSelectedItem!=item&&this.currentSelectedItem!==null){
this.highlightRow(this.currentSelectedItem);
}
this.currentSelectedItem=item;
}else{
if(!item.checked){
this.toggleSelectAllMsg(false);
}
}
this.highlightRow(item);
this.refreshSelectionCount();
this.selectedItems=this.items.filter(":checked");
this.updateDisabledButtons(item,item.checked,true);
this.refreshButtonState();
this.refreshSelectAllState(false);
},toggleSelectAll:function(){
var _381=this.items;
var _382=(this.selectAllCheckbox.checked)?true:false;
this.items.attr("checked",_382);
this.tableRows=$("TABLE.dataTable > TBODY > TR",this.container);
if(_382){
this.tableRows.addClass("selected");
}else{
this.tableRows.removeClass("selected");
}
this.refreshState();
this.toggleSelectAllMsg(_382);
},highlightRow:function(obj){
var _384=(obj.checked)?true:false;
var row=obj.parentNode.parentNode;
if(_384){
$(row).addClass("selected");
}else{
$(row).removeClass("selected");
}
},changeSortColumn:function(obj,_387){
var _388="ascending";
var _389=$(obj).attr("data-default-sort-direction");
if(_389){
if(_389.indexOf("desc")>-1||_389.indexOf("descending")>-1){
_388="descending";
}
}
var _38a=_388;
if($(obj.parentNode).hasClass("ascending")||$(obj.parentNode).hasClass("descending")){
var _38b=$(obj.parentNode).hasClass("descending")?"descending":"ascending";
_38a=(_38b=="ascending")?"descending":"ascending";
}
if(this.sortColumn.length>0&&this.sortColumn.length>0){
if(DR.Widgets.Button!==undefined){
DR.Widgets.Button.disableSearchButton=function(){
};
}
this.sortColumn.val(_387);
this.sortDirection.val(_38a);
this.changePage(1,false,null);
}else{
if(console){
console.log("sortColumn and/or  sortDirection not found");
}
}
},initPaging:function(){
this.controls=$(".pagination",this.container);
this.itemCountContainers=$(".items",this.container);
this.refreshItemCount();
var _38c=this;
$("A",this.controls).click(function(){
_38c.handlePagerClick(this);
return false;
});
this.pageInputs=$("INPUT.currentPage",this.controls);
this.pageInputs.val(this.originalPageValue);
this.pageInputs.keypress(function(evt){
_38c.doEnterPush(evt,this);
});
this.pageUrl=$(".pageUrl",this.container);
this.searchFilters=$(".searchFilters",this.container);
this.sortColumn=$(".sortColumn",this.container);
this.sortDirection=$(".sortDirection",this.container);
this.resetPagerState();
},refreshItemCount:function(){
this.originalPage=$(".originalPage",this.container);
this.originalPageValue=parseInt(this.originalPage.val(),10);
this.currentPage=this.originalPageValue;
this.totalPages=parseInt($("input.totalPages",this.container).val(),10);
this.totalItems=$(".totalItems",this.container).val();
this.firstItem=$(".firstItemOnPage",this.container).val();
this.lastItem=$(".lastItemOnPage",this.container).val();
$(".totalItems",this.itemCountContainers).text(this.totalItems);
$(".firstItem",this.itemCountContainers).text(this.firstItem);
$(".lastItem",this.itemCountContainers).text(this.lastItem);
this.itemCountContainers.css("visibility","visible");
},handlePagerClick:function(link){
link=$(link);
if(link.hasClass("off")){
return;
}else{
if(link.hasClass("first")){
this.changePage(1);
}else{
if(link.hasClass("prev")){
this.changePage(this.originalPageValue-1);
}else{
if(link.hasClass("next")){
this.changePage(this.originalPageValue+1);
}else{
if(link.hasClass("last")){
this.changePage(this.totalPages);
}
}
}
}
}
},resetPagerState:function(){
var _38f=this.totalPages;
var _390=this.currentPage;
$(".totalPages",this.controls).text(_38f);
var _391=false;
if(_38f==1){
_391=true;
$("A",this.controls).addClass("off");
}else{
if(_390==1){
$("A.first, A.prev",this.controls).addClass("off");
$("A.next, A.last",this.controls).removeClass("off");
}else{
if(this.currentPage==_38f){
$("A.first, A.prev",this.controls).removeClass("off");
$("A.next, A.last",this.controls).addClass("off");
}else{
$("A",this.controls).removeClass("off");
}
}
}
if(_391){
this.pageInputs.attr("disabled","disabled");
}else{
this.pageInputs.removeAttr("disabled");
}
},doEnterPush:function(evt,el){
var key=(evt.which)?evt.which:event.keyCode;
if(key==13){
var _395=el.value;
if(isNaN(_395)||_395<0){
alert(_32c.INVALID_NUMBER);
el.select();
if(evt.preventDefault){
evt.preventDefault();
}else{
if(window.event){
window.event.cancelBubble=true;
window.event.returnValue=false;
}
}
return false;
}else{
if(_395>this.totalPages){
_395=this.totalPages;
}else{
if(parseInt(_395,10)===0){
_395=1;
}
}
this.changePage(_395,true,evt);
}
}
},changePage:function(_396,_397,evt){
this.currentPage=_396;
if(_32b.PAGES_START_AT_ZERO){
_396--;
}
if(typeof _32b.PAGING_OVERRIDE=="function"){
_32b.PAGING_OVERRIDE(this.container,_396);
}else{
if(this.submitType.toLowerCase()=="post"){
var _399=$(".currentPage");
_399.val(_396);
_399[0].form.submit();
}else{
var url="";
url+=this.pageUrl.val()+"?";
url+=this.searchFilters.val();
url+="&"+this.sortColumn[0].name+"="+this.sortColumn.val();
url+="&"+this.sortDirection[0].name+"="+this.sortDirection.val();
url+="&page="+_396;
window.location=url;
}
}
if(_397){
if(evt.preventDefault){
evt.preventDefault();
}else{
if(window.event){
window.event.cancelBubble=true;
window.event.returnValue=false;
}
}
return false;
}
}};
$.dr.list={getMessages:function(){
return _32c;
},getDefaults:function(){
return _32b;
},setDefaults:function(_39b){
if(_39b){
$.extend(_32b,_39b);
}
$(document).trigger("afterListSetDefaults",[_39b]);
},setMessages:function(_39c){
if(_39c){
$.extend(_32c,_39c);
}
$(document).trigger("afterListSetMessages",[_39c]);
}};
var _39d=function(evt,_39f){
var _3a0=$("DIV.listControl",_39f).each(function(_3a1){
var _3a2=$("TABLE.dataTable",this);
if(_3a2.length>0){
var id=this.getAttribute("id");
if(!id){
id="list_"+_3a1+"_"+new Date().getTime();
this.id=id;
}
$(this).data("list",new list(id));
}
});
};
$.dr.addUnobtrusiveEvent(_39d);
$.namespace("dr",{list:function(){
return this.each(function(){
var _3a4=this;
if(this.tagName!="body"){
_3a4=this.parentNode;
}
_39d(null,_3a4);
});
}});
$.namespace("dr.list",{refreshState:function(){
return this.each(function(){
var _3a5=$(this).data("list");
if(_3a5){
_3a5.refreshItemCount();
_3a5.resetPagerState();
_3a5.initCheckboxes(false);
_3a5.refreshState();
}
});
}});
})(jQuery);
DR.Utils.Logger=function(id){
this.id=id;
this.items=null;
this.inited=false;
this.disabled=false;
};
DR.Utils.Logger.prototype={init:function(str){
if(this.overlay===undefined){
var _3a8=document.getElementById(DR.CONTENT_AREA_ID);
if(!_3a8){
_3a8=document.getElementsByTagName("BODY")[0];
}
var d=document.createElement("div");
d.id=this.id+"_logger";
var c=document.createElement("div");
c.className="modalScrollerMediumHeight";
c.style.width="300px";
c.style.height="300px";
this.overlayContent=c;
var b=document.createElement("div");
b.className="pageButtons";
b.innerHTML="<button onclick=\""+this.id+".clear();\" >Clear</button><button onclick=\"overlayStack.hideCurrent();\" style=\"margin-right:0;\">Close</button>";
d.appendChild(c);
d.appendChild(b);
_3a8.appendChild(d);
this.overlay=new DR.Widgets.InlineModelessOverlay(this.id+"_logger");
this.overlay.setTitle("Logger");
this.overlay.setSize(350,350);
this.overlay.show();
this.inited=true;
}
},hide:function(str){
if(this.inited){
overlayStack.hideCurrent();
}
},clear:function(str){
if(this.inited){
this.items=null;
this.overlayContent.innerHTML="";
}
},disable:function(){
this.disabled=true;
},log:function(str,_3af){
if(this.disabled){
return;
}
if(!this.inited){
this.init();
overlayStack.disableCurrent();
}
str=str+"";
if(this.items===null){
this.items=[str];
}else{
this.items.push(str);
}
if(_3af!==false){
this.refresh();
}
},refresh:function(str){
var h="<table cellpadding=\"0\" cellspacing=\"0\" class=\"dataTable\" style=\"border:1px solid #666;\">";
h+="<thead><th style=\"width:20px;\">ID</th><th>Value</th></thead>";
h+="<tbody>";
var _3b2=this.items;
for(var i=0;i<_3b2.length;i++){
h+="<tr><td>"+(i+1)+"</td><td>"+_3b2[i]+"</td></tr>";
}
h+="</tbody></table>";
this.overlayContent.innerHTML=h;
this.refreshScroll();
var _3b4=this;
var func=function(){
_3b4.refreshScroll();
};
window.setTimeout(func,1000);
},refreshScroll:function(str){
this.overlayContent.scrollTop=parseInt(this.overlayContent.offsetHeight,10);
}};
var DR_Utils_Logger=new DR.Utils.Logger("DR_Utils_Logger");
function log(_3b7){
DR_Utils_Logger.log(_3b7);
}
DR.Widgets.ModelessOverlay=function(id,url,_3ba){
this.id=id;
this.parentId=-1;
this.parentWindowIndex=-1;
this.url=url;
this.stackID="";
this.title="&nbsp;";
this.built=false;
this.isOpen=false;
this.hasFocus=false;
this.hasChildren=false;
this.hasModalChildren=false;
this.blurWindow=false;
this.isInStack=false;
this.modalMaskBuilt=false;
this.modelessMaskBuilt=false;
this.loading=false;
this.cancelFunction="";
this.callBackFunction="";
this.abortFunction="";
this.modalType="Modeless";
this.inline=false;
this.titleBarHeight=28;
this.borderWidth=2;
this.inlineDialogPadding=10;
this.shadowRight=36;
this.shadowBottom=36;
this.contentWidth=580;
this.contentHeight=520;
this.waitToLoadIframe=true;
this.ieTimeout=false;
this.enableDragging=true;
this.dragObject=null;
this.autoCenter=true;
this.enableSelfPositioning=false;
this.enableAutoSizing=false;
this.scrollBarsHidden=false;
this.width=this.contentWidth+this.shadowRight+(this.borderWidth*2);
this.height=this.contentHeight+this.shadowBottom+this.titleBarHeight+(this.borderWidth*2);
this.optionalClassName=(_3ba)?_3ba:null;
};
DR.Widgets.ModelessOverlay.prototype={show:function(){
this.checkBrowser();
if(window!=top&&!this.inline){
this.addToStack();
parent.overlayStack.addChildWindow(this,overlayStack.currentWindow);
}else{
if(!this.built){
this.addToStack();
this.build();
}
if(!this.modalMaskBuilt){
this.buildModalMask();
}
if(this.modalType=="Modal"){
this.modalMask.style.display="block";
this.modalMaskIEOver.style.display="block";
this.modalMask.className="modalOverlayMask";
}
if(this.modalType=="Modeless"){
this.modalMask.className="modelessOverlayMask";
}
this.isOpen=true;
this.position();
var func=function(){
overlayStack.getCurrent().center(false);
};
window.setTimeout(func,10);
this.focus();
this.refreshMaskSize();
this.refreshSize();
this.dialog.style.display="block";
this.showLoading();
this.hideDocScrollBars();
this.center();
if(!this.inline){
if(this.waitToLoadIframe){
var _3bc=function(){
overlayStack.buildIframe();
};
window.setTimeout(_3bc,50);
this.ieTimeout=true;
}else{
this.buildIframe();
}
if(this.modalType=="Modal"){
this.addEvent(document,"keypress",DR.Utils.suppressKeypress,1);
}
}
}
},position:function(){
if(!this.enableSelfPositioning){
if(this.anchorId){
this.setPositionTo();
}else{
this.center();
}
}
},setPositionTo:function(){
var _3bd=new DR.Utils.Position(this.dialog);
this.dialog.style.position="absolute";
_3bd.setRelativePosition(this.anchorId,DR.Utils.Position.ON_LEFT,DR.Utils.Position.DRAW_RIGHT,DR.Utils.Position.ON_TOP,DR.Utils.Position.DRAW_DOWN,(0-this.shadowRight/2),0,false);
},center:function(_3be){
if(!this.anchorId){
var w=this.width;
var h=this.height;
overlayStack.getPageSize();
var x,y;
var _3c2=0;
var _3c3=0;
var _3c4=0;
var _3c5=(DR.Utils.BrowserDetect.browser=="Explorer"&&DR.Utils.BrowserDetect.version<7)?true:false;
if(document.documentElement){
if(_3c5){
if($("body.modalPage").length==0&&!_3be){
_3c2=18;
_3c3=1;
_3c4=9;
}
x=document.documentElement.scrollLeft+document.body.scrollLeft;
y=document.documentElement.scrollTop+document.body.scrollTop;
}
}
if(this.autoCenter||(!this.autoCenter&&!_3be)){
if(_3c5){
this.dialog.style.left=(x+(overlayStack.doc.windowWidth/2)-((w-_3c2)/2+_3c3))+"px";
this.dialog.style.top=(y+(overlayStack.doc.windowHeight/2)-((h-_3c2)/2+_3c4))+"px";
}else{
this.dialog.style.left=Math.round(overlayStack.doc.windowWidth/2-w/2)+"px";
this.dialog.style.top=Math.round(overlayStack.doc.windowHeight/2-h/2)+"px";
}
}
}
},refreshMaskSize:function(){
overlayStack.refreshMaskSize();
},addToStack:function(){
if(!this.isInStack){
this.stackId=overlayStack.add(this);
this.isInStack=true;
}
},checkBrowser:function(){
if(document.all){
this.browserType="IE";
this.filtersSupported=true;
this.iframeTransparency=true;
this.waitToLoadIframe=true;
}else{
this.broswerType="Standard";
this.filtersSupported=false;
this.iframeTransparency=false;
this.waitToLoadIframe=false;
}
this.isIE7=(navigator.appVersion.indexOf("MSIE 7")>-1);
},focus:function(){
if(overlayStack.checkAnyOpen()&&this.isOpen){
if(!this.hasChildren&&!this.hasModalChildren){
overlayStack.bringToFront(this.stackId);
}else{
if(this.hasChildren){
window.frames[this.iframe.id].overlayStack.focusCurrent(false);
}
}
if(window!=top){
parent.overlayStack.setCurrentHasChildren(true);
parent.overlayStack.blurCurrent();
}
overlayStack.blurOtherWindows();
}else{
if(window!=top){
parent.overlayStack.focusCurrent(true);
}
}
this.hasFocus=true;
this.isBlurred=false;
},blur:function(){
DR.Utils.addCSSClass(this.contentTable,"inActive");
if(this.hasChildren&&this.blurWindow){
this.blurWindow=false;
window.frames[this.iframe.id].overlayStack.blurCurrent();
}
this.isBlurred=true;
},cancel:function(){
if(typeof this.cancelFunction=="function"){
this.cancelFunction();
}
this.close();
},setCancelFunction:function(func){
if(typeof func=="function"){
this.cancelFunction=func;
}
},setCallBackFunction:function(func){
if(typeof func=="function"){
this.callBackFunction=func;
}
},setAbortFunction:function(func){
if(typeof func=="function"||func===null){
this.abortFunction=func;
}
},callBack:function(arg1,arg2,arg3,arg4,arg5,arg6,arg7,arg8,arg9,_3d2){
if(typeof this.callBackFunction=="function"){
this.callBackFunction(arg1,arg2,arg3,arg3,arg4,arg5,arg6,arg7,arg8,arg9,_3d2);
}
},close:function(){
if(typeof this.abortFunction=="function"){
this.abortFunction();
}else{
this.isOpen=false;
this.hasFocus=false;
this.dialog.style.display="none";
overlayStack.setCurrentWindow(this.stackId);
if(!overlayStack.checkAnyModalOpen()){
if(this.modalType=="Modal"){
this.modalMask.style.display="none";
this.modalMaskIEOver.style.display="none";
this.enableScrollBars();
}
}
if(!overlayStack.checkAnyModelessOpen()||!overlayStack.checkAnyModelessOpen()){
if(window!=top){
parent.overlayStack.setCurrentHasChildren(false);
parent.overlayStack.focusCurrent(true);
}
}
if(!this.inline){
if(this.parentId>-1&&this.parentWindowIndex>-1){
window.frames[overlayStack.windows[this.parentId].iframe.id].overlayStack.destroyWindow(this.parentWindowIndex);
}
overlayStack.setCurrentHasModalChildren(false);
overlayStack.destroyCurrent();
if(this.modalType=="Modal"){
this.removeEvent(document,"keypress",DR.Utils.suppressKeypress,1);
}
}
}
},hideDocScrollBars:function(){
if(this.modalType=="Modal"){
if(this.browserType=="IE"&&DR.Utils.BrowserDetect.version<7){
var a=document.getElementsByTagName("html")[0];
a.style.overflow="hidden";
this.scrollBarsHidden=true;
}else{
}
}
},enableScrollBars:function(){
if(!overlayStack.checkAnyModalOpen()&&this.modalType=="Modal"){
if(this.browserType=="IE"){
var a=document.getElementsByTagName("html")[0];
a.style.overflow="auto";
this.scrollBarsHidden=false;
}else{
}
}
},hideLoading:function(){
if(!this.inline&&!this.ieTimeout&&this.iframeSpacer){
this.iframeSpacer.style.display="none";
this.iframe.style.display="block";
this.iframe.style.visibility="visible";
this.loading=false;
if(document.addEventListener){
}
overlayStack.setCurrentHasChildren(false);
}
},showLoading:function(){
if(!this.inline){
this.iframeSpacer.style.display="block";
if(this.iframe){
this.iframe.style.display="none";
this.iframe.style.visibility="hidden";
}
this.loading=true;
}
},buildModalMask:function(){
if(document.getElementById("modalMask")===null){
var d=document.createElement("div");
d.id="modalMask";
d.className="modalOverlayMask";
var f=document.createElement("IFRAME");
f.className="modalOverlayMaskIframe";
f.id="modalOverlayMaskIframe";
f.src=DR.BLANK_PAGE_URL;
d.appendChild(f);
var dd=document.createElement("div");
dd.className="modalOverlayMaskDiv";
dd.id="modalOverlayMaskDiv";
this.modalMaskIframe=f;
this.modalMaskIEOver=DR.Utils.addToBody(dd);
this.modalMask=DR.Utils.addToBody(d);
f=null;
dd=null;
d=null;
}else{
this.modalMask=document.getElementById("modalMask");
this.modalMaskIframe=document.getElementById("modalOverlayMaskIframe");
this.modalMaskIEOver=document.getElementById("modalOverlayMaskDiv");
}
this.modalMaskBuilt=true;
},buildModelessMask:function(){
if(!document.body.modelessMask){
var d=document.createElement("div");
d.id="modelessMask";
d.className="modelessOverlayMask";
this.modelessMask=DR.Utils.addToBody(d);
d=null;
}
this.modelessMaskBuilt=true;
},build:function(){
var _3d9=document.getElementsByTagName("BODY")[0];
var _3da=document.createElement("div");
_3da.id="modal_"+this.id;
_3da.className="modalOverlay";
var _3db=this;
var ie6=false;
var _3dd=" colspan=\"2\"  rowspan=\"2\"";
if(DR.Utils.BrowserDetect.browser=="Explorer"&&DR.Utils.BrowserDetect.version<7){
ie6=true;
_3dd="";
this.shadowRight=8;
this.shadowBottom=8;
}
var s=[];
var _3df="";
if(this.optionalClassName!=null){
_3df="class=\""+this.optionalClassName+"\"";
}
var _3e0="";
if(this.disabled){
_3e0="style=\"display:none\"";
}
if(this.modalType=="Modeless"){
s[s.length]="<div class=\"modalWrapper\" id=\"{0}_modalWrapper\">";
s[s.length]="<div class=\"divFloat\" id=\"{0}_divFloat\">";
}
s[s.length]="<div id=\"{0}_contentTable\" "+_3df+" >";
s[s.length]="<table border=\"0\" cellpadding=\"0\" cellspacing=\"0\" class=\"wrapperTbl\">";
if(!ie6){
s[s.length]="<tr><td colspan=\"2\" class=\"topLeft\">&nbsp;</td><td colspan=\"2\" class=\"topRight\">&nbsp;</td></tr>";
s[s.length]="<tr><td class=\"leftTop\">&nbsp;</td>";
}else{
s[s.length]="<tr>";
}
s[s.length]="<td "+_3dd+" id=\"{0}_content\" >";
s[s.length]="<div class=\"inner\" id=\"{0}_inner\" >";
s[s.length]="<table border=\"0\" cellpadding=\"0\" cellspacing=\"0\" class=\"titleBar\" id=\"{0}_titleTbl\">";
s[s.length]="<tr>";
s[s.length]="<td class=\"title\" ><div id=\"{0}_title\">"+this.title+"</div></td>";
s[s.length]="<td class=\"close\" "+_3e0+" title=\""+DR.Widgets.ModalOverlay.CLOSE_WINDOW+"\"><a href=\"#\" onmousedown=\"if (window.event){window.event.cancelBubble = true;}else{event.preventDefault();event.stopPropagation();}\" id=\"{0}_closeLink\" ></a></td>";
s[s.length]="</tr>";
s[s.length]="</table>";
if(!this.inline){
s[s.length]="<div id=\"{0}_iframeSpacer\" >";
s[s.length]="<div class=\"modalLoading\" id=\"{0}_loadingDiv\" >";
s[s.length]="<div class=\"modalLoadingTextWrapper\" id=\"{0}_loadingTextWrapper\" >";
s[s.length]="<div class=\"modalLoadingText\">"+DR.Widgets.ModalOverlay.LOADING_WINDOW+"</div>";
s[s.length]="<div class=\"modalLoadingImg\"></div>";
s[s.length]="</div>";
s[s.length]="</div>";
s[s.length]="</div>";
}
s[s.length]="</div>";
s[s.length]="</td>";
s[s.length]="<td class=\"rightTop\">&nbsp;</td></tr>";
if(!ie6){
s[s.length]="<tr><td class=\"leftBottom\">&nbsp;</td><td class=\"rightBottom\">&nbsp;</td></tr>";
s[s.length]="<tr><td colspan=\"2\" class=\"bottomLeft\">&nbsp;</td><td colspan=\"2\" class=\"bottomRight\">&nbsp;</td></tr>";
}else{
s[s.length]="<tr><td class=\"bottomLeft\">&nbsp;</td><td class=\"bottomRight\">&nbsp;</td></tr>";
}
s[s.length]="</table>";
s[s.length]="</div>";
if(this.modalType=="Modeless"){
s[s.length]="</div>";
s[s.length]="<iframe  src=\""+DR.BLANK_PAGE_URL+"\" class=\"modelessOverlayMaskIframe\" id=\"{0}_modelessOverlayMaskIframe\" ></iframe>";
s[s.length]="</div>";
}
s=s.join("");
s=s.replace(/\{0\}/g,this.id);
_3da.innerHTML=s;
if(this.inline){
var _3e1=document.getElementById(this.inlineId);
_3e1.style.display="block";
dParent=_3e1.parentNode;
this.dialog=dParent.insertBefore(_3da,_3e1);
var _3e2=document.createElement("div");
_3e2.className="inlineDialog";
getElem(this.id+"_inner").appendChild(_3e2);
this.dialogClone=_3e2;
_3e2.appendChild(_3e1);
}else{
this.dialog=_3d9.appendChild(_3da);
this.iframeWrapper=getElem(this.id+"_inner");
this.iframeSpacer=getElem(this.id+"_iframeSpacer");
this.loadingDiv=getElem(this.id+"_loadingDiv");
this.loadingTextWrapper=getElem(this.id+"_loadingTextWrapper");
}
if(this.modalType=="Modeless"){
this.modelessMaskingDiv=getElem(this.id+"_divFloat");
this.modelessMaskingIframe=getElem(this.id+"_modelessOverlayMaskIframe");
}
this.windowIcon=getElem(this.id+"_title");
this.contentTable=getElem(this.id+"_contentTable");
this.closeLink=getElem(this.id+"_closeLink");
getElem(this.id+"_closeLink").onclick=function(){
_3db.cancel();
return false;
};
function myDialogInitDrag(_3e3){
_3db.initDrag(_3e3);
}
if(this.enableDragging){
getElem(this.id+"_titleTbl").onmousedown=myDialogInitDrag;
}
overlayStack.addWindowEventHandlers();
function eventMyDialogFocus(_3e4){
_3db.focus();
}
_3da.onclick=eventMyDialogFocus;
s=null;
function cleanupIE_Events(){
_3da.detachEvent("onclick",eventMyDialogFocus);
overlayStack.destroyAll();
window.detachEvent("onunload",cleanupIE_Events);
}
if(this.browserType=="IE"){
window.attachEvent("onunload",cleanupIE_Events);
}else{
_3da=null;
}
this.built=true;
},buildIframe:function(){
this.iframeCountID=overlayStack.getNewIframeID();
var _3e5=document.createElement("IFRAME");
_3e5.id="modal_iframe_"+this.iframeCountID;
_3e5.name="modal_iframe_"+this.iframeCountID;
_3e5.frameBorder=0;
if(this.iframeTransparency){
_3e5.allowTransparency=true;
}
var self=this;
function myDialogHideLoading(){
self.hideLoading();
}
function myDialogFocus(){
self.focus();
}
if(document.attachEvent){
_3e5.attachEvent("onload",myDialogHideLoading);
}else{
_3e5.addEventListener("load",myDialogHideLoading,false);
}
if(this.url.indexOf("modalTime")==-1){
var _3e7=new Date().getTime();
if(this.url.indexOf("?")==-1){
this.url+="?modalTime="+_3e7;
}else{
this.url+="&modalTime="+_3e7;
}
}
_3e5.src=this.url;
_3e5.style.display="none";
this.iframeWrapper.appendChild(_3e5);
this.iframe=_3e5;
function cleanupIE_Events(){
if(_3e5){
_3e5.detachEvent("onload",myDialogHideLoading);
_3e5.detachEvent("onfocus",myDialogFocus);
}
window.detachEvent("onunload",cleanupIE_Events);
}
if(this.browserType=="IE"){
window.attachEvent("onunload",cleanupIE_Events);
}else{
_3e5=null;
}
this.refreshSize();
},refreshSize:function(){
overlayStack.getPageSize();
this.width=this.contentWidth+this.shadowRight+(this.borderWidth*2);
this.height=this.contentHeight+this.shadowBottom+this.titleBarHeight+(this.borderWidth*2);
if(this.width>overlayStack.doc.windowWidth){
this.width=overlayStack.doc.windowWidth;
this.contentWidth=this.width-this.shadowRight-(this.borderWidth*2);
}
if(this.height>overlayStack.doc.windowHeight){
this.height=overlayStack.doc.windowHeight;
this.contentHeight=this.height-this.shadowBottom-this.titleBarHeight-(this.borderWidth*2);
}
var w=this.width+"px";
var h=this.height+"px";
var cw=this.contentWidth+"px";
var ch=this.contentHeight+"px";
this.dialog.style.width=w;
this.dialog.style.height=h;
if(!this.inline){
this.iframeSpacer.style.width=cw;
this.iframeSpacer.style.height=ch;
if(this.iframe){
this.iframe.style.width=cw;
this.iframe.style.height=ch;
}
this.loadingDiv.style.width=cw;
this.loadingDiv.style.height=ch;
this.loadingTextWrapper.style.top=(Math.round(this.contentHeight/2)-40)+"px";
this.loadingTextWrapper.style.left=(Math.round(this.contentWidth/2)-100)+"px";
}
if(this.modalType=="Modeless"){
this.modelessMaskingDiv.style.width=w;
this.modelessMaskingDiv.style.height=h;
this.modelessMaskingIframe.style.width=w;
this.modelessMaskingIframe.style.height=h;
}
},setSize:function(w,h){
this.contentWidth=parseInt(w,10);
this.contentHeight=parseInt(h,10);
if(this.inline){
this.contentWidth+=this.inlineDialogPadding*2;
this.contentHeight+=this.inlineDialogPadding*2;
}
this.width=this.contentWidth+this.shadowRight+(this.borderWidth*2);
this.height=this.contentHeight+this.shadowBottom+this.titleBarHeight+(this.borderWidth*2);
},setAnchorId:function(_3ee){
if(_3ee.length>0){
this.anchorId=_3ee;
}
},setDragNDrop:function(v){
this.enableDragging=v;
},setAutoCenter:function(v){
this.autoCenter=v;
},setTitle:function(_3f1){
if(_3f1!==""){
this.title=_3f1;
if(this.windowIcon){
this.windowIcon.innerHTML=_3f1;
}
}
},setDisabled:function(flag){
this.disabled=flag;
},disable:function(){
this.disabled=true;
this.closeLink.style.visibility="hidden";
},initDrag:function(_3f3){
if(this.dragObject===null){
this.dragObject=new DR.Utils.DragObject(this.dialog);
this.dragObject.setType("Absolute",this);
this.dragObject.setMoveDragCallback(true);
this.dragObject.setStopDragCallback(true);
}
this.dragObject.initDrag(_3f3);
},moveDrag:function(){
if(!this.inline){
this.loadingDiv.style.visibility="hidden";
this.iframe.style.display="none";
this.iframeSpacer.style.display="block";
}else{
this.dialogClone.style.visibility="hidden";
}
if(this.filtersSupported){
this.contentTable.style.filter="alpha(opacity=50)";
}else{
this.contentTable.style.opacity="0.5";
}
if(this.modalType=="Modeless"){
this.modalMask.className="modelessOverlayMask";
this.modalMask.style.display="block";
this.modalMaskIEOver.style.display="block";
}
this.focus();
},stopDrag:function(){
if(!this.inline){
if(this.loading){
this.loadingDiv.style.visibility="visible";
}else{
this.iframeSpacer.style.display="none";
this.iframe.style.display="block";
}
}else{
this.dialogClone.style.visibility="visible";
}
if(this.filtersSupported){
this.contentTable.style.filter="";
}else{
this.contentTable.style.opacity="1";
}
if(this.modalType=="Modeless"){
this.modalMask.style.display="none";
this.modalMaskIEOver.style.display="none";
}
},addEvent:function(obj,evt,fn,_3f7){
if(obj.addEventListener){
obj.addEventListener(evt,fn,Boolean(_3f7));
return true;
}else{
if(obj.attachEvent){
var r=obj.attachEvent("on"+evt,fn);
return r;
}else{
return false;
}
}
},removeEvent:function(obj,evt,fn,_3fc){
if(obj.addEventListener){
obj.removeEventListener(evt,fn,Boolean(_3fc));
return true;
}else{
if(obj.attachEvent){
var r=obj.detachEvent("on"+evt,fn);
return r;
}else{
return false;
}
}
}};
DR.Widgets.ModelessOverlay.open=function(url,_3ff,_400,_401){
var _402=new Date().getTime();
var m=new DR.Widgets.ModelessOverlay("modal_"+_402,url);
var t=_401;
if(!_401){
t="&nbsp;";
}
m.setTitle(t);
m.setSize(_3ff,_400);
m.show();
return m;
};
DR.Widgets.ModelessOverlay.close=function(){
parent.overlayStack.closeCurrent();
};
DR.Widgets.ModalOverlay=function(id,url,_407){
this.id=id;
this.url=url;
this.optionalClassName=(_407)?_407:null;
};
DR.Widgets.ModalOverlay.prototype=new DR.Widgets.ModelessOverlay();
DR.Widgets.ModalOverlay.prototype.modalType="Modal";
DR.Widgets.ModalOverlay.CLOSE_WINDOW="Close Window";
DR.Widgets.ModalOverlay.LOADING_WINDOW="Loading please wait...";
DR.Widgets.ModalOverlay.open=function(url,_409,_40a,_40b){
var _40c=new Date().getTime();
var m=new DR.Widgets.ModalOverlay("modal_"+_40c,url);
var t=_40b;
if(!_40b){
t="&nbsp;";
}
m.setTitle(t);
m.setSize(_409,_40a);
m.show();
return m;
};
DR.Widgets.ModalOverlay.close=function(){
parent.overlayStack.closeCurrent();
};
DR.Widgets.InlineModalOverlay=function(id,_410){
this.id=id;
this.inlineId=id;
this.optionalClassName=(_410)?_410:null;
};
DR.Widgets.InlineModalOverlay.prototype=new DR.Widgets.ModelessOverlay();
DR.Widgets.InlineModalOverlay.prototype.modalType="Modal";
DR.Widgets.InlineModalOverlay.prototype.inline=true;
DR.Widgets.InlineModelessOverlay=function(id,_412){
this.id=id;
this.inlineId=id;
this.optionalClassName=(_412)?_412:null;
};
DR.Widgets.InlineModelessOverlay.prototype=new DR.Widgets.ModelessOverlay();
DR.Widgets.InlineModelessOverlay.prototype.modalType="Modeless";
DR.Widgets.InlineModelessOverlay.prototype.inline=true;
DR.Widgets.ModalOverlay.iframeFunctionCallback="";
DR.Widgets.ModalOverlay.iframeCallbackTimeout=function(){
eval(DR.Widgets.ModalOverlay.iframeFunctionCallback);
};
DR.Widgets.ModalOverlay.iframeCallback=function(func){
DR.Widgets.ModalOverlay.iframeFunctionCallback=func;
setTimeout("DR.Widgets.ModalOverlay.iframeCallbackTimeout()",1);
};
(function($){
var _415={type:"modal",inline:false,width:620,height:590,url:null,id:null,title:"&nbsp;",cancelFunction:null,callBackFunction:null,abortFunction:null,draggable:true,centered:true,relativePositioned:false,optionalClassName:null,showCloseIcon:true};
$.dr.overlay=function(_416){
_416=$.extend({},_415,_416);
var m,id=_416.id,url=_416.url,type=_416.type,inline=_416.inline,optionalClassName=_416.optionalClassName;
if(inline){
var d=$("#"+id).data("inlineOverlay");
if(d){
d.show();
return;
}
}else{
if(url.length===0){
return;
}
}
var _419=DR.Widgets;
if(!id){
id="modal_"+new Date().getTime();
}
if(!inline&&type=="modal"){
m=new _419.ModalOverlay(id,url,optionalClassName);
}else{
if(!inline&&type=="modeless"){
m=new _419.ModelessOverlay(id,url,optionalClassName);
}else{
if(type=="modal"){
m=new _419.InlineModalOverlay(id,optionalClassName);
}else{
if(type=="modeless"){
m=new _419.InlineModelessOverlay(id,optionalClassName);
}
}
}
}
m.setTitle(_416.title);
m.setSize(_416.width,_416.height);
if(!_416.draggable){
m.setDragNDrop(false);
}
if(!_416.centered){
m.setAutoCenter(false);
}
if(_416.anchorId){
m.setAutoCenter(false);
m.setAnchorId(_416.anchorId);
m.enableSelfPositioning=true;
}
if(_416.relativePositioned){
m.enableSelfPositioning=true;
}
if(typeof _416.cancelFunction=="function"){
m.cancelFunction=_416.cancelFunction;
}
if(typeof _416.callBackFunction=="function"){
m.callBackFunction=_416.callBackFunction;
}
if(typeof _416.abortFunction=="function"){
m.abortFunction=_416.abortFunction;
}
if(!_416.showCloseIcon){
m.setDisabled(true);
}
m.show();
if(inline){
$("#"+id).data("overlay",m);
}
return m;
};
$.dr.overlay.close=function(){
DR.Widgets.ModalOverlay.close();
};
$.namespace("dr",{overlay:function(_41a){
return this.each(function(){
var opts=$.extend({},_41a,{inline:true,id:this.id});
$.dr.overlay(opts);
});
}});
var _41c=function(obj){
return $(obj).data("overlay");
};
$.namespace("dr.overlay",{setTitle:function(_41e){
return this.each(function(){
var m=_41c(this);
if(m){
m.setTitle(_41e);
}
});
}});
})(jQuery);
DR.Widgets.ModalOverlayStack=function(){
this.windows=[];
this.zIndex=100000;
this.windowIndex=-1;
this.iframeCounter=-1;
this.currentWindow=-1;
this.focusAndBlurSet=false;
};
DR.Widgets.ModalOverlayStack.prototype={add:function(obj){
this.windowIndex++;
this.windows[this.windowIndex]=obj;
this.currentWindow=this.windowIndex;
return this.windowIndex;
},addChildWindow:function(obj,_422){
this.setCurrentHasModalChildren(true);
var m=new DR.Widgets.ModalOverlay(obj.id,obj.url);
m.parentId=this.currentWindow;
m.parentWindowIndex=_422;
m.setTitle(obj.title);
m.setDragNDrop(obj.enableDragging);
if(typeof (obj.callBackFunction)=="function"){
m.setCallBackFunction(obj.callBackFunction);
}
if(typeof (obj.cancelFunction)=="function"){
m.setCancelFunction(obj.cancelFunction);
}
if(typeof (obj.abortFunction)=="function"){
m.setAbortFunction(obj.abortFunction);
}
m.setSize(obj.contentWidth,obj.contentHeight);
m.show();
obj=null;
},getCurrent:function(){
if(this.currentWindow>-1){
var c=this.windows[this.currentWindow];
return c;
}
},getById:function(id){
for(var i=0;i<this.windows.length;i++){
if(this.windows[i].id==id){
return this.windows[i];
break;
}
}
return null;
},checkCurrentLoading:function(){
if(this.currentWindow>-1){
var c=this.windows[this.currentWindow];
return c.loading;
}
},disableCurrent:function(){
if(this.currentWindow>-1){
var c=this.windows[this.currentWindow];
c.closeLink.style.visibility="hidden";
}
},enableCurrent:function(){
if(this.currentWindow>-1){
var c=this.windows[this.currentWindow];
c.closeLink.style.visibility="visible";
}
},setCurrentWindow:function(id){
this.currentWindow=id;
},getNewIframeID:function(){
this.iframeCounter++;
return this.iframeCounter;
},checkAnyOpen:function(){
var _42b=false;
for(var i=0;i<this.windows.length;i++){
if(this.windows[i].isOpen){
_42b=true;
}
}
return _42b;
},checkAnyModalOpen:function(){
var _42d=false;
for(var i=0;i<this.windows.length;i++){
if(this.windows[i].isOpen&&this.windows[i].modalType=="Modal"){
_42d=true;
}
}
return _42d;
},checkAnyModelessOpen:function(){
var _42f=false;
for(var i=0;i<this.windows.length;i++){
if(this.windows[i].isOpen&&this.windows[i].modalType=="Modeless"){
_42f=true;
}
}
return _42f;
},setCurrentHasChildren:function(flag){
if(this.currentWindow>-1){
var c=this.windows[this.currentWindow];
c.hasChildren=flag;
}
},setCurrentHasModalChildren:function(flag){
if(this.currentWindow>-1){
var c=this.windows[this.currentWindow];
c.hasModalChildren=flag;
}
},resizeCurrent:function(_435,_436){
if(this.currentWindow>-1){
var c=this.windows[this.currentWindow];
c.setSize(_435,_436);
c.refreshSize();
c.position();
}
},blurCurrent:function(){
if(this.currentWindow>-1){
var c=this.windows[this.currentWindow];
c.blurWindow=false;
c.blur();
}
},hideCurrent:function(){
if(this.currentWindow>-1){
var c=this.windows[this.currentWindow];
c.dialog.style.display="none";
c.enableScrollBars();
}
},blurOtherWindows:function(){
for(var i=0;i<this.windows.length;i++){
if(this.windows[i].stackId!=this.currentWindow){
this.windows[i].hasFocus=false;
this.windows[i].blur();
}
}
},windowOnBlur:function(){
if(this.currentWindow>-1){
var c=this.windows[this.currentWindow];
c.blurWindow=true;
c.blur();
}
},focusCurrent:function(_43c){
if(this.currentWindow>-1){
var c=this.windows[this.currentWindow];
if(!c.hasFocus||_43c){
c.focus();
}
}
},bringToFront:function(id){
if(this.windowIndex>-1){
this.currentWindow=id;
var c=this.windows[this.currentWindow];
this.zIndex=this.zIndex+5;
if(this.currentWindow>-1){
c.dialog.style.zIndex=this.zIndex;
c.modalMask.style.zIndex=this.zIndex-2;
c.modalMaskIEOver.style.zIndex=this.zIndex-1;
DR.Utils.removeCSSClass(c.contentTable,"inActive");
}
}
},addWindowEventHandlers:function(){
function overlayStackFocusParent(){
if(window!=top){
parent.overlayStack.setCurrentHasChildren(false);
parent.overlayStack.focusCurrent(true);
}
}
if(!overlayStack.focusAndBlurSet){
if(window.attachEvent){
window.attachEvent("onunload",overlayStackFocusParent);
}else{
window.addEventListener("unload",overlayStackFocusParent,false);
}
var _440=window.onresize;
if(typeof window.onresize!="function"){
window.onresize=function(){
overlayStack.refreshMaskSize();
};
this.onResizeSet=true;
}else{
if(!this.onResizeSet){
window.onresize=function(){
overlayStack.refreshMaskSize();
_440();
};
}
}
overlayStack.focusAndBlurSet=true;
}
function cleanupEvents(){
window.detachEvent("onunload",cleanupEvents);
window.onresize=null;
}
if(window.attachEvent){
window.attachEvent("onunload",cleanupEvents);
}
},refreshMaskSize:function(){
if(this.currentWindow>-1){
var c=this.windows[this.currentWindow];
this.getPageSize();
if(document.all){
c.modalMask.style.width=this.doc.windowWidth+"px";
c.modalMaskIframe.style.width=this.doc.windowWidth+"px";
c.modalMaskIEOver.style.width=this.doc.windowWidth+"px";
}
c.modalMask.style.height=this.doc.pageHeight+"px";
c.modalMaskIframe.style.height=this.doc.pageHeight+"px";
c.modalMaskIEOver.style.height=this.doc.pageHeight+"px";
}
},buildIframe:function(){
if(this.currentWindow>-1){
this.windows[this.currentWindow].ieTimeout=false;
this.windows[this.currentWindow].buildIframe();
}
},closeCurrent:function(){
if(this.currentWindow>-1){
this.windows[this.currentWindow].cancel();
}
},cancelCurrent:function(){
if(this.currentWindow>-1){
this.windows[this.currentWindow].cancel();
}
},destroyAll:function(){
var _442=false;
for(var i=0;i<this.windows.length;i++){
if(!this.windows[i].inline){
this.currentWindow=i;
this.destroyCurrent();
}
}
return _442;
},destroyCurrent:function(){
if(this.currentWindow>-1){
this.destroyWindow(this.currentWindow);
}
},destroyWindow:function(_444){
if(_444>-1){
var _445=this.windows[_444];
var _446=-1;
if(_445.parentId>-1){
_446=_445.parentId;
}
if(!_445.inline){
if(_445.iframe){
_445.iframe.parentNode.removeChild(_445.iframe);
_445.iframeSpacer.parentNode.removeChild(_445.iframeSpacer);
_445.contentTable.parentNode.removeChild(_445.contentTable);
_445.windowIcon.parentNode.removeChild(_445.windowIcon);
_445.dialog.parentNode.removeChild(_445.dialog);
this.windows[_444].iframe=null;
this.windows[_444].modalMask=null;
this.windows[_444].modelessMaskingDiv=null;
this.windows[_444].modelessMaskingIframe=null;
this.windows[_444].modalMaskIframe=null;
this.windows[_444].modalMaskIEOver=null;
this.windows[_444].iframeSpacer=null;
this.windows[_444].contentTable=null;
this.windows[_444].windowIcon=null;
this.windows[_444].dialog=null;
}
_445=null;
this.windows[_444]=null;
this.windows.splice(_444,1);
this.windowIndex--;
this.currentWindow=-1;
_444=this.windows.length-1;
}
if(_446>-1&&_444>-1){
this.windows[_446].hasModalChildren=false;
this.windows[_446].focus();
this.reorderStack(false);
}else{
this.reorderStack(true);
}
}
},reorderStack:function(_447){
var _448=-1;
for(var i=0;i<this.windows.length;i++){
if(this.windows[i].isOpen){
this.windows[i].stackId=i;
_448=i;
}
}
if(_448>-1&&_447){
this.currentWindow=_448;
this.windows[this.currentWindow].focus();
}
},callBack:function(arg1,arg2,arg3,arg4,arg5,arg6,arg7,arg8,arg9,_453){
if(this.currentWindow>-1){
var _454=this.windows[this.currentWindow];
if(_454.parentId>-1){
window.frames[this.windows[_454.parentId].iframe.id].overlayStack.callBack(arg1,arg2,arg3,arg3,arg4,arg5,arg6,arg7,arg8,arg9,_453);
}else{
_454.callBack(arg1,arg2,arg3,arg3,arg4,arg5,arg6,arg7,arg8,arg9,_453);
}
}
},getPageSize:function(){
var _455,yScroll,pageHeight,pageWidth;
var obj={};
if(window.innerHeight&&window.scrollMaxY){
_455=document.body.scrollWidth;
yScroll=window.innerHeight+window.scrollMaxY;
}else{
if(document.body.scrollHeight>document.body.offsetHeight){
_455=document.body.scrollWidth;
yScroll=document.body.scrollHeight;
}else{
_455=document.body.offsetWidth;
yScroll=document.body.offsetHeight;
}
}
var _457,windowHeight;
if(self.innerHeight){
_457=self.innerWidth;
windowHeight=self.innerHeight;
}else{
if(document.documentElement&&document.documentElement.clientHeight){
_457=document.documentElement.clientWidth;
windowHeight=document.documentElement.clientHeight;
}else{
if(document.body){
_457=document.body.clientWidth;
windowHeight=document.body.clientHeight;
}
}
}
if(yScroll<windowHeight){
pageHeight=windowHeight;
}else{
pageHeight=yScroll;
}
if(_455<_457){
pageWidth=_457;
}else{
pageWidth=_455;
}
if(this.doc===undefined){
this.doc={};
}
this.doc.pageWidth=pageWidth;
this.doc.pageHeight=pageHeight;
this.doc.windowWidth=_457;
this.doc.windowHeight=windowHeight;
}};
overlayStack=new DR.Widgets.ModalOverlayStack();
DR.Widgets.Prompt=function(){
this._type="Prompt";
this.built=false;
this.questionDiv=null;
this.liveChangeTextDiv=null;
this.textInput=null;
this.overlay=null;
this.size="normal";
this.isPrompt=false;
this.isAlert=false;
this.isCriticalConfirm=false;
this.isConfirm=false;
this.modalWarning=false;
this.isSuccess=false;
this.iconClass="";
this.width=420;
this.height=200;
};
DR.Widgets.Prompt.PROMPT="Prompt";
DR.Widgets.Prompt.ALERT="Alert";
DR.Widgets.Prompt.WARNING="Warning";
DR.Widgets.Prompt.CONFIRM="Confirm";
DR.Widgets.Prompt.SUCCESS="Success";
DR.Widgets.Prompt.LIVE_CHANGE="Live Change Warning";
DR.Widgets.Prompt.LIVE_CHANGE_QUESTION="Please enter your username as it appears below to confirm you want to save these changes.{0}Username: {1}";
DR.Widgets.Prompt.INCORRECT_VALUE="The value you entered is incorrect.";
DR.Widgets.Prompt.prototype={init:function(){
this.parentDiv=document.getElementById(DR.CONTENT_AREA_ID);
if(this.parentDiv===null){
this.parentDiv=document.body;
}
if(this.parentDiv){
switch(this._type){
case "Prompt":
this.modalTitle=DR.Widgets.Prompt.PROMPT;
this.isPrompt=true;
this.iconClass="modalPrompt";
break;
case "Confirm":
this.modalTitle=DR.Widgets.Prompt.CONFIRM;
this.isConfirm=true;
this.iconClass="";
break;
case "Alert":
this.modalTitle=DR.Widgets.Prompt.ALERT;
this.isAlert=true;
this.iconClass="modalPrompt";
break;
case "Warning":
this.modalTitle=DR.Widgets.Prompt.WARNING;
this.isWarning=true;
this.iconClass="modalWarning";
break;
case "Success":
this.modalTitle=DR.Widgets.Prompt.SUCCESS;
this.isSuccess=true;
this.iconClass="modalSuccess";
break;
case "Critical_Confirm":
this.modalTitle=DR.Widgets.Prompt.LIVE_CHANGE;
this.isCriticalConfirm=true;
this.iconClass="modalLiveChange";
this.height=300;
break;
}
this.instanceId="DR.Utils."+this._type.toUpperCase();
this.prefixId="modal_"+this._type;
var d=document.createElement("div");
d.id=this.prefixId+"_container";
var f=document.createElement("div");
f.className="questionBg";
var q=document.createElement("div");
q.className="question";
var _45b=document.createElement("div");
q.appendChild(_45b);
this.questionDiv=_45b;
var _45c="check";
var _45d=this.instanceId+".cancel()";
var _45e=this.instanceId+".ok()";
var _45f;
var _460;
if(this.isPrompt||this.isCriticalConfirm){
_45f=document.createElement("div");
_45f.className="input";
_45f.innerHTML="<input type=\"text\" id=\""+this.prefixId+"_input\" autocomplete=\"off\" onkeyup=\""+this.instanceId+".enterKey(event)\" />";
_45c="save";
}
var _460;
var _461="";
if(this.isCriticalConfirm){
var _461=DR.Widgets.Prompt.LIVE_CHANGE_QUESTION.replaceBreaks();
_461=_461.replace("{1}","<strong><span id=\"liveChangeKey\">"+this.acceptKey+"<span></strong>");
var _460=document.createElement("div");
_460.innerHTML=_461;
_460.className="liveChangeText";
this.liveChangeTextDiv=_460;
}
var s="";
if(!this.isAlert&&!this.isSuccess){
s+="<button id=\""+this.prefixId+"_cancelBtn\" class=\"button cancel large\" type=\"button\" onclick=\""+_45d+"\"></button>";
}
s+="<button id=\""+this.prefixId+"_okBtn\" type=\"button\" class=\"button "+_45c+" large primary\" onclick=\""+_45e+"\" style=\"margin-right:0;\"></button>";
var _463=document.createElement("div");
_463.className="pageButtons";
_463.innerHTML=s;
if(this.isPrompt||this.isCriticalConfirm){
f.appendChild(q);
d.appendChild(f);
if(this.isCriticalConfirm){
d.appendChild(_460);
}
d.appendChild(_45f);
d.appendChild(_463);
}else{
q.appendChild(_463);
f.appendChild(q);
d.appendChild(f);
}
this.parentDiv.appendChild(d);
this.okButton=getElem(this.prefixId+"_okBtn");
if(!this.isAlert&&!this.isSuccess){
this.cancelButton=getElem(this.prefixId+"_cancelBtn");
}
if(this.isPrompt||this.isCriticalConfirm){
$(this.cancelButton).dr.button.changeText(BUTTON_CANCEL);
if(this.isCriticalConfirm){
$(this.okButton).dr.button.changeText(BUTTON_OK);
}else{
$(this.okButton).dr.button.changeText(BUTTON_SAVE);
}
this.textInput=getElem(this.prefixId+"_input");
}else{
if(this.isAlert||this.isSuccess){
$(this.okButton).dr.button.changeText(BUTTON_OK);
}else{
$(this.cancelButton).dr.button.changeText(BUTTON_NO);
$(this.okButton).dr.button.changeText(BUTTON_YES);
}
}
var opts={inline:true,id:this.prefixId+"_container",optionalClassName:this.iconClass+" modalConfirm",showCloseIcon:false,width:this.width,height:this.height};
if(this.isSuccess){
opts.type="modeless";
}
this.overlay=$.dr.overlay(opts);
}
},open:function(_465,text,_467,_468,_469){
if((this.isAlert||this.isSuccess||typeof (_467)=="function"||_467===null)&&typeof (_465)=="string"){
if(_469){
this.acceptKey=_469.trim();
getElem("liveChangeKey").innerHTML=this.acceptKey;
}
this.questionDiv.innerHTML=_465;
this.overlay.setTitle(_468||this.modalTitle);
this.overlay.setDisabled(true);
this.overlay.show();
if(this.isPrompt||this.isCriticalConfirm){
this.textInput.value=text;
this.textInput.focus();
this.textInput.select();
}else{
if(this.isSuccess){
this.okButton.focus();
}
}
this.callback=_467;
}
},ok:function(){
var _46a=true;
if(typeof (this.callback)=="function"){
if(this.isPrompt){
this.callback(this.textInput.value);
}else{
if(this.isCriticalConfirm){
if(this.acceptKey==this.textInput.value.trim()){
this.callback(true);
}else{
_46a=false;
this.showCriticalConfirmWarning();
}
}else{
this.callback(true);
}
}
}
if(_46a){
this.overlay.cancel();
}
},enterKey:function(evt){
var key=(evt.which)?evt.which:event.keyCode;
if(key==13){
var val=this.textInput.value.trim();
if((this.lastValue!==undefined&&this.lastValue!=val)||(this.isCriticalConfirm&&this.acceptKey==val)){
this.ok();
}
this.lastValue=val;
}
},showCriticalConfirmWarning:function(){
alert(DR.Widgets.Prompt.INCORRECT_VALUE);
this.textInput.focus();
this.textInput.select();
},cancel:function(){
this.overlay.cancel();
if(typeof (this.callback)=="function"){
if(this.isPrompt){
this.callback(null);
}else{
this.callback(false);
}
}
}};
DR.Widgets.Confirm=function(){
this._type="Confirm";
};
DR.Widgets.Confirm.prototype=new DR.Widgets.Prompt();
DR.Widgets.Warning=function(){
this._type="Warning";
};
DR.Widgets.Warning.prototype=new DR.Widgets.Prompt();
DR.Widgets.Alert=function(){
this._type="Alert";
};
DR.Widgets.Alert.prototype=new DR.Widgets.Prompt();
DR.Widgets.Success=function(){
this._type="Success";
};
DR.Widgets.Success.prototype=new DR.Widgets.Prompt();
DR.Widgets.CriticalConfirm=function(){
this._type="Critical_Confirm";
};
DR.Widgets.CriticalConfirm.prototype=new DR.Widgets.Prompt();
DR.Utils.alert=function(_46e,_46f,_470){
if(!DR.Utils.ALERT){
DR.Utils.ALERT=new DR.Widgets.Alert();
DR.Utils.ALERT.init();
}
DR.Utils.ALERT.open(_46e,null,_46f,_470);
};
DR.Utils.ALERT=null;
DR.Utils.success=function(_471,_472,_473){
if(!DR.Utils.SUCCESS){
DR.Utils.SUCCESS=new DR.Widgets.Success();
DR.Utils.SUCCESS.init();
}
DR.Utils.SUCCESS.open(_471,null,_472,_473);
};
DR.Utils.SUCCESS=null;
DR.Utils.warning=function(_474,_475,_476){
if(!DR.Utils.WARNING){
DR.Utils.WARNING=new DR.Widgets.Warning();
DR.Utils.WARNING.init();
}
DR.Utils.WARNING.open(_474,null,_475,_476);
};
DR.Utils.WARNING=null;
DR.Utils.confirm=function(_477,_478,_479){
if(!DR.Utils.CONFIRM){
DR.Utils.CONFIRM=new DR.Widgets.Confirm();
DR.Utils.CONFIRM.init();
}
DR.Utils.CONFIRM.open(_477,null,_478,_479);
};
DR.Utils.CONFIRM=null;
DR.Utils.prompt=function(_47a,text,_47c,_47d){
if(!DR.Utils.PROMPT){
DR.Utils.PROMPT=new DR.Widgets.Prompt();
DR.Utils.PROMPT.init();
}
DR.Utils.PROMPT.open(_47a,text,_47c,_47d);
};
DR.Utils.PROMPT=null;
DR.Utils.criticalConfirm=function(_47e,text,_480,_481,_482){
if(!DR.Utils.CRITICAL_CONFIRM){
DR.Utils.CRITICAL_CONFIRM=new DR.Widgets.CriticalConfirm();
DR.Utils.CRITICAL_CONFIRM.init();
}
DR.Utils.CRITICAL_CONFIRM.open(_47e,text,_480,_481,_482);
};
DR.Utils.CRITICAL_CONFIRM=null;
(function($){
var _484={title:null,callback:null};
var _485=function(_486){
_486=(_486)?_486:{};
return $.extend({},_484,_486);
};
$.dr.alert=function(text,_488){
_488=_485(_488);
DR.Utils.alert(text,_488.callback,_488.title);
};
$.dr.success=function(text,_48a){
_48a=_485(_48a);
DR.Utils.success(text,_48a.callback,_48a.title);
};
$.dr.warning=function(text,_48c,_48d){
_48d=_485(_48d);
DR.Utils.warning(text,_48c,_48d.title);
};
$.dr.confirm=function(text,_48f,_490){
_490=_485(_490);
DR.Utils.confirm(text,_48f,_490.title);
};
$.dr.prompt=function(text,_492,_493,_494){
_494=_485(_494);
DR.Utils.prompt(text,_492,_493,_494.title);
};
$.dr.criticalConfirm=function(text,_496,_497,_498,_499){
_499=_485(_499);
DR.Utils.criticalConfirm(text,_496,_497,_499.title,_498);
};
})(jQuery);
DR.Widgets.PanelSet=function(obj){
this.layout="TwoColumn";
this.sidebarOpenCSSClass="sidebarOpen";
this.sidebarClosedCSSClass="sidebarClosed";
this.buttonSelectedCSSClass="selected";
this.column1Open=true;
this.container=(typeof obj=="string")?document.getElementById(obj):obj;
this.defaultSearchField=null;
this.column1Button=null;
this.column1=null;
this.column2=null;
this.column1Width=200;
this.column2Width=null;
this.panelWidth=720;
this.panelHeight=430;
this.autoHeightSizing=true;
this.handleWidth=10;
this.leftPadding=10;
this.column1MinWidth=170;
this.column2MinWidth=170;
this.dragObject=null;
this.resizeCallback=null;
this.saveCookieState=false;
this.saveUserDataState=true;
this.stateCookie=null;
this.stateCookieID=null;
this.dataTableContainer=null;
};
DR.Widgets.PanelSet.prototype={init:function(){
this.loadState();
var self=this;
var _49c=window.onresize;
var _49d=function(){
self.refreshPanelSize();
self.refresh();
};
window.onresize=function(){
_49d();
if(typeof (_49c)=="function"){
_49c();
}
};
var _49e,winOnload;
function cleanupEvents(){
window.detachEvent("onresize",winOnload);
window.detachEvent("onresize",_49d);
window.detachEvent("onunload",cleanupEvents);
}
if(DR.Utils.BrowserDetect.browser=="Explorer"){
if(DR.Utils.BrowserDetect.version<7){
if(this.column2){
var d=this.column2.getElementsByTagName("div");
for(var i=0;i<d.length;i++){
var c=d[i].className;
if(c){
if(c.indexOf("dataTableContainer")>-1){
this.dataTableContainer=d[i];
break;
}
}
}
}
}
_49e=window.onload;
winOnload=function(){
self.drawInterface();
};
window.onload=function(){
winOnload();
if(typeof (_49e)=="function"){
_49e();
}
};
if(window.attachEvent){
window.attachEvent("onunload",cleanupEvents);
}
}else{
this.drawInterface();
}
},drawInterface:function(){
this.refreshPanelSize();
this.attachHandles();
this.refresh();
this.show();
},setColumn1Id:function(id){
this.column1=document.getElementById(id);
},setColumn2Id:function(id){
this.column2=document.getElementById(id);
},setColumn1Width:function(w){
this.column1Width=parseInt(w,10);
},show:function(){
this.container.style.visibility="visible";
},setPanelSize:function(w,h){
if(w!==undefined&&h!==undefined){
this.panelWidth=parseInt(w,10);
this.panelHeight=parseInt(h,10);
}
},setPanelHeight:function(h){
if(h!==undefined){
this.autoHeightSizing=false;
this.panelHeight=parseInt(h,10);
}
},refreshPanelSize:function(w,h){
if(DR.Utils.BrowserDetect.browser=="Explorer"){
this.panelWidth=this.container.offsetWidth;
if(this.autoHeightSizing&&DR.Utils.BrowserDetect.version>6){
this.panelHeight=jQuery("TABLE.panelTable",this.container)[0].offsetHeight;
}
}else{
this.panelWidth=this.container.offsetWidth;
}
},setColumn1DefaultWidth:function(w){
if(w!==undefined){
this.column1Width=parseInt(w,10);
}
},setColumn2DefaultWidth:function(w){
if(w!==undefined){
this.column2Width=parseInt(w,10);
}
},setColumn1MinWidth:function(w){
if(w!==undefined){
this.column1MinWidth=parseInt(w,10);
}
},setColumn1ButtonId:function(id){
if(id!==undefined){
this.column1Button=document.getElementById(id);
}
},setDefaultSearchFocusFieldId:function(id){
if(id!==undefined){
this.defaultSearchField=document.getElementById(id);
}
},setUserDataStorageIds:function(_4af,_4b0){
if(_4af!==undefined&&_4b0!==undefined){
this.userDataPageName=_4af;
this.userDataSetting=_4b0;
}
},setColumn2MinWidth:function(w){
if(w!==undefined){
this.column2MinWidth=parseInt(w,10);
}
},getColumn1Width:function(){
return this.column1Width;
},getColumn2Width:function(){
return this.column2Width;
},setResizeCallback:function(func){
if(typeof func=="function"){
this.resizeCallback=func;
}
},setStateCookieID:function(_4b3){
this.saveCookieState=true;
this.stateCookieID=_4b3+"_LeftWidth";
},loadState:function(){
if(this.saveCookieState&&this.stateCookie===null){
this.stateCookie=new DR.Utils.Cookie(this.stateCookieID);
this.stateCookie.load();
var v=this.stateCookie.value;
if(v!==null){
this.column1Width=parseInt(v,10);
}
}
},saveState:function(_4b5){
if(this.saveUserDataState&&DR.USER_DATA!==null){
if(_4b5=="width"){
DR.USER_DATA.save(this.userDataPageName,this.userDataSetting+"Width",this.column1Width,"String");
}else{
var _4b6="";
if(!this.column1Open){
_4b6="collapsed";
}
DR.USER_DATA.save(this.userDataPageName,this.userDataSetting+"Collapsed",_4b6,"String");
}
}else{
if(this.saveCookieState&&this.stateCookie===null){
this.stateCookie.setValue(""+this.column1Width+"");
}
}
},attachHandles:function(){
var _4b7;
if(this.layout=="TwoColumn"){
_4b7="H";
}else{
if(this.layout=="TwoRow"){
_4b7="V";
}
}
var self=this;
this.hiddenHandle=document.createElement("div");
this.hiddenHandle.style.position="absolute";
this.hiddenHandle.style.top="0px";
this.hiddenHandle.style.display="none";
this.staticHandle=document.createElement("div");
this.staticHandle.style.position="absolute";
this.staticHandle.style.top="0px";
this.staticHandle.style.display="block";
function handleOnMousedown(_4b9){
self.initDrag(_4b9);
}
this.staticHandle.onmousedown=handleOnMousedown;
this.hiddenHandle.className="splitContainerHiddenHandle"+_4b7;
this.staticHandle.className="splitContainerHandle"+_4b7;
this.container.appendChild(this.staticHandle);
this.container.appendChild(this.hiddenHandle);
function cleanupEvents(){
self.staticHandle.detachEvent("onmousedown",handleOnMousedown);
window.detachEvent("onunload",cleanupEvents);
}
if(window.attachEvent){
window.attachEvent("onunload",cleanupEvents);
}
},refresh:function(){
var h=this.panelHeight-2;
if(this.hiddenHandle){
if(DR.Utils.BrowserDetect.browser=="Explorer"){
if(this.autoHeightSizing){
}
this.hiddenHandle.style.height=(h+2)+"px";
this.staticHandle.style.height=(h+2)+"px";
}else{
this.hiddenHandle.style.height="100%";
this.staticHandle.style.height="100%";
}
}
this.refreshColumn1Width();
if(!(DR.Utils.BrowserDetect.browser=="Explorer"&&DR.Utils.BrowserDetect.version<7)){
this.fixColumn1Width();
}else{
this.column2Width=this.container.offsetWidth-this.column1Width;
if(this.dataTableContainer){
this.dataTableContainer.style.width=(this.column2Width-20)+"px";
}
}
if(this.hiddenHandle){
this.hiddenHandle.style.left=(this.column1Width)+"px";
this.staticHandle.style.left=(this.column1Width)+"px";
}
if(typeof this.resizeCallback=="function"){
this.resizeCallback();
}
},fixColumn1Width:function(_4bb){
if(this.container.className.indexOf(this.sidebarClosedCSSClass)==-1){
var a=this.column1.childNodes;
for(var i=0;i<a.length;i++){
if(a[i].tagName){
var newW=(a[i].offsetWidth);
if(jQuery.browser.safari){
newW=newW+2;
}
this.column1.style.width=newW+"px";
this.column1Width=newW+this.leftPadding;
}
}
}
},refreshColumn1Width:function(_4bf){
this.column1.style.width=(this.column1Width-this.leftPadding)+"px";
},initDrag:function(_4c0){
if(this.dragObject===null){
this.dragObject=new DR.Utils.DragObject(this.hiddenHandle);
this.dragObject.setType("PanelSet",this);
this.dragObject.setMoveDragCallback(true);
this.dragObject.setStopDragCallback(true);
}
this.dragObject.initDrag(_4c0);
},moveDrag:function(x,y){
this.hiddenHandle.style.display="block";
},stopDrag:function(x,y){
if(this.layout=="TwoColumn"){
this.column1Width=parseInt(this.hiddenHandle.style.left,10);
this.saveState("width");
}
this.dragObject.isDragging=false;
this.dragObject.isInitialized=false;
this.hiddenHandle.style.display="none";
this.refresh();
if(typeof this.resizeCallback=="function"){
this.resizeCallback(this.column1Width);
}
},hideColumn1:function(){
if(DR.Utils.BrowserDetect.browser=="Explorer"){
this.column1.style.display="none";
}
DR.Utils.replaceCSSClass(this.container,this.sidebarOpenCSSClass,this.sidebarClosedCSSClass);
DR.Utils.removeCSSClass(this.column1Button,"selected");
this.column1Open=false;
this.saveState("column1Visible");
},showColumn1:function(){
if(DR.Utils.BrowserDetect.browser=="Explorer"){
this.column1.style.display="block";
}
DR.Utils.replaceCSSClass(this.container,this.sidebarClosedCSSClass,this.sidebarOpenCSSClass);
DR.Utils.addCSSClass(this.column1Button,this.buttonSelectedCSSClass);
if(this.defaultSearchField){
this.defaultSearchField.focus();
this.defaultSearchField.select();
}
this.column1Open=true;
this.saveState("column1Visible");
},toggleColumn1:function(){
if(this.container.className.indexOf(this.sidebarClosedCSSClass)>-1){
this.showColumn1();
}else{
this.hideColumn1();
}
}};
(function($){
var imgs=[],$dialog,frameTimeout,open=false,isIE6=($.browser.msie&&$.browser.version==6),stopEventDefined=false;
var _4c7={enabled:true,showText:true,text:"Processing...",cssClass:"processingDialog",imgSrc:"processingDialog/gears/gif/gear_0",imgExt:"gif",imgPrefix:"gear_0",frames:3,frameInterval:120,beforeUnloadDelay:2000,shadowVisible:true};
var _4c8=function(){
var _4c9=this;
var _4ca=$(window).scrollTop();
var _4cb=$(window).height();
var _4cc=$(window).width();
var _4cd=_4c9.height();
var _4ce=_4c9.width();
var posY=(!isIE6)?(_4cb/2)-(_4cd/2):(_4cb/2)-(_4cd/2)+_4ca;
var posX=(_4cc/2)-(_4ce/2);
_4c9.css({"top":posY,"left":posX});
};
var _4d1=function(){
var _4d2=this;
var _4d3=0;
var func=function(test){
if(_4d3>=_4c7.frames){
_4d3=0;
}
_4d2.attr("class",_4c7.cssClass+" "+_4c7.imgPrefix+_4d3);
_4d3++;
frameTimeout=setTimeout(func,_4c7.frameInterval);
};
func();
};
var _4d6=function(){
if(typeof (frameTimeout)!="undefined"){
clearTimeout(frameTimeout);
}
};
var _4d7=function(){
var _4d8=this;
$(window).bind("resize scroll",function(){
_4c8.call(_4d8);
});
};
$.dr.processingDialog={show:function(){
if(!_4c7.enabled||open){
return;
}
open=true;
$dialog.show();
_4d1.call($dialog);
_4c8.call($dialog);
_4d7.call($dialog);
if(!stopEventDefined&&$.browser.msie){
stopEventDefined=true;
document.attachEvent("onstop",$.dr.processingDialog.hide);
}
},hide:function(){
open=false;
_4d6();
$dialog.hide();
},enable:function(){
_4c7.enabled=true;
},disable:function(){
_4c7.enabled=false;
$.dr.processingDialog.hide();
}};
$(document).bind("showChangesWarning",function(){
$.dr.processingDialog.disable();
});
var init=function(){
$dialog=$("<div class=\""+_4c7.cssClass+" "+_4c7.imgPrefix+"\"><span><p>"+_4c7.text+"</p></span></div>").hide().prependTo("body");
if(isIE6){
$dialog.css("position","absolute");
}
if(!_4c7.showText){
$dialog.find("> span").addClass("hide");
}
if(_4c7.shadowVisible){
$dialog.find("> span").dr.shadows();
}
for(var i=0;i<_4c7.frames;i++){
imgs[i]=new Image();
imgs[i].src=DR.IMAGE_PATH+_4c7.imgSrc+i+"."+_4c7.imgExt;
}
var func=function(){
setTimeout($.dr.processingDialog.show,_4c7.beforeUnloadDelay);
};
$(window).bind("beforeunload",func);
};
$.dr.addDomReadyEvent(init,"domReadyLate");
})(jQuery);
DR.Utils.Profiler=function(){
this.startTime=new Date().getTime();
this.benchmarks=[];
this.log("Init Profiler");
};
DR.Utils.Profiler.prototype={start:function(){
this.startTime=new Date().getTime();
this.benchmarks=[];
this.log("Profiler: Start Timing");
},log:function(_4dc){
var obj={};
obj.time=new Date().getTime();
obj._event=_4dc;
this.benchmarks.push(obj);
},view:function(){
var _4de=this.benchmarks;
var _4df=this.startTime;
if(window.console&&!$.browser.safari){
for(var i=0;i<_4de.length;i++){
var time=_4de[i].time;
var _4e2=time-this.startTime;
var _4e3=time-_4df;
console.log("Elapsed time: "+_4e2+" - Delta: "+_4e3+" - "+_4de[i]._event);
_4df=time;
}
}else{
var h="<table cellpadding=\"4\" cellspacing=\"1\" border=\"1\" >";
h+="<tr><th nowrap=\"nowrap\" style=\"width:75px;\">Elapsed (ms)</th><th nowrap=\"nowrap\" style=\"width:60px;\">Delta (ms)</th><th>Event</th></tr>";
for(var i=0;i<_4de.length;i++){
var time=_4de[i].time;
var _4e2=time-this.startTime;
var _4e3=time-_4df;
h+="<tr>";
h+="<td>"+_4e2+"</td>";
h+="<td>"+_4e3+"</td>";
h+="<td nowrap=\"nowrap\">"+_4de[i]._event+"</td>";
h+="</tr>";
_4df=time;
}
h+="</table>";
DR_Utils_Logger.log(h);
DR_Utils_Logger.overlayContent.style.width="400px";
DR_Utils_Logger.overlay.setSize(450,350);
DR_Utils_Logger.overlay.setTitle("Profiler");
DR_Utils_Logger.overlay.refreshSize();
}
},clear:function(){
this.benchmarks=[];
}};
var DR_Utils_Profiler=new DR.Utils.Profiler();
DR.Widgets.SessionTimeout=function(){
};
DR.Widgets.SessionTimeout.KEEP_ALIVE_URL="";
DR.Widgets.SessionTimeout.SESSION_EXPIRED_TITLE="Session Expired";
DR.Widgets.SessionTimeout.SESSION_WARNING_TITLE="Session Timeout Warning";
DR.Widgets.SessionTimeout.sessionAboutToTimeoutTimerLimit=50;
DR.Widgets.SessionTimeout.timerLimit=60;
DR.Widgets.SessionTimeout.enabled=false;
DR.Widgets.SessionTimeout.init=function(){
if(DR.Widgets.SessionTimeout.enabled){
DR.Widgets.SessionTimeout.startTime=new Date().getTime();
DR.Widgets.SessionTimeout.overlay=null;
DR.Widgets.SessionTimeout.aboutToTimeoutOverlay=null;
DR.Widgets.SessionTimeout.sessionAboutToTimeoutTimerLimit=DR.Widgets.SessionTimeout.sessionAboutToTimeoutTimerLimit*1000*60;
DR.Widgets.SessionTimeout.timerLimit=DR.Widgets.SessionTimeout.timerLimit*1000*60;
window.setTimeout("DR.Widgets.SessionTimeout.check()",10000);
}
};
DR.Widgets.SessionTimeout.showAboutToTimeoutOverlay=function(){
if(DR.Widgets.SessionTimeout.aboutToTimeoutOverlay===null){
DR.Widgets.SessionTimeout.aboutToTimeoutOverlay=new DR.Widgets.InlineModalOverlay("sessionAboutToTimeoutOverlay");
DR.Widgets.SessionTimeout.aboutToTimeoutOverlay.setTitle(DR.Widgets.SessionTimeout.SESSION_WARNING_TITLE);
DR.Widgets.SessionTimeout.aboutToTimeoutOverlay.setSize(450,200);
}
if(!DR.Widgets.SessionTimeout.aboutToTimeoutOverlay.isOpen){
DR.Widgets.SessionTimeout.aboutToTimeoutOverlay.show();
overlayStack.disableCurrent();
getElem("keepAliveBtn").focus();
}
};
DR.Widgets.SessionTimeout.showOverlay=function(){
DR.Widgets.SessionTimeout.aboutToTimeoutOverlay.close();
if(DR.Widgets.SessionTimeout.overlay===null){
DR.Widgets.SessionTimeout.overlay=new DR.Widgets.InlineModalOverlay("sessionTimeoutOverlay");
}
DR.Widgets.SessionTimeout.overlay.setTitle(DR.Widgets.SessionTimeout.SESSION_EXPIRED_TITLE);
DR.Widgets.SessionTimeout.overlay.setSize(450,200);
DR.Widgets.SessionTimeout.overlay.show();
overlayStack.disableCurrent();
};
DR.Widgets.SessionTimeout.check=function(){
var _4e5=new Date().getTime();
var _4e6=_4e5-DR.Widgets.SessionTimeout.startTime;
if(_4e6>DR.Widgets.SessionTimeout.timerLimit){
DR.Widgets.SessionTimeout.showOverlay();
return;
}else{
if(_4e6>DR.Widgets.SessionTimeout.sessionAboutToTimeoutTimerLimit){
DR.Widgets.SessionTimeout.showAboutToTimeoutOverlay();
}
}
window.setTimeout("DR.Widgets.SessionTimeout.check()",10000);
};
DR.Widgets.SessionTimeout.keepAlive=function(){
DR.Widgets.SessionTimeout.sessionTimeoutStartTime=new Date().getTime();
DR.Widgets.SessionTimeout.aboutToTimeoutOverlay.close();
jQuery.ajax({type:"GET",url:DR.Widgets.SessionTimeout.keepAliveUrl});
};
(function($){
$.extend({tablesorter:new function(){
var _4e8=[],widgets=[];
this.defaults={cssHeader:"th_header",cssAsc:"descending",cssDesc:"ascending",sortInitialOrder:"asc",sortMultiSortKey:"shiftKey",sortForce:null,sortAppend:null,textExtraction:"simple",parsers:{},widgets:[],widgetZebra:{css:["even","odd"]},headers:{},widthFixed:false,cancelSelection:true,sortList:[],headerList:[],dateFormat:"us",decimal:".",debug:false};
function benchmark(s,d){
log(s+","+(new Date().getTime()-d.getTime())+"ms");
}
this.benchmark=benchmark;
function log(s){
if(typeof console!="undefined"&&typeof console.debug!="undefined"){
console.log(s);
}else{
alert(s);
}
}
function buildParserCache(_4ec,_4ed){
if(_4ec.config.debug){
var _4ee="";
}
var rows=_4ec.tBodies[0].rows;
if(_4ec.tBodies[0].rows[0]){
var list=[],cells=rows[0].cells,l=cells.length;
for(var i=0;i<l;i++){
var p=false;
if($.metadata&&($(_4ed[i]).metadata()&&$(_4ed[i]).metadata().sorter)){
p=getParserById($(_4ed[i]).metadata().sorter);
}else{
if((_4ec.config.headers[i]&&_4ec.config.headers[i].sorter)){
p=getParserById(_4ec.config.headers[i].sorter);
}
}
if(!p){
p=detectParserForColumn(_4ec,cells[i]);
}
if(_4ec.config.debug){
_4ee+="column:"+i+" parser:"+p.id+"\n";
}
list.push(p);
}
}
if(_4ec.config.debug){
log(_4ee);
}
return list;
}
function detectParserForColumn(_4f3,node){
var l=_4e8.length;
for(var i=1;i<l;i++){
if(_4e8[i].is($.trim(getElementText(_4f3.config,node)),_4f3,node)){
return _4e8[i];
}
}
return _4e8[0];
}
function getParserById(name){
var l=_4e8.length;
for(var i=0;i<l;i++){
if(_4e8[i].id.toLowerCase()==name.toLowerCase()){
return _4e8[i];
}
}
return false;
}
function buildCache(_4fa){
if(_4fa.config.debug){
var _4fb=new Date();
}
var _4fc=(_4fa.tBodies[0]&&_4fa.tBodies[0].rows.length)||0,totalCells=(_4fa.tBodies[0].rows[0]&&_4fa.tBodies[0].rows[0].cells.length)||0,_4e8=_4fa.config.parsers,cache={row:[],normalized:[]};
for(var i=0;i<_4fc;++i){
var c=_4fa.tBodies[0].rows[i],cols=[];
cache.row.push($(c));
for(var j=0;j<totalCells;++j){
cols.push(_4e8[j].format(getElementText(_4fa.config,c.cells[j]),_4fa,c.cells[j]));
}
cols.push(i);
cache.normalized.push(cols);
cols=null;
}
if(_4fa.config.debug){
benchmark("Building cache for "+_4fc+" rows:",_4fb);
}
return cache;
}
function getElementText(_500,node){
if(!node){
return "";
}
var t="";
if(_500.textExtraction=="simple"){
if(node.childNodes[0]&&node.childNodes[0].hasChildNodes()){
t=node.childNodes[0].innerHTML;
}else{
t=node.innerHTML;
}
}else{
if(typeof (_500.textExtraction)=="function"){
t=_500.textExtraction(node);
}else{
t=$(node).text();
}
}
return t;
}
function appendToTable(_503,_504){
if(_503.config.debug){
var _505=new Date();
}
var c=_504,r=c.row,n=c.normalized,totalRows=n.length,checkCell=(n[0].length-1),tableBody=$(_503.tBodies[0]),rows=[];
for(var i=0;i<totalRows;i++){
rows.push(r[n[i][checkCell]]);
if(!_503.config.appender){
var o=r[n[i][checkCell]];
var l=o.length;
for(var j=0;j<l;j++){
tableBody[0].appendChild(o[j]);
}
}
}
if(_503.config.appender){
_503.config.appender(_503,rows);
}
rows=null;
if(_503.config.debug){
benchmark("Rebuilt table:",_505);
}
applyWidget(_503);
setTimeout(function(){
$(_503).trigger("sortEnd");
},0);
}
function buildHeaders(_50b){
if(_50b.config.debug){
var time=new Date();
}
var meta=($.metadata)?true:false,tableHeadersRows=[];
for(var i=0;i<_50b.tHead.rows.length;i++){
tableHeadersRows[i]=0;
}
$tableHeaders=$("thead th",_50b);
$tableHeaders.each(function(_50f){
this.count=0;
this.column=_50f;
this.order=formatSortingOrder(_50b.config.sortInitialOrder);
if(checkHeaderMetadata(this)||checkHeaderOptions(_50b,_50f)){
this.sortDisabled=true;
}
if(!this.sortDisabled){
$(this).addClass(_50b.config.cssHeader);
}
_50b.config.headerList[_50f]=this;
});
if(_50b.config.debug){
benchmark("Built headers:",time);
log($tableHeaders);
}
return $tableHeaders;
}
function checkCellColSpan(_510,rows,row){
var arr=[],r=_510.tHead.rows,c=r[row].cells;
for(var i=0;i<c.length;i++){
var cell=c[i];
if(cell.colSpan>1){
arr=arr.concat(checkCellColSpan(_510,headerArr,row++));
}else{
if(_510.tHead.length==1||(cell.rowSpan>1||!r[row+1])){
arr.push(cell);
}
}
}
return arr;
}
function checkHeaderMetadata(cell){
if(($.metadata)&&($(cell).metadata().sorter===false)){
return true;
}
return false;
}
function checkHeaderOptions(_517,i){
if((_517.config.headers[i])&&(_517.config.headers[i].sorter===false)){
return true;
}
return false;
}
function applyWidget(_519){
var c=_519.config.widgets;
var l=c.length;
for(var i=0;i<l;i++){
getWidgetById(c[i]).format(_519);
}
}
function getWidgetById(name){
var l=widgets.length;
for(var i=0;i<l;i++){
if(widgets[i].id.toLowerCase()==name.toLowerCase()){
return widgets[i];
}
}
}
function formatSortingOrder(v){
if(typeof (v)!="Number"){
i=(v.toLowerCase()=="desc")?1:0;
}else{
i=(v==(0||1))?v:0;
}
return i;
}
function isValueInArray(v,a){
var l=a.length;
for(var i=0;i<l;i++){
if(a[i][0]==v){
return true;
}
}
return false;
}
function setHeadersCss(_525,_526,list,css){
_526.removeClass(css[0]).removeClass(css[1]);
var h=[];
_526.each(function(_52a){
if(!this.sortDisabled){
h[this.column]=$(this);
}
});
var l=list.length;
for(var i=0;i<l;i++){
if(list[i][0]){
h[list[i][0]].addClass(css[list[i][1]]);
}
}
}
function fixColumnWidth(_52d,_52e){
var c=_52d.config;
if(c.widthFixed){
var _530=$("<colgroup>");
$("tr:first td",_52d.tBodies[0]).each(function(){
_530.append($("<col>").css("width",$(this).width()));
});
$(_52d).prepend(_530);
}
}
function updateHeaderSortCount(_531,_532){
var c=_531.config,l=_532.length;
for(var i=0;i<l;i++){
var s=_532[i],o=c.headerList[s[0]];
o.count=s[1];
o.count++;
}
}
function multisort(_536,_537,_538){
if(_536.config.debug){
var _539=new Date();
}
var _53a="var sortWrapper = function(a,b) {",l=_537.length;
for(var i=0;i<l;i++){
var c=_537[i][0];
var _53d=_537[i][1];
var s=(getCachedSortType(_536.config.parsers,c)=="text")?((_53d==0)?"sortText":"sortTextDesc"):((_53d==0)?"sortNumeric":"sortNumericDesc");
var e="e"+i;
_53a+="var "+e+" = "+s+"(a["+c+"],b["+c+"]); ";
_53a+="if("+e+") { return "+e+"; } ";
_53a+="else { ";
}
var _540=_538.normalized[0].length-1;
_53a+="return a["+_540+"]-b["+_540+"];";
for(var i=0;i<l;i++){
_53a+="}; ";
}
_53a+="return 0; ";
_53a+="}; ";
eval(_53a);
_538.normalized.sort(sortWrapper);
if(_536.config.debug){
benchmark("Sorting on "+_537.toString()+" and dir "+_53d+" time:",_539);
}
return _538;
}
function sortText(a,b){
return ((a<b)?-1:((a>b)?1:0));
}
function sortTextDesc(a,b){
return ((b<a)?-1:((b>a)?1:0));
}
function sortNumeric(a,b){
return a-b;
}
function sortNumericDesc(a,b){
return b-a;
}
function getCachedSortType(_549,i){
return _549[i].type;
}
this.construct=function(_54b){
return this.each(function(){
if(!this.tHead||!this.tBodies){
return;
}
var _54c,$document,$headers,cache,config,shiftDown=0,sortOrder;
this.config={};
config=$.extend(this.config,$.tablesorter.defaults,_54b);
_54c=$(this);
$headers=buildHeaders(this);
this.config.parsers=buildParserCache(this,$headers);
cache=buildCache(this);
var _54d=[config.cssDesc,config.cssAsc];
fixColumnWidth(this);
$headers.click(function(e){
_54c.trigger("sortStart");
var _54f=(_54c[0].tBodies[0]&&_54c[0].tBodies[0].rows.length)||0;
if(!this.sortDisabled&&_54f>0){
var _550=$(this);
var i=this.column;
this.order=this.count++%2;
if(!e[config.sortMultiSortKey]){
config.sortList=[];
if(config.sortForce!=null){
var a=config.sortForce;
for(var j=0;j<a.length;j++){
if(a[j][0]!=i){
config.sortList.push(a[j]);
}
}
}
config.sortList.push([i,this.order]);
}else{
if(isValueInArray(i,config.sortList)){
for(var j=0;j<config.sortList.length;j++){
var s=config.sortList[j],o=config.headerList[s[0]];
if(s[0]==i){
o.count=s[1];
o.count++;
s[1]=o.count%2;
}
}
}else{
config.sortList.push([i,this.order]);
}
}
setTimeout(function(){
setHeadersCss(_54c[0],$headers,config.sortList,_54d);
appendToTable(_54c[0],multisort(_54c[0],config.sortList,cache));
},1);
return false;
}
}).mousedown(function(){
if(config.cancelSelection){
this.onselectstart=function(){
return false;
};
return false;
}
});
_54c.bind("update",function(){
this.config.parsers=buildParserCache(this,$headers);
cache=buildCache(this);
}).bind("sorton",function(e,list){
$(this).trigger("sortStart");
config.sortList=list;
var _557=config.sortList;
updateHeaderSortCount(this,_557);
setHeadersCss(this,$headers,_557,_54d);
appendToTable(this,multisort(this,_557,cache));
}).bind("appendCache",function(){
appendToTable(this,cache);
}).bind("applyWidgetId",function(e,id){
getWidgetById(id).format(this);
}).bind("applyWidgets",function(){
applyWidget(this);
});
if($.metadata&&($(this).metadata()&&$(this).metadata().sortlist)){
config.sortList=$(this).metadata().sortlist;
}
if(config.sortList.length>0){
_54c.trigger("sorton",[config.sortList]);
}
applyWidget(this);
});
};
this.addParser=function(_55a){
var l=_4e8.length,a=true;
for(var i=0;i<l;i++){
if(_4e8[i].id.toLowerCase()==_55a.id.toLowerCase()){
a=false;
}
}
if(a){
_4e8.push(_55a);
}
};
this.addWidget=function(_55d){
widgets.push(_55d);
};
this.formatFloat=function(s){
var i=parseFloat(s);
return (isNaN(i))?0:i;
};
this.formatInt=function(s){
var i=parseInt(s);
return (isNaN(i))?0:i;
};
this.isDigit=function(s,_563){
var _564="\\"+_563.decimal;
var exp="/(^[+]?0("+_564+"0+)?$)|(^([-+]?[1-9][0-9]*)$)|(^([-+]?((0?|[1-9][0-9]*)"+_564+"(0*[1-9][0-9]*)))$)|(^[-+]?[1-9]+[0-9]*"+_564+"0+$)/";
return RegExp(exp).test($.trim(s));
};
this.clearTableBody=function(_566){
if($.browser.msie){
function empty(){
while(this.firstChild){
this.removeChild(this.firstChild);
}
}
empty.apply(_566.tBodies[0]);
}else{
_566.tBodies[0].innerHTML="";
}
};
}});
$.fn.extend({tablesorter:$.tablesorter.construct});
var ts=$.tablesorter;
ts.addParser({id:"text",is:function(s){
return true;
},format:function(s){
return $.trim(s.toLowerCase());
},type:"text"});
ts.addParser({id:"digit",is:function(s,_56b){
var c=_56b.config;
return $.tablesorter.isDigit(s,c);
},format:function(s){
return $.tablesorter.formatFloat(s);
},type:"numeric"});
ts.addParser({id:"currency",is:function(s){
return /^[£$€?.]/.test(s);
},format:function(s){
return $.tablesorter.formatFloat(s.replace(new RegExp(/[^0-9.]/g),""));
},type:"numeric"});
ts.addParser({id:"ipAddress",is:function(s){
return /^\d{2,3}[\.]\d{2,3}[\.]\d{2,3}[\.]\d{2,3}$/.test(s);
},format:function(s){
var a=s.split("."),r="",l=a.length;
for(var i=0;i<l;i++){
var item=a[i];
if(item.length==2){
r+="0"+item;
}else{
r+=item;
}
}
return $.tablesorter.formatFloat(r);
},type:"numeric"});
ts.addParser({id:"url",is:function(s){
return /^(https?|ftp|file):\/\/$/.test(s);
},format:function(s){
return jQuery.trim(s.replace(new RegExp(/(https?|ftp|file):\/\//),""));
},type:"text"});
ts.addParser({id:"isoDate",is:function(s){
return /^\d{4}[\/-]\d{1,2}[\/-]\d{1,2}$/.test(s);
},format:function(s){
return $.tablesorter.formatFloat((s!="")?new Date(s.replace(new RegExp(/-/g),"/")).getTime():"0");
},type:"numeric"});
ts.addParser({id:"percent",is:function(s){
return /\%$/.test($.trim(s));
},format:function(s){
return $.tablesorter.formatFloat(s.replace(new RegExp(/%/g),""));
},type:"numeric"});
ts.addParser({id:"usLongDate",is:function(s){
return s.match(new RegExp(/^[A-Za-z]{3,10}\.? [0-9]{1,2}, ([0-9]{4}|'?[0-9]{2}) (([0-2]?[0-9]:[0-5][0-9])|([0-1]?[0-9]:[0-5][0-9]\s(AM|PM)))$/));
},format:function(s){
return $.tablesorter.formatFloat(new Date(s).getTime());
},type:"numeric"});
ts.addParser({id:"shortDate",is:function(s){
return /\d{1,2}[\/\-]\d{1,2}[\/\-]\d{2,4}/.test(s);
},format:function(s,_57f){
var c=_57f.config;
s=s.replace(/\-/g,"/");
if(c.dateFormat=="us"){
s=s.replace(/(\d{1,2})[\/\-](\d{1,2})[\/\-](\d{4})/,"$3/$1/$2");
}else{
if(c.dateFormat=="uk"){
s=s.replace(/(\d{1,2})[\/\-](\d{1,2})[\/\-](\d{4})/,"$3/$2/$1");
}else{
if(c.dateFormat=="dd/mm/yy"||c.dateFormat=="dd-mm-yy"){
s=s.replace(/(\d{1,2})[\/\-](\d{1,2})[\/\-](\d{2})/,"$1/$2/$3");
}
}
}
return $.tablesorter.formatFloat(new Date(s).getTime());
},type:"numeric"});
ts.addParser({id:"time",is:function(s){
return /^(([0-2]?[0-9]:[0-5][0-9])|([0-1]?[0-9]:[0-5][0-9]\s(am|pm)))$/.test(s);
},format:function(s){
return $.tablesorter.formatFloat(new Date("2000/01/01 "+s).getTime());
},type:"numeric"});
ts.addParser({id:"metadata",is:function(s){
return false;
},format:function(s,_585,cell){
var c=_585.config,p=(!c.parserMetadataName)?"sortValue":c.parserMetadataName;
return $(cell).metadata()[p];
},type:"numeric"});
ts.addWidget({id:"zebra",format:function(_588){
if(_588.config.debug){
var time=new Date();
}
$("tr:visible",_588.tBodies[0]).filter(":even").removeClass(_588.config.widgetZebra.css[1]).addClass(_588.config.widgetZebra.css[0]).end().filter(":odd").removeClass(_588.config.widgetZebra.css[0]).addClass(_588.config.widgetZebra.css[1]);
if(_588.config.debug){
$.tablesorter.benchmark("Applying Zebra widget",time);
}
}});
})(jQuery);
(function($){
var _58b=function(){
var _58c=$.support.style;
var _58d=0;
var _58e=0;
var _58f=$("div.taskbar");
for(var t=0;t<_58f.length;t++){
var _591=$("li",_58f[t]);
var _592=0;
for(var i=0;i<_591.length;i++){
var _594=$(_591[i]).height();
if(_594>_592){
_592=_594+4;
}
}
if(_58c==false){
_58e=0;
}
if(_58c==false&&_592<72){
_58d=25;
}
for(var i=0;i<_591.length;i++){
$(_591[i]).height(_592-_58d);
$("button",_591[i]).height(_592-_58d);
$("button span.icon",_591[i]).height(_592-54);
var _595=$("button span.icon",_591[i]).width();
if(_595<=60){
$("button",_591[i]).width(60);
$("button span.icon",_591[i]).width(54);
}else{
if(_595>=1000){
$("button",_591[i]).width(100+_58e);
$("button span.icon",_591[i]).width(88);
}else{
$("button",_591[i]).width(_595+17+_58e);
$("button span.icon",_591[i]).width(_595);
}
}
}
$(_58f[t]).height(_592+2-_58d);
$("div div div",_58f[t]).height(_592+2-_58d);
}
};
$.dr.addDomReadyEvent(_58b,"domReadyEarly");
})(jQuery);
DR.Widgets.ToolTip=function(_596,_597){
if(DR.Utils.BrowserDetect.isIE6()){
return null;
}
this.refObj=_596;
this.edgeX="Left";
this.edgeY="Bottom";
this.drawDirectionX="Right";
this.drawDirectionY="Down";
this._type=_597;
this.mouseOverTimeOut=1100;
this.mouseOutTimeOut=300;
if(_597=="menuTooltip"){
this.cssClass="menuTooltip";
this._offsetX=7;
this._offsetY=0;
this.edgeX="Right";
this.edgeY="Top";
}else{
if(_597=="codePreview"){
this.cssClass="menuTooltip";
this._offsetX=0;
this._offsetY=2;
this.edgeX="Right";
this.edgeY="Top";
}else{
this.cssClass="taskTooltip";
this._offsetX=0;
this._offsetY=5;
this.edgeX="Left";
this.edgeY="Bottom";
}
}
this.drawDirectionX="Right";
this.drawDirectionY="Down";
this.shadowOffset=4;
this.init();
};
DR.Widgets.ToolTip.prototype={init:function(){
if(this.refObj.title!=undefined){
if(this.refObj.title.trim()!=""){
this.build();
var _598=this;
var _599=function(){
_598.markToShow=true;
window.setTimeout(function(){
if(_598.markToShow){
_598.show();
}
},this.mouseOverTimeOut);
};
var _59a=function(){
_598.markToShow=false;
window.setTimeout(function(){
if(!_598.markToShow){
_598.hide();
}
},this.mouseOutTimeOut);
};
var hide=function(){
_598.hide();
};
jQuery(this.refObj).mouseover(_599);
jQuery(this.refObj).mouseout(_59a);
jQuery(this.refObj).click(hide);
jQuery(this.tooltip).mouseover(_599);
jQuery(this.tooltip).mouseout(_59a);
jQuery(this.tooltip).click(hide);
}
}
},build:function(){
var d=document.createElement("div");
d.className=this.cssClass;
d.innerHTML=this.refObj.title;
this.refObj.removeAttribute("title");
DR.Utils.addToBody(d);
this.tooltip=d;
var s=document.createElement("div");
s.className="taskTooltipShadow";
s.innerHTML="&nbsp;";
DR.Utils.addToBody(s);
this.shadow=s;
},show:function(){
var _59e=jQuery(this.tooltip).height()+2*10+2*1;
var _59f=jQuery(this.tooltip).width()+2*10+2*1;
var _5a0=jQuery(window).height();
if(_59e>_5a0){
_59e=_5a0-200;
this.tooltip.style.height=(_59e+2*10+2*1)+"px";
}
this.tooltip.style.display="block";
this.shadow.style.height=_59e+"px";
this.shadow.style.width=_59f+"px";
this.shadow.style.display="block";
this._position();
},hide:function(){
this.shadow.style.display="none";
this.tooltip.style.display="none";
},_position:function(){
DR.Utils.Position.snapTo(this.refObj,this.tooltip,this._offsetX,this._offsetY,this.edgeX,this.edgeY,this.drawDirectionX,this.drawDirectionY,true);
this.shadow.style.top=(parseInt(this.tooltip.style.top,10)+this.shadowOffset)+"px";
this.shadow.style.left=(parseInt(this.tooltip.style.left,10)+this.shadowOffset)+"px";
}};
$.fn.dr_toolTip=function(type){
return this.each(function(){
type=(type)?type:"taskTooltip";
if(this.tooltip===undefined){
this.tooltip=new DR.Widgets.ToolTip(this,type);
}
});
};
DR.Widgets.TreeMenu=function(_5a2){
this.container=getElem(_5a2);
this.currentTreeNodeId=null;
this.currentTreeNodeHasChildren=false;
this.labelOnclick=null;
this.defaultNodeId="";
this.saveState=false;
this.saveSelectedItem="";
this.stateCookie=null;
this.cookieName="";
this.stateCookieSelected=null;
this.cookieSelectedName="";
this.rootNodeCookie=null;
this.rootNodeCookieID="";
this.ready=true;
this.checkBrowser();
};
DR.Widgets.TreeMenu.prototype={selectNode:function(obj){
var node=null;
var _5a5=false;
if(typeof obj=="object"){
node=obj.parentNode.parentNode;
}else{
if(typeof obj=="string"){
node=document.getElementById(obj);
_5a5=true;
}else{
return null;
}
}
var id=node.id;
id=id.replace("treeNode_","");
var _5a7=id;
id=id.replace("treeRoot_Node_","");
var _5a8=document.getElementById(node.id+"_child");
if(node.className=="treeNodeClosed"||node.className=="treeNodeClosedSelected"){
if(_5a8){
node.className="treeNodeOpenSelected";
_5a8.style.display="block";
}else{
node.className="treeNodeEmptySelected";
}
this.saveNodeState(id,"selected");
}else{
if(node.className=="treeNodeOpen"){
if(_5a8){
_5a8.style.display="block";
node.className="treeNodeOpenSelected";
}
this.saveNodeState(id,"selected");
}else{
if(node.className=="treeNodeEmptyOpen"||node.className=="treeNodeEmpty"||node.className=="treeNodeEmptySelected"){
node.className="treeNodeEmptySelected";
this.saveNodeState(id,"selected");
}else{
if(node.className=="doc"){
node.className="docSelected";
this.saveNodeState(id,"selected");
}
}
}
}
if(!this.ready){
this.makeVisible(node);
if(this.browserType=="IE"){
var _5a9=this;
var func=function(){
_5a9.scrollToNode(node);
};
window.setTimeout(func,100);
}else{
this.scrollToNode(node);
}
}
if(_5a5){
this.scrollToNode(node);
}
this.setCurrentNodeOff(node.id);
if(!_5a8){
this.currentTreeNodeHasChildren=false;
}else{
if(_5a8.childNodes.length>0){
this.currentTreeNodeHasChildren=true;
}
}
this.currentTreeNodeId=node.id;
if(typeof this.labelOnclick=="function"){
this.labelOnclick(id,node.id);
}
},scrollToNode:function(node){
var xpos=node.offsetLeft;
var ypos=node.offsetTop;
this.container.scrollTop=ypos;
this.container.scrollLeft=xpos;
},toggleNode:function(obj){
var node=null;
if(typeof obj=="object"){
node=obj.parentNode.parentNode;
}else{
if(typeof obj=="string"){
if(obj.length==0){
log("hi");
}
node=document.getElementById(obj);
}else{
return null;
}
}
var id=node.id;
id=id.replace("treeNode_","");
var _5b1=document.getElementById(node.id+"_child");
if(node.className=="treeNodeClosed"){
if(_5b1){
node.className="treeNodeOpen";
_5b1.style.display="block";
this.saveNodeState(id,"open");
}else{
node.className="treeNodeEmpty";
}
}else{
if(node.className=="treeNodeClosedSelected"){
node.className="treeNodeOpenSelected";
_5b1.style.display="block";
this.saveNodeState(id,"open");
}else{
if(node.className=="treeNodeOpen"){
if(_5b1){
_5b1.style.display="none";
node.className="treeNodeClosed";
this.saveNodeState(id,"closed");
}
}else{
if(node.className=="treeNodeOpenSelected"){
if(_5b1){
_5b1.style.display="none";
node.className="treeNodeClosedSelected";
this.saveNodeState(id,"closed");
}
}
}
}
}
},saveNodeState:function(id,_5b3){
if(typeof id=="string"&&this.ready){
if(this.saveState){
if(_5b3=="open"){
this.stateCookie.addArrayValue(id);
}else{
if(_5b3=="closed"){
this.stateCookie.removeArrayValue(id);
}else{
if(_5b3=="selected"){
this.stateCookie.addArrayValue(id);
}
}
}
}
if(this.saveSelectedItem&&_5b3=="selected"){
this.stateCookieSelected.setValue(id);
}
}
},setCurrentNodeOff:function(id){
if(this.currentTreeNodeId!==null&&this.currentTreeNodeId!=id){
var node=document.getElementById(this.currentTreeNodeId);
if(node){
if(node.className=="docSelected"){
node.className="doc";
}else{
if(this.currentTreeNodeHasChildren){
node.className="treeNodeOpen";
}else{
node.className="treeNodeEmpty";
}
}
}
}
},setLabelOnlick:function(func){
if(typeof func=="function"){
this.labelOnclick=func;
}
},setDefaultNodeId:function(id){
if(typeof id=="string"){
this.defaultNodeId=id;
}
},setRootNodeId:function(id){
if(typeof id=="string"){
this.rootNodeCookie=new DR.Utils.Cookie(this.cookieName+"_rootID");
this.rootNodeCookie.type="Single";
this.rootNodeCookie.load();
var v=this.rootNodeCookie.value;
if(v!=id&&v!==""&&v!==null){
if(this.saveState){
this.stateCookie.clear();
}
if(this.saveSelectedItem){
this.stateCookieSelected.clear();
}
this.initCookies();
}
this.rootNodeCookie.setValue(id);
}
},goUp:function(){
var node=document.getElementById(this.currentTreeNodeId);
if(node){
var _5bb=node.parentNode.parentNode;
this.selectNode(_5bb.id);
}
},enableSaveState:function(_5bc){
if(typeof _5bc=="string"){
this.cookieName=_5bc;
this.saveState=true;
this.saveSelectedItem=true;
this.initCookies();
}
},enableLastSelected:function(_5bd){
if(typeof _5bd=="string"){
this.cookieName=_5bd;
this.saveSelectedItem=true;
this.initCookies();
}
},initCookies:function(){
if(this.cookieName!==""){
if(this.saveState){
this.stateCookie=new DR.Utils.Cookie(this.cookieName);
this.stateCookie.type="Array";
this.stateCookie.load();
}
if(this.saveSelectedItem){
this.cookieSelectedName=this.cookieName+"_on";
this.stateCookieSelected=new DR.Utils.Cookie(this.cookieSelectedName);
this.stateCookieSelected.type="Single";
this.stateCookieSelected.load();
}
}
},refreshState:function(){
if(this.cookieName!==""){
this.ready=false;
if(this.saveState){
var a=this.stateCookie.arrayValues;
for(var i=0;i<a.length;i++){
if(a[i]!=v){
if(document.getElementById("treeNode_"+a[i])){
this.toggleNode("treeNode_"+a[i]);
}else{
this.stateCookie.removeArrayValue(a[i]);
}
}
}
}
if(this.saveSelectedItem){
var v=this.stateCookieSelected.value;
if(v!==""&&v!==null&&document.getElementById("treeNode_"+v)){
this.selectNode("treeNode_"+v);
}else{
if(this.defaultNodeId!==""){
this.selectNode(this.defaultNodeId);
}
}
}
this.ready=true;
}
},makeVisible:function(obj){
var p=obj.parentNode;
while(p){
if((p.tagName=="BODY")||(p.tagName=="HTML")){
break;
}
if(p.className=="treeNodeClosed"){
this.toggleNode(p.id);
}
p=p.parentNode;
}
},checkBrowser:function(){
if(document.all){
this.browserType="IE";
}else{
this.broswerType="Standard";
}
}};
(function($){
var _5c4="fckeditor.js",SCRIPT_LOADING=false,REFRESH_INTERVAL=500,EDITORS=[],CUSTOM_TOOLBAR_SETS=[],DEFAULT_CONFIG={BasePath:DR.FRAMEWORK_PATH+"external/fckeditor/",Width:"700",Height:"300",ToolbarSet:"default"};
var _5c5=function(){
return (typeof FCKeditor_IsCompatibleBrowser=="function")?true:false;
};
var _5c6=function(){
return (typeof FCKeditorAPI=="undefined")?false:true;
};
var _5c7=function(id){
return FCKeditorAPI.GetInstance(id);
};
var _5c9=function(html){
var h=html.replace(/\<b\>/g,"<strong>");
h=h.replace(/\<\/b>/g,"</strong>");
h=h.replace(/\<i>/g,"<em>");
h=h.replace(/\<\/i>/g,"</em>");
return h;
};
var _5cc=function(_5cd,id,_5cf){
this.textareaObj=_5cd;
this.id=id;
this.editorObj=null;
var c=$.extend({},DEFAULT_CONFIG);
this.config=(_5cf)?$.extend(c,_5cf):c;
this.refreshTimer=null;
this.init();
};
_5cc.prototype={init:function(){
if(_5c5()){
this.bindEditor();
}else{
if(!SCRIPT_LOADING){
this.loadScript();
}else{
this.checkScriptReady();
}
}
},loadScript:function(){
var _5d1=this;
SCRIPT_LOADING=true;
$.getScript(this.config.BasePath+_5c4,function(){
SCRIPT_LOADING=false;
_5d1.checkScriptReady();
});
},checkScriptReady:function(){
var _5d2=this;
var func=function(){
if(_5c5()){
_5d2.bindEditor();
}else{
_5d2.checkScriptReady();
}
};
window.setTimeout(func,100);
},bindEditor:function(){
var _5d4=new FCKeditor(this.id);
$.extend(true,_5d4,this.config);
_5d4.ReplaceTextarea();
this.editorObj=_5d4;
this.checkAPIReady();
},checkAPIReady:function(){
var _5d5=this;
var func=function(){
if(_5c6()){
var _5d7=_5c7(_5d5.id);
if(typeof _5d7=="undefined"){
_5d5.checkAPIReady();
}else{
if(typeof _5d7.EditorDocument=="undefined"){
_5d5.checkAPIReady();
}else{
_5d5.synchronize();
}
}
}else{
_5d5.checkAPIReady();
}
};
window.setTimeout(func,10);
},synchronize:function(){
var _5d8=this;
var _5d9=function(){
_5d8.updateTextarea();
_5d8.synchronize();
};
this.refreshTimer=window.setTimeout(_5d9,REFRESH_INTERVAL);
},updateTextarea:function(a){
this.textareaObj.value=this.getHTML();
},setHTML:function(html){
var _5dc=_5c7(this.id);
if(!_5dc){
return undefined;
}else{
html=_5c9(html);
_5dc.SetHTML(html);
}
},getHTML:function(){
var _5dd=_5c7(this.id);
if(typeof _5dd!="undefined"){
return _5dd.GetXHTML(true);
}
return undefined;
}};
$.namespace("dr",{wysiwyg:function(_5de){
DEFAULT_CONFIG.BasePath=DR.FRAMEWORK_PATH+"external/fckeditor/";
this.each(function(){
if(this.tagName.toLowerCase()=="textarea"){
if(!this.wysiwyg){
var id=this.id||this.name;
if(EDITORS[id]){
clearTimeout(EDITORS[id].refreshTimer);
EDITORS[id]=null;
}
this.value=_5c9(this.value);
var _5e0=new _5cc(this,id,_5de);
EDITORS[id]=_5e0;
this.wysiwyg=_5e0;
}
}
});
return this;
}});
$.namespace("dr.wysiwyg",{setHTML:function(html){
this.each(function(){
if(this.wysiwyg){
this.wysiwyg.setHTML(html);
}
});
return this;
},getHTML:function(html){
if(this.length){
var elem=this[0];
var h="";
if(elem.wysiwyg){
h=elem.wysiwyg.getHTML();
}
return h;
}
return undefined;
}});
$.dr.wysiwyg={setDefaultConfig:function(_5e5){
if(typeof _5e5=="object"){
$.extend(DEFAULT_CONFIG,_5e5);
}
},addToolbarSet:function(_5e6){
if(typeof _5e6=="object"){
if(_5e6.name&&_5e6.settings){
CUSTOM_TOOLBAR_SETS.push(_5e6);
}
}
},getCustomToolbarSets:function(){
return CUSTOM_TOOLBAR_SETS;
}};
var _5e7=function(_5e8){
_5e8.filter("textarea.basic_wysiwyg, textarea.wysiwyg").each(function(){
var $obj=$(this);
if($obj.hasClass("basic_wysiwyg")){
$obj.dr.wysiwyg({ToolbarSet:"basic"});
}else{
$obj.dr.wysiwyg();
}
});
};
$.dr.addPlugin("form",_5e7);
})(jQuery);
String.THOUSANDS_SEPARATOR=",";
String.prototype.formatNumber=function(){
return this.replace(/\d{1,3}(?=(\d{3})+(?!\d))/g,"$&"+String.THOUSANDS_SEPARATOR);
};
Date.prototype.dr_getDOY=function(){
var _5ea=new Date(this.getFullYear(),0,1);
return Math.ceil((this-_5ea)/86400000);
};
jQuery.dr=window.jQuery.dr||{};
$.dr.baseChart={initChart:function(_5eb){
var obj=$("#"+_5eb);
if(obj.hasClass("stockChartContainer")){
if(!(window[_5eb] instanceof $.dr.stockChart)){
try{
window[_5eb]=new $.dr.stockChart(_5eb);
window[_5eb].initChart(_5eb+"_flashObjectId");
}
catch(e){
}
}
}
}};
amChartInited=function(_5ed){
$.dr.baseChart.initChart(_5ed);
};
amProcessCompleted=function(_5ee,_5ef){
if(window[_5ee]){
window[_5ee].processCompletedCallback(_5ef);
}
};
window.amReturnData=function(_5f0,data){
if(window[_5f0]){
window[_5f0].returnDataCallback(unescape(data));
}
};
window.amReturnSettings=function(_5f2,_5f3){
if(window[_5f2]){
window[_5f2].returnSettingsCallback(_5f3);
}
};
window.amReturnParam=function(_5f4,_5f5){
if(window[_5f4]){
window[_5f4].returnParamCallback(_5f5);
}
};
window.amError=function(_5f6,_5f7){
if(window[_5f6]){
window[_5f6].errorCallback(_5f7);
}
};
window.amRolledOver=function(_5f8,date,_5fa){
if(window[_5f8]){
window[_5f8].rolledOverCallback(date,_5fa);
}
};
window.amClickedOn=function(_5fb,date,_5fd){
if(window[_5fb]){
window[_5fb].clickedOnCallback(date,_5fd);
}
};
window.amRolledOverEvent=function(_5fe,date,_600,id,url){
if(window[_5fe]){
window[_5fe].rolledOverEventCallback(date,_600,id,url);
}
};
window.amClickedOnEvent=function(_603,date,_605,id,url){
if(window[_603]){
window[_603].clickedOnEventCallback(date,_605,id,url);
}
};
window.amGetZoom=function(_608,from,to){
if(window[_608]){
window[_608].getZoomCallback(from,to);
}
};
window.amReturnImageData=function(_60b,data){
};
window.amSliceClick=function(_60d,_60e,_60f,_610,_611,_612,_613){
};
window.amSliceOver=function(_614,_615,_616,_617,_618,_619,_61a){
};
window.amSliceOut=function(_61b){
};
(function($){
var _61d=function(_61e){
var did=$(_61e).val();
var _620=[];
_620.push("<data_sets>");
_620.push("<data_set did='"+did+"'>");
_620.push("<compare_list_box selected='true' /></data_set></data_sets>");
return _620.join("");
};
var _621=function(_622){
var _623=$(_622).attr("dr:chart");
var _624=$(_622).attr("id");
var _625=$(":selected",_622).text();
var _626=$(_622).val();
var _627=_626;
var _628=[];
_628.push("<charts>");
_628.push("<chart cid='"+((_623!=null)?_623:0)+"'>");
_628.push("<title>"+_625+"</title>");
_628.push("<graphs>");
_628.push("<graph gid='0'>");
_628.push("<data_sources>");
_628.push("<close>"+_626+"</close>");
_628.push("</data_sources>");
_628.push("<compare_source>"+_627+"</compare_source>");
_628.push("<legend><date key='false' title='false'><![CDATA[{close}]]></date><period key='false' title='false'> <![CDATA[<b>{close}</b>]]></period></legend>");
_628.push("</graph></graphs></chart></charts>");
if(_623==0){
_628.push("<scroller><graph_data_source>"+_626+"</graph_data_source></scroller>");
}
DR.USER_DATA.save("sitePulseHomeDetail"+GC.CURRENT_SITE_ID,_624,_626,"String");
return _628.join("");
};
var _629=function(_62a,_62b){
var _62c=[];
_62c.push("<period_selector><from>");
_62c.push(new $.dr.date($(_62a).val(),DR.USER_DATE_FORMAT).toFormattedString(_62b));
_62c.push("</from></period_selector>");
return _62c.join("");
};
var _62d=function(_62e,_62f){
var _630=[];
var _631=new $.dr.date($(_62e).val(),DR.USER_DATE_FORMAT);
_631.setDate(_631.getDate()+1);
_630.push("<period_selector><to>");
_630.push(_631.toFormattedString(_62f));
_630.push("</to></period_selector>");
return _630.join("");
};
var _632=function(_633){
var _634=[];
$(".changeGraphColumn",_633.chartContainerObj).change(function(_635){
_633.changeGraphSrcColumn(_635.target);
});
$(".applyGraphColumn",_633.chartContainerObj).each(function(){
_634.push(this);
});
return _634;
};
var _636=function(_637){
var _638=[];
$(".applySettings",_637.chartContainerObj).each(function(){
_638.push(this);
$(this).click(function(_639){
_637.applySettings(_639.target);
});
});
return _638;
};
var _63a=function(_63b){
var _63c=null;
$(".changeCompareTo:first",_63b.chartContainerObj).change(function(_63d){
_63b.changeCompareTo(_63d.target);
});
$(".applyCompareTo:first",_63b.chartContainerObj).each(function(){
_63c=this;
});
return _63c;
};
var _63e=function(_63f){
$("select.changeData").change(function(){
_63f.changeSelectDataSet($(this).val());
}).keyup(function(){
_63f.changeSelectDataSet($(this).val());
});
};
var _640=function(_641){
var _642=null;
$(".applyRangeStart:first",_641).each(function(){
_642=this;
});
return _642;
};
var _643=function(_644){
var _645=null;
$(".applyRangeEnd:first",_644).each(function(){
_645=this;
});
return _645;
};
var _646=function(_647){
var _648=[];
$(".dynamicHighlight",_647).each(function(){
var _649=this.getAttribute("dr:precision");
var _64a=this.getAttribute("dr:prefix");
var _64b=this.getAttribute("dr:suffix");
_648.push({elemObj:this,precision:(_649!=null&&!isNaN(_649))?_649:2,formula:this.getAttribute("dr:formula"),prefix:(_64a)?_64a:"",suffix:(_64b)?_64b:""});
});
return _648;
};
var _64c=function(_64d){
$(".staticHighlightControl",_64d.chartContainerObj).change(function(_64e){
_64d.changeStaticHighlight(_64e.target);
});
};
var _64f=function(_650){
var _651=[];
$(".staticHighlight",_650).each(function(){
var _652=this.getAttribute("dr:precision");
var _653=this.getAttribute("dr:prefix");
var _654=this.getAttribute("dr:suffix");
var _655=this.getAttribute("dr:typeRef");
var type=this.getAttribute("dr:type");
_651.push({elemObj:this,precision:(_652!=null&&!isNaN(_652))?_652:2,formula:this.getAttribute("dr:formula"),prefix:(_653)?_653:"",suffix:(_654)?_654:"",type:type,typeRef:_655});
});
return _651;
};
var _657=function(_658){
var _659=_658.indexOf("<columns>");
var _65a=_658.indexOf("</columns>");
var _65b=[];
if(_659>-1&&_65a>-1){
_65b=_658.substring(_659+9,_65a);
_65b=_65b.split("<column>").join("").split("</column>");
_65b=(_65b instanceof Array)?_65b:[];
}
return _65b;
};
var _65c=function(col,_65e){
var pos=-1;
if(!isNaN(col)){
pos=col;
}else{
pos=$.inArray(col,_65e);
}
return pos;
};
var _660=function(_661){
_661.getSettings();
};
var _662=function(_663){
_663.getData(0);
};
var _664=function(_665,_666){
_665.compareDataSet(_666);
};
var _667=function(_668,_669){
_668.uncompareDataSet(_669);
};
var _66a=function(_66b){
_66b.uncompareAll();
};
var _66c=function(_66d,_66e){
_66d.selectDataSet(_66e);
};
var _66f=function(_670){
_670.hideEvents();
};
var _671=function(_672){
_672.showEvents();
};
var _673=function(_674){
_674.showAll();
};
var _675=function(_676,data){
_676.setData(data);
};
var _678=function(_679){
_679.rebuild();
};
var _67a=function(_67b){
_67b.reloadData();
};
var _67c=function(_67d,_67e){
_67d.reloadSettings(_67e);
};
var _67f=function(_680,_681,_682,_683){
var _684=[];
_684.push("<settings>");
_684.push(_681);
_684.push("</settings>");
_680.setSettings(_684.join(""),_682,_683);
};
var _685=function(_686,data,_688){
_686.appendData(data,_688);
};
var _689=function(_68a,_68b,_68c){
_68a.getParam(_68b);
};
var _68d=function(_68e,from,to,_691){
var _692=new $.dr.date(to,_691);
_692.setDate(_692.getDate()+1);
_68e.setZoom(from,_692.toFormattedString());
};
var _693=function(_694,_695){
var _696=0;
var days=1;
var _698=$.dr.stockChart.STATIC_TYPES;
if(_694.typeRef){
_694.type=$("#"+_694.typeRef).val();
}
if(_694.type){
for(var t in _698){
if(t==_694.type){
_696=_698[t].offset;
days=_698[t].days;
break;
}
}
}
_694.chartObj=_695;
_694.startOffset=_696;
_694.numDays=days;
_694.avg=function(_69a){
return _695.staticData.avg(this,_69a);
};
_694.sum=function(_69b){
return _695.staticData.sum(this,_69b);
};
var _69c="0";
with(_694){
_69c=eval(formula);
if(!isNaN(_69c)){
_69c=prefix+_69c.toFixed(precision).formatNumber()+suffix;
}else{
_69c=$.dr.stockChart.DATA_NOT_AVAILABLE;
}
}
$(_694.elemObj).html(_69c);
};
$.dr.stockChart=function(_69d,_69e){
this.dataDateFmt=(_69e)?_69e:"yyyy-mm-dd";
this.chartPrefix=_69d;
var _69f=$("#"+this.chartPrefix);
this.chartContainerObj=(_69f.length>0)?_69f:document;
};
$.dr.stockChart.prototype={initChart:function(id){
this.flashChartObj=document.getElementById(id);
this.dynamicHighlights={};
this.staticHighlights=[];
this.controls={};
this.controls.apply=[];
this.controls.graphColumn=[];
this.controls.fromDate=_640(this.chartContainerObj);
this.controls.toDate=_643(this.chartContainerObj);
this.controls.compareTo=_63a(this);
this.controls.changeDataSet=_63e(this);
this.controls.apply=_636(this);
this.controls.graphColumn=_632(this);
_64c(this);
this.staticHighlights=_64f(this.chartContainerObj);
this.dynamicHighlights=_646(this.chartContainerObj);
this.rangeFromDate=null;
this.rangeToDate=null;
this.chartSettingsXML=null;
this.columnNames=[];
this.isDataLoaded=false;
this.chartData=null;
this.numDataColumns=0;
this.dataPoints=0;
this.chartDataLoc=[];
this.dataStartDate=null;
this.dataEndDate=null;
this.rangeTotals=[];
this.rangeAverages=[];
this.rangeDataPoints=0;
if(!this.rangeFromDate&&this.controls.fromDate){
this.rangeFromDate=new $.dr.date($(this.controls.fromDate).val(),DR.USER_DATE_FORMAT).toFormattedString(this.dataDateFmt);
}
if(!this.rangeToDate&&this.controls.toDate){
this.rangeToDate=new $.dr.date($(this.controls.toDate).val(),DR.USER_DATE_FORMAT).toFormattedString(this.dataDateFmt);
}
_660(this.flashChartObj);
this.columnNames=_657(this.chartSettingsXML);
_662(this.flashChartObj);
this.dataStartDate=this.chartData[0][0];
this.dataEndDate=this.chartData[this.chartData.length-1][0];
this.updateStaticHighlights();
this.getZoomCallback(this.rangeFromDate,this.rangeToDate);
this.syncBoundControls();
},syncBoundControls:function(){
for(var _6a1 in this.controls){
switch(_6a1){
case "compareTo":
break;
case "graphColumn":
for(var c=0;c<this.controls[_6a1].length;c++){
}
break;
case "fromDate":
break;
case "toDate":
break;
default:
break;
}
}
},setCustomDateControls:function(_6a3,end){
if(this.controls.toDate){
$(this.controls.toDate).val(new $.dr.date(this.rangeToDate,this.dataDateFmt).toFormattedString(DR.USER_DATE_FORMAT));
}
if(this.controls.fromDate){
$(this.controls.fromDate).val(new $.dr.date(this.rangeFromDate,this.dataDateFmt).toFormattedString(DR.USER_DATE_FORMAT));
}
},getZoomCallback:function(from,to){
this.rangeFromDate=from;
this.rangeToDate=to;
this.setCustomDateControls();
this.update();
},rolledOverCallback:function(date,_6a8){
},processCompletedCallback:function(_6a9){
_660(this.flashChartObj);
},errorCallback:function(_6aa){
},clickedOnCallback:function(date,_6ac){
if(_6ac=="DD"){
_68d(this.flashChartObj,date,date,this.dataDateFmt);
}else{
if(_6ac=="WW"){
var _6ad=new $.dr.date(date,this.dataDateFmt);
_6ad.setDate(_6ad.getDate()+6);
_68d(this.flashChartObj,date,_6ad.toFormattedString(),this.dataDateFmt);
}else{
if(_6ac=="MM"){
var _6ad=new $.dr.date(date,this.dataDateFmt);
_6ad.setMonth(_6ad.getMonth()+1);
_6ad.setDate(_6ad.getDate()-1);
_68d(this.flashChartObj,date,_6ad.toFormattedString(),this.dataDateFmt);
}
}
}
},rolledOverEventCallback:function(date,_6af,id,url){
},clickedOnEventCallback:function(date,_6b3,id,url){
},returnSettingsCallback:function(_6b6){
this.chartSettingsXML=unescape(_6b6);
},returnDataCallback:function(_6b7){
var _6b8=new Date().getTime();
this.chartData=_6b7.split("\n");
this.chartData.reverse();
for(var i=0;i<this.chartData.length;i++){
var temp=this.chartData[i].split(",");
if(temp.length>1){
this.chartData[i]=temp;
this.chartDataLoc[i]=this.chartData[i][0];
temp=null;
}else{
var _6bb=this.chartData.splice(i,1);
i--;
}
}
var _6bc=new Date().getTime();
this.dataPoints=this.chartData.length;
this.numDataColumns=this.chartData[0].length;
this.isDataLoaded=true;
_6b7=null;
},returnParamCallback:function(_6bd){
},changeStaticHighlight:function(obj){
var _6bf=obj.id;
for(var i=0;i<this.staticHighlights.length;i++){
var _6c1=this.staticHighlights[i];
for(var r in _6c1){
if(r=="typeRef"&&_6c1[r]==_6bf){
_693(this.staticHighlights[i],this);
}
}
}
},updateStaticHighlights:function(){
for(var i=0;i<this.staticHighlights.length;i++){
_693(this.staticHighlights[i],this);
}
},staticData:{avg:function(_6c4,col){
var _6c6=this.sum(_6c4,col)/_6c4.numDays;
return Number(_6c6);
},sum:function(_6c7,col){
var _6c9=_65c(col,_6c7.chartObj.columnNames);
var _6ca=Number.NaN;
var _6cb=(_6c7.chartObj.chartData.length-1)-_6c7.startOffset;
var _6cc=_6cb-(_6c7.numDays);
if(_6c9>-1){
_6ca=0;
for(var i=_6cb;i>_6cc;i--){
var val=Number(_6c7.chartObj.chartData[i][_6c9]);
_6ca+=((val==NaN)?0:val);
}
}
return Number(_6ca);
}},changeCompareTo:function(_6cf){
var _6d0=$(_6cf).val();
_66a(this.flashChartObj);
if(_6d0!=""){
_664(this.flashChartObj,_6d0);
}
},changeSelectDataSet:function(data){
_66c(this.flashChartObj,data);
},changeGraphSrcColumn:function(_6d2){
var _6d3=_621(_6d2);
_67f(this.flashChartObj,_6d3,true);
},applySettings:function(){
var _6d4=[];
for(var _6d5 in this.controls){
switch(_6d5){
case "compareTo":
break;
case "graphColumn":
for(var c=0;c<this.controls[_6d5].length;c++){
_6d4.push(_621(this.controls[_6d5][c]));
}
break;
case "fromDate":
_6d4.push(_629(this.controls.fromDate,this.dataDateFmt));
break;
case "toDate":
_6d4.push(_62d(this.controls.toDate,this.dataDateFmt));
break;
default:
break;
}
}
_67f(this.flashChartObj,_6d4.join(""),true);
},update:function(){
if(!this.isDataLoaded){
var _6d7=this;
window.setTimeout(function(){
_6d7.update();
},1000);
}else{
var _6d8=parseInt(jQuery.inArray(this.rangeToDate,this.chartDataLoc));
var _6d9=parseInt(jQuery.inArray(this.rangeFromDate,this.chartDataLoc));
this.rangeDataPoints=(_6d8-_6d9)+1;
for(var col=1;col<this.numDataColumns;col++){
this.rangeTotals[col]=0;
this.rangeAverages[col]=0;
}
for(var row=_6d9;row<=_6d8;row++){
for(var col=1;col<this.numDataColumns;col++){
var val=Number(this.chartData[row][col]);
this.rangeTotals[col]=this.rangeTotals[col]+((val==NaN)?0:val);
}
}
for(var _6dd=1;_6dd<this.rangeTotals.length;_6dd++){
this.rangeAverages[_6dd]=this.rangeTotals[_6dd]/this.rangeDataPoints;
}
this.updateDynamicHighlights();
}
},sum:function(col){
var _6df=_65c(col,this.columnNames);
return (_6df>-1)?this.rangeTotals[_6df]:Number.NaN;
},avg:function(col){
var _6e1=_65c(col,this.columnNames);
return (_6e1>-1)?this.rangeAverages[_6e1]:Number.NaN;
},dataPoints:function(){
return this.rangeDataPoints;
},updateDynamicHighlights:function(){
for(var _6e2 in this.dynamicHighlights){
var _6e3=this.dynamicHighlights[_6e2];
var _6e4=0;
with(this){
_6e4=eval(_6e3.formula);
if(!isNaN(_6e4)){
_6e4=_6e3.prefix+_6e4.toFixed(_6e3.precision).formatNumber()+_6e3.suffix;
}else{
_6e4=$.dr.stockChart.DATA_NOT_AVAILABLE;
}
}
$(_6e3.elemObj).html(_6e4);
}
}};
$.dr.stockChart.DATA_NOT_AVAILABLE="n/a";
$.dr.stockChart.SUM="sum";
$.dr.stockChart.AVG="avg";
$.dr.stockChart.TEXT="text";
$.dr.stockChart.VALUE="value";
$.dr.stockChart.DOY=new Date().dr_getDOY();
$.dr.stockChart.STATIC_TYPES={mtd:{offset:0,days:new Date().getDate()},ytd:{offset:0,days:$.dr.stockChart.DOY},wtd:{offset:0,days:new Date().getDay()+1},prev365:{offset:364,days:365},prev7:{offset:6,days:7},prev90:{offset:89,days:90},prev30:{offset:29,days:30},prev1:{offset:1,days:1},cur1:{offset:0,days:1},cur365:{offset:0,days:365},cur90:{offset:0,days:90},cur30:{offset:0,days:30},cur7:{offset:0,days:7}};
})(jQuery);
(function($){
$.namespace("dr",{equalize:function(){
$(this).each(function(){
var _6e6=0;
$(this).children().each(function(i){
_6e6=$(this).height()>_6e6?$(this).height():_6e6;
});
if($.browser.msie&&$.browser.version==6){
$(this).children().css({"height":_6e6});
}else{
$(this).children().css({"min-height":_6e6});
}
});
return $(this);
}});
})(jQuery);
(function($){
var _6e9=function(){
$(".iconWell").find(".menu > ul",this).dr.shadows();
$("> li",".iconWell").hover(function(){
$(this).addClass("hover");
},function(){
$(this).removeClass("hover");
});
};
$.dr.addDomReadyEvent(_6e9,"domReadyEarly");
})(jQuery);
(function($){
$.namespace("dr",{navigation:function(){
var _6eb=$(this),timeout="",fadeSpeed=!$.browser.msie?"fast":0;
var _6ec=[{"open":"100","close":"800"}];
var rows={"dfltCol":"3","oneCol":"1","twoCol":"2"};
var _6ee=function(_6ef,_6f0){
childWidth=$(_6f0).width();
windowWidth=$(window).width();
posX=$(_6ef).offset().left;
targetPosX=posX-(childWidth*0.05)-10;
if((targetPosX+childWidth)>windowWidth){
targetPosX=windowWidth-childWidth;
}else{
if(targetPosX<0){
targetPosX=0;
}
}
return targetPosX;
};
var _6f1=function(){
$(".menu",_6eb).each(function(idx){
$(this).css({"left":_6ee($(this).parent(),$(this))+"px","display":"none"});
});
};
var _6f3=function(){
var _6f4="";
for(var key in rows){
if($(this).attr("class").match(key)){
_6f4=rows[key];
}
}
return _6f4=_6f4==""?rows.dfltCol:_6f4;
};
return this.each(function(){
$(".menu",this).bind("menuOpen",function(e){
var _6f7=$(e.target);
if(typeof (timeout)!="undefined"){
clearTimeout(timeout);
}
timeout=setTimeout(function(){
_6f7.fadeIn(fadeSpeed,function(){
_6f7.data("active",true);
});
},_6f7.data("interval").open);
}).bind("menuClose",function(e){
var _6f9=$(e.target);
if(typeof (timeout)!="undefined"){
clearTimeout(timeout);
}
if(_6f9.data("active")){
timeout=setTimeout(function(){
_6f9.fadeOut(fadeSpeed,function(){
_6f9.data("active",false).parent().removeClass("hover");
});
},_6f9.data("interval").close);
}else{
_6f9.hide().parent().removeClass("hover");
}
}).each(function(idx){
$(this).data("idx",idx).data("active",false).data("interval",{open:_6ec[$(this).parents(".menu").length].open,close:_6ec[$(this).parents(".menu").length].close});
}).find("a").click(function(){
$(".menu",_6eb).hide();
}).end().find("> ul").dr.shadows().each(function(){
var _6fb=$(this),rowHeights=[];
$(this).children().each(function(_6fc){
var row=_6fc==0?0:Math.floor(_6fc/_6f3.call(_6fb));
$(this).data("row",row);
if(typeof (rowHeights[row])=="undefined"){
rowHeights[row]=0;
}
rowHeights[row]=$(this).height()>rowHeights[row]?$(this).height():rowHeights[row];
});
$(this).children().each(function(){
$(this).height(rowHeights[$(this).data("row")]);
});
});
$("> li",this).hover(function(){
$(".menu:not(:eq("+$(".menu",$(this)).data("idx")+"))",_6eb).hide().parent().removeClass("hover");
$(".menu",$(this)).trigger("menuOpen").parent().addClass("hover");
},function(){
$(".menu",$(this)).trigger("menuClose");
}).filter(":has(.menu)").find("> a").click(function(e){
e.preventDefault();
});
$(window).bind("load resize",_6f1);
});
}});
})(jQuery);
(function($){
var _700=function(){
$(".nav").dr.navigation();
};
$.dr.addDomReadyEvent(_700,"domReadyEarly");
})(jQuery);
(function($){
$.namespace("dr",{shadows:function(){
$(this).each(function(){
if(!$.browser.msie||$.browser.msie&&$.browser.version>6){
$(this).wrap($("<div class=\"shadow\"><div class=\"topLeft\"><div class=\"topRight\"></div></div></div>").append("<div class=\"bottomLeft\"></div><div class=\"bottomRight\"></div>"));
}else{
$(this.parentNode).bgIframe();
}
});
return $(this);
}});
})(jQuery);
(function($){
var _703={deepLink:true,activeTab:0,displayEffect:{animation:"fade",speed:"normal"}};
var _704=function(){
$(this).show();
};
$.namespace("dr",{tabs:function(_705){
var _706=$.extend(true,{},_703,_705);
var _707,currentPath,activeTab,tabIDArray=[],effectType=_706.displayEffect.animation.toLowerCase(),animation={show:$.fn.show,hide:$.fn.hide,speed:_706.displayEffect.speed};
if(effectType=="fade"){
animation=$.extend(animation,{show:$.fn.fadeIn,hide:$.fn.fadeOut});
}else{
if(effectType=="slide"){
animation=$.extend(animation,{show:$.fn.slideDown,hide:$.fn.slideUp});
}else{
if(effectType!="expand"){
animation.speed=0;
}
}
}
var _708=function(_709,_70a,_70b){
$(this).find("> dt").removeClass("active").eq(_709).toggleClass("active").end().end().find("> dd").hide().eq(_709).show();
_70a.call($(".tabContent",this).hide().eq(_709),_70b);
activeTab=_709;
};
var _70c=function(){
$this=$(this);
$this.find("> dt").each(function(_70d){
var _70e=encodeURI((_70d==0)?"/":"/"+$.trim($(this).text()).replace(/ /g,"-"));
$(this).data("label",_70e).data("count",_70d).click(function(){
$.address.value($(this).data("label"));
});
tabIDArray.push(_70e.toLowerCase());
});
$.address.change(function(_70f){
var _710=encodeURI($.trim(_70f.value)).toLowerCase();
var _711=$this.find("> dt").filter(function(){
var _712=$(this).data("label");
return (_712)?(_712.toLowerCase()==_710):false;
}).data("count");
if(activeTab!=_711&&currentPath!=_70f.path){
if(typeof activeTab==="undefined"&&typeof _707!=="undefined"&&_70f.path=="/"){
_711=_707;
}
var _713=false;
for(var i=0;i<tabIDArray.length;i++){
if(tabIDArray[i]==_710){
_708.call($this,_711,animation.show,animation.speed);
break;
}
}
}
currentPath=_70f.path;
});
$.address.init(function(_715){
var _716=setTimeout(function(){
_704.call($this);
},25);
});
};
var _717=function(){
var _718=this;
if($.address.ready()){
_70c.call(_718);
}else{
$(document).bind("onAddressActivated",function(){
_70c.call(_718);
});
$.address.activate();
}
};
return this.each(function(){
var _719=$(this);
var _71a=($(this).parents("dl.tabs").length>0)?true:false;
var _71b=(!_706.deepLink||$("body").hasClass("modalPage"))?false:true;
_719.hide().css("visibility","visible").wrap("<div class=\"tabSet\">").find("> dt").each(function(_71c){
var $dt=$(this).addClass("tab");
var link=$("a",this);
if(link.length>0){
$dt.addClass("tabLink");
_71b=false;
}else{
$dt.click(function(){
if(!_71b||_71a){
_708.call(_719,_71c,animation.show,animation.speed);
}
return false;
});
}
if(!$("+ dd",this).length){
$dt.after("<dd/>");
}
if($dt.hasClass("active")){
_707=_71c;
}
if(!$dt.hasClass("active")){
$dt.css({backgroundPosition:"0 -500px"}).mouseover(function(){
$(this).stop().animate({backgroundPosition:"(0px -535px)"},250);
}).mouseout(function(){
$(this).stop().animate({backgroundPosition:"0 -500px"},250);
});
}
}).eq(0).addClass("first").end().end().find("> dd").addClass("tabContainer").wrapInner("<div class=\"tabContent\">").appendTo(this);
if(!_71b||_71a){
_708.call(_719,_707||_706.activeTab,animation.show,1);
_704.call(_719);
}else{
_717.call(_719);
}
});
}});
$.dr.tabs={getDefaults:function(){
return _703;
},setDefaults:function(_71f){
if(_71f){
$.extend(_703,_71f);
}
$(document).trigger("afterTabSetDefaults",[_71f]);
}};
var _720=function(evt,_722){
$("dl.tabs",_722).dr.tabs();
};
$.dr.addUnobtrusiveEvent(_720,"unobtrusiveEventEarly");
})(jQuery);
(function($){
$.dr.timer={set:function(fn,len){
timeout=setTimeout(function(){
fn();
},len);
},clear:function(){
if(typeof (timeout)!="undefined"){
clearTimeout(timeout);
}
}};
})(jQuery);
function Color(){
this.red=0;
this.green=0;
this.blue=0;
this.hex="000000";
}
function HexColor(hex){
this.setHex(hex);
}
HexColor.prototype=new Color();
function RGBColor(r,g,b){
this.setRGBColor(r,g,b);
}
RGBColor.prototype=new Color();
Color.HEX_VALUES="0123456789ABCDEF";
Color.HEX_SYMBOL="#";
Color.DEC_VALUES="0123456789.%";
Color.PERCENT_SYMBOL="%";
Color.MSG_NOT_VALID_HEX_ERROR="Invalid hexidecimal code. Hexidecimal colors contain the following characters only: 0123456789ABCDEF.";
Color.rgbToHexColor=function(r,g,b){
return Color.decToHex(r)+Color.decToHex(g)+Color.decToHex(b);
};
Color.decToHex=function(n){
var h=Color.HEX_VALUES.substr(n&15,1);
while(n>15){
n>>=4;
h=Color.HEX_VALUES.substr(n&15,1)+h;
}
if(h.length==1){
h="0"+h;
}
return h;
};
Color.hexToRgb=function(h){
h=(Color.parseHex)?Color.parseHex(h):"FFFFFF";
var _730=new RGBColor(Color.hexToDec(h.substring(0,2)),Color.hexToDec(h.substring(2,4)),Color.hexToDec(h.substring(4,6)));
return _730;
};
Color.hexToDec=function(h){
return parseInt(h,16);
};
Color.parseHex=function(h){
h=h.toUpperCase();
var _733=null;
var _734=null;
if((h.indexOf("#")!=-1&&h.length==7)||(h.indexOf("#")==-1&&h.length==6)){
_733=/\#{0,1}((([ABCDEF]|\d){2}){3})/;
_734=h.match(_733);
h=(_734!==null)?_734[1]:null;
}else{
if((h.indexOf("#")!=-1&&h.length==4)||(h.indexOf("#")==-1&&h.length==3)){
_733=/\#{0,1}(([ABCDEF]|\d{1})([ABCDEF]|\d{1})([ABCDEF]|\d{1}))/;
_734=h.match(_733);
h=(_734!==null)?_734[2]+_734[2]+_734[3]+_734[3]+_734[4]+_734[4]:null;
}else{
_733=/\#{0,1}(([ABCDEF]|\d){1,6})/;
_734=h.match(_733);
h=(_734!==null)?_734[1]:"000000";
while(h.length<6){
h+="0";
}
}
}
return h;
};
Color.percentToDec=function(p){
if(String(p).indexOf(Color.PERCENT_SYMBOL)){
try{
p=parseFloat(p);
}
catch(e){
p=0;
}
}
p=Math.min(100,Math.abs(p))/100;
return Math.round(p*255);
};
Color.decToPercent=function(dec){
return dec/255*100;
};
Color.hexMask=function(evt,obj){
var key=(evt.which)?evt.which:event.keyCode;
var _73a=String.fromCharCode(key).toUpperCase();
var _73b=Color.HEX_VALUES+"#";
if((key===null)||(key===0)||(key==8)||(key==9)||(key==13)||(key==27)){
return true;
}else{
if((Color.HEX_VALUES.indexOf(_73a)>-1||((Color.HEX_SYMBOL.indexOf(_73a)>-1)&&obj.value.length<=0))){
return _73a;
}else{
return false;
}
}
};
Color.decMask=function(evt){
var key=(evt.which)?evt.which:event.keyCode;
var _73e=String.fromCharCode(key).toUpperCase();
if((key===null)||(key===0)||(key==8)||(key==9)||(key==13)||(key==27)){
return true;
}else{
if((Color.DEC_VALUES.indexOf(_73e)>-1)){
return _73e;
}else{
return false;
}
}
};
Color.prototype.setRGBColor=function(r,g,b){
this.setRedChannel(r);
this.setGreenChannel(g);
this.setBlueChannel(b);
};
Color.prototype.setRedChannel=function(ch){
this.red=this.setChannel(ch);
this.rgbUpdated();
};
Color.prototype.setGreenChannel=function(ch){
this.green=this.setChannel(ch);
this.rgbUpdated();
};
Color.prototype.setBlueChannel=function(ch){
this.blue=this.setChannel(ch);
this.rgbUpdated();
};
Color.prototype.setChannel=function(ch){
if(String(ch).indexOf(Color.PERCENT_SYMBOL)!=-1){
ch=Color.percentToDec(ch);
}
try{
ch=parseInt(ch,10);
if(isNaN(ch)){
ch=0;
}
}
catch(e){
ch=0;
}
finally{
ch=Math.min(255,Math.abs(ch));
}
return ch;
};
Color.prototype.setHex=function(h){
this.hex=Color.parseHex(h);
if(this.hex!==null){
this.hexUpdated();
}else{
alert(Color.MSG_NOT_VALID_HEX_ERROR);
this.hex="000000";
}
};
Color.prototype.rgbUpdated=function(){
this.hex=Color.rgbToHexColor(this.red,this.green,this.blue);
};
Color.prototype.hexUpdated=function(){
var _747=Color.hexToRgb(this.hex);
this.red=_747.red;
this.green=_747.green;
this.blue=_747.blue;
};
Color.prototype.toString=function(){
return this.red+","+this.green+","+this.blue;
};
Color.prototype.toRGBString=function(){
return this.toString();
};
Color.prototype.toHexString=function(){
return "#"+this.hex;
};
(function($){
var _749=function(_74a,fObj){
if(typeof fObj=="string"){
this.inputId=fObj;
this.inputObj=getElem(fObj);
}else{
this.inputId=fObj.id;
this.inputObj=fObj;
}
if(this.inputObj===null){
return;
}
this.pickerObjId=_74a;
this.imagePrefix=DR.IMAGE_PATH+"/colorPicker/";
this.rampLeftOffset=12;
this.sliderIconSize=11;
this.rampScale=100;
this.defaultHexColor="000000";
this._open=false;
this.sampleColorObj=null;
this.sampleColorId=this.inputId+"_sample";
this.pickerIconObj=null;
this.pickerIconId=this.inputId+"_icon";
this.currentColor=new Color();
if(this.inputObj.value.trim()!=""){
this.currentColor.setHex(this.inputObj.value);
}
this.currentChannel=null;
this.isDragging=false;
this.popupBound=false;
this.buildUI();
};
var _74c="Red",RED_SLIDER_ALT="Drag to adjust the red channel",GREEN_RAMP_ALT="Green",GREEN_SLIDER_ALT="Drag to adjust the green channel",BLUE_RAMP_ALT="BLUE",BLUE_SLIDER_ALT="Drag to adjust the blue channel",POPUP_UI=null,INSTANCE=null;
_749.prototype={init:function(){
if(!this.popUpBound){
this.buildPopup();
this.bindToInstance();
}
},buildUI:function(){
this.init();
if(DR.Utils.hasCSSClass(this.inputObj,"Enabled")){
this.sampleColorObj=getElem(this.sampleColorId);
this.pickerIconObj=getElem(this.pickerIconId);
}else{
var _74d=this.inputObj.parentNode;
var _74e=false;
while(!_74e){
if((_74d.tagName=="BODY")||(_74d.tagName=="HTML")){
break;
}
if(_74d.tagName=="DIV"||_74d.tagName=="DD"||_74d.tagName=="TD"){
_74e=true;
}else{
_74d=_74d.parentNode;
}
}
var _74f=document.createElement("div");
_74f.className="colorPickerSample";
_74f.innerHTML="<div id=\""+this.sampleColorId+"\" style=\"background-color:"+this.currentColor.toHexString()+"\"></div>";
_74f=DR.Utils.insertAfter(_74d,_74f,this.inputObj);
this.sampleColorObj=getElem(this.sampleColorId);
var d=document.createElement("div");
d.className="colorPickerHandle";
d.innerHTML="&nbsp;";
d.id=this.pickerIconId;
this.pickerIconObj=DR.Utils.insertAfter(_74d,d,_74f);
var _751=this;
var func=function(evt){
_751.toggle(evt);
};
DR.Utils.addEvent(this.pickerIconObj,"click",func);
DR.Utils.addEvent(this.sampleColorObj,"click",func);
DR.Utils.addEvent(this.inputObj,"click",func);
var _754=_74d.getElementsByTagName("span");
var _755=false;
if(_754.length>0){
if(DR.Utils.hasCSSClass(_754[0],"hint")){
_755=true;
}
}
if(!_755){
var s=document.createElement("span");
s.innerHTML="#"+this.defaultHexColor;
s.className="hint";
DR.Utils.insertAfter(_74d,s,this.pickerIconObj);
}
DR.Utils.addCSSClass(this.inputObj,"colorPickerEnabled");
}
},buildPopup:function(){
if(POPUP_UI===null){
var _757=document.getElementsByTagName("body")[0];
var div=document.createElement("DIV");
var ramp="";
ramp+="<div class=\"{0}Ramp\">";
ramp+="\t<div id=\"colorPickerRamp_{0}\" class=\"ramp\"><img src=\""+this.imagePrefix+"{0}_ramp.gif\" width=\"122\" height=\"19\" border=\"0\" onmouseup=\"$.dr.colorPicker.getInstance().stopDrag();\" onmousedown=\"$.dr.colorPicker.getInstance().startDrag('{0}', event);\"  ondragstart=\"return false;\" title=\"{RAMP_ALT}\" /></div>";
ramp+="\t<div class=\"rampInput\"><input name=\"{0}\"  id=\"colorPickerInput_{0}\" maxlength=\"5\"  value=\"0\" onkeypress=\"return Color.decMask(event);\"  onchange=\"$.dr.colorPicker.getInstance().changeInput(this);\" /></div>";
ramp+="\t<div id=\"colorPickerSlider_{0}\" class=\"rampSlider\"><img name=\"{0}_slider_img\" src=\""+this.imagePrefix+"slider_head.gif\"  width=\"11\" height=\"6\" border=\"0\" onmouseup=\"$.dr.colorPicker.getInstance().stopDrag();\" onmousedown=\"$.dr.colorPicker.getInstance().startDrag('{0}', event);\" ondragstart=\"return false;\" title=\"{SLIDER_ALT}\" /></div>";
ramp+="</div>";
var h="";
h+="<div id=\"colorPickerPopup\" class=\"colorPickerPopup\" >";
h+="\t<div class=\"swatch\"><div class=\"frame\"><div id=\"colorPickerSample\"></div></div></div>";
h+="\t<div id=\"colorPickerRamps\" class=\"ramps\">";
h+=ramp.replace(/\{0\}/g,"red").replace(/{RAMP_ALT}/,_74c).replace(/{SLIDER_ALT}/,RED_SLIDER_ALT);
h+=ramp.replace(/\{0\}/g,"green").replace(/{RAMP_ALT}/,GREEN_RAMP_ALT).replace(/{SLIDER_ALT}/,GREEN_SLIDER_ALT);
h+=ramp.replace(/\{0\}/g,"blue").replace(/{RAMP_ALT}/,BLUE_RAMP_ALT).replace(/{SLIDER_ALT}/,BLUE_SLIDER_ALT);
h+="\t\t<div class=\"hexInput\">";
h+="\t\t\t#<input id=\"colorPickerHex\" name=\"hex\" value=\""+this.defaultHexColor+"\" maxlength=\"7\" onkeypress=\"$.dr.colorPicker.getInstance().doEnter(event); return Color.hexMask(event, this);\" onchange=\"$.dr.colorPicker.getInstance().changeHex();\" />";
h+="\t\t</div>";
h+="\t</div>";
h+="</div>";
div.innerHTML=h;
POPUP_UI=_757.appendChild(div);
}
},bindToInstance:function(){
this.popupId="colorPickerPopup";
this.popupObj=getElem(this.popupId);
this.colorPickerRampsObj=getElem("colorPickerRamps");
this.colorPickerHexInputObj=getElem("colorPickerHex");
this.colorPickersampleColorObj=getElem("colorPickerSample");
var c="colorPickerSlider_";
var r="colorPickerRamp_";
var i="colorPickerInput_";
this.channels={};
this.channels.red={};
this.channels.red.slider=getElem(c+"red");
this.channels.red.ramp=getElem(r+"red");
this.channels.red.input=getElem(i+"red");
this.channels.green={};
this.channels.green.slider=getElem(c+"green");
this.channels.green.ramp=getElem(r+"green");
this.channels.green.input=getElem(i+"green");
this.channels.blue={};
this.channels.blue.slider=getElem(c+"blue");
this.channels.blue.ramp=getElem(r+"blue");
this.channels.blue.input=getElem(i+"blue");
this.popUpBound=true;
var _75e=function(evt){
if(window.event){
window.event.cancelBubble=true;
}else{
evt.stopPropagation();
evt.preventDefault();
}
};
this.stopClick=_75e;
DR.Utils.addEvent(this.popupObj,"click",_75e,false);
},show:function(evt){
if(this.inputObj.value.trim()!=""){
this.update();
}else{
INSTANCE=this;
}
if(this.inputObj.disabled){
return;
}
this.popupObj.style.display="block";
var _761=5;
var _762=0;
var _763="Right";
var _764="Top";
var _765="Right";
var _766="Down";
DR.Utils.Position.snapTo(this.inputObj,this.popupObj,_761,_762,_763,_764,_765,_766);
var _767=this;
var func=function(){
_767.addDocumentOnclick();
};
window.setTimeout(func,50);
this._open=true;
},addDocumentOnclick:function(){
var _769=this;
var func=function(){
_769.hide();
};
this.hideFunc=func;
DR.Utils.addEvent(document,"click",func,false);
},hide:function(){
this.popupObj.style.display="none";
if(this.hideFunc){
DR.Utils.removeEvent(document,"click",this.hideFunc);
}
this._open=false;
},toggle:function(evt){
var xLoc=parseInt(DR.Utils.getStyle(this.popupObj,"left"),10);
if(xLoc<-100){
this.popupObj.style.display="none";
}
if(this.popupObj.style.display=="block"&&this._open){
this.hide();
}else{
this.show(evt);
}
},startDrag:function(_76d,evt){
this.currentChannel=_76d;
var _76f=this;
var _770=function(evt){
_76f.doDrag(evt);
};
var _772=function(evt){
_76f.stopDrag(evt);
};
this.mouseup=_772;
this.mousemove=_770;
DR.Utils.addEvent(document,"mousemove",_770,false);
DR.Utils.addEvent(document,"mouseup",_772,false);
this.dragSlider(evt);
this.isDragging=true;
if(document.addEventListener){
evt.stopPropagation();
evt.preventDefault();
}
},stopDrag:function(){
DR.Utils.removeEvent(document,"mousemove",this.mousemove);
DR.Utils.removeEvent(document,"mouseup",this.mouseup);
this.isDragging=false;
this.currentChannel=null;
},doDrag:function(evt){
if(this.isDragging){
if(!evt){
evt=window.event;
}
this.dragSlider(evt);
}
return false;
},dragSlider:function(evt){
evt=(evt)?evt:event;
var _776=this.popupObj.offsetLeft+this.colorPickerRampsObj.offsetLeft;
_776+=(this.rampLeftOffset-(this.sliderIconSize/2));
var x=this.constrainSlider(evt.clientX-_776+document.body.parentNode.scrollLeft);
var p=x-this.rampLeftOffset+"%";
if(this.currentChannel=="red"){
this.currentColor.setRedChannel(p);
}else{
if(this.currentChannel=="green"){
this.currentColor.setGreenChannel(p);
}
}
if(this.currentChannel=="blue"){
this.currentColor.setBlueChannel(p);
}
this.update();
},constrainSlider:function(x){
var _77a=this.rampLeftOffset;
var _77b=_77a+this.rampScale;
var newX=Math.min(Math.max(_77a,x),_77b);
return newX;
},positionSliders:function(){
this.positionSlider(this.channels.red.slider,this.currentColor.red);
this.positionSlider(this.channels.green.slider,this.currentColor.green);
this.positionSlider(this.channels.blue.slider,this.currentColor.blue);
},positionSlider:function(_77d,dec){
var _77f=Math.round(Color.decToPercent(dec));
_77f=_77f+this.rampLeftOffset;
_77d.style.left=_77f+"px";
},update:function(){
INSTANCE=this;
this.channels.red.input.value=this.currentColor.red;
this.channels.green.input.value=this.currentColor.green;
this.channels.blue.input.value=this.currentColor.blue;
if(this.currentColor.hex){
this.colorPickerHexInputObj.value=this.currentColor.hex;
this.colorPickersampleColorObj.style.backgroundColor=this.currentColor.toHexString();
}
this.positionSliders();
this.inputObj.value=this.currentColor.toHexString();
this.sampleColorObj.style.backgroundColor=this.currentColor.toHexString();
},changeInput:function(obj){
var _781=obj.value;
var _782=obj.name;
if(_782=="red"){
this.currentColor.setRedChannel(_781);
}else{
if(_782=="green"){
this.currentColor.setGreenChannel(_781);
}
}
if(_782=="blue"){
this.currentColor.setBlueChannel(_781);
}
this.currentChannel=_782;
this.update();
},changeHex:function(){
var hex=this.colorPickerHexInputObj.value;
this.currentColor.setHex(hex);
this.update();
},setBaseInput:function(){
this.inputObj.value=this.currentColor.toHexString();
},getBaseInput:function(){
var hex=null;
if(this.inputObj!==null){
hex=this.inputObj.value;
}
},doEnter:function(evt,_786){
var key=(evt.which)?evt.which:event.keyCode;
var _788=(_786)?true:false;
if(key==13){
if(!_788){
this.changeHex();
}else{
this.update();
}
}
}};
$.namespace("dr",{colorPicker:function(){
return this.each(function(){
if(this.type=="text"){
if(!$(this).hasClass("colorPicker_inited")){
$(this).addClass("colorPicker");
var _789="jQuery('#"+this.id+"').get(0).colorPicker";
this.colorPicker=new _749(_789,this);
$(this).addClass("colorPicker_inited");
}
}
});
}});
$.dr.colorPicker={getInstance:function(){
return INSTANCE;
}};
var _78a=function(_78b){
_78b.filter("input[type=text].colorPicker").dr.colorPicker();
};
$.dr.addPlugin("form",_78a);
})(jQuery);
(function($){
var _78d=0,MONTH_NAMES=null,MONTH_ABBREVIATIONS=null,DAY_HEADERS=null,ANY_DATE_PICKERS_OPEN=false;
var _78e={CSS_CLASS_DATE:"date",CSS_CLASS_TODAYS_DATE:"todaysDate",CSS_CLASS_DISPLAY_DATE_CLASS:"displayDate",CSS_CLASS_DISPLAY_MONTH_DATE:"displayMonthDate",CSS_CLASS_OTHER_MONTH_DATE:"otherMonthDate",YEAR_SELECT_OFFSET:4,DEFAULT_TEXT:"Calendar"};
var _78f="January",FEBRUARY="February",MARCH="March",APRIL="April",MAY="May",JUNE="June",JULY="July",AUGUST="August",SEPTEMBER="September",OCTOBER="October",NOVEMBER="November",DECEMBER="December",JANUARY_ABBRV="Jan",FEBRUARY_ABBRV="Feb",MARCH_ABBRV="Mar",APRIL_ABBRV="Apr",MAY_ABBRV="May",JUNE_ABBRV="Jun",JULY_ABBRV="Jul",AUGUST_ABBRV="Aug",SEPTEMBER_ABBRV="Sep",OCTOBER_ABBRV="Oct",NOVEMBER_ABBRV="Nov",DECEMBER_ABBRV="Dec",SUNDAY_ABBRV="S",MONDAY_ABBRV="M",TUESDAY_ABBRV="T",WEDNESDAY_ABBRV="W",THURSDAY_ABBRV="T",FRIDAY_ABBRV="F",SATURDAY_ABBRV="S",TODAY="Go to Today's Date";
var _790=function(_791,fObj,_793,_794){
this.pickerObjId=_791;
this.init(fObj,_793,_794);
};
_790.prototype={init:function(fObj,_796,_797){
if(typeof fObj=="string"){
this.inputId=fObj;
this.inputObj=getElem(fObj);
}else{
if(fObj.id){
this.inputId=fObj.id;
}else{
this.inputId=fObj.getAttribute("datePickerId");
}
this.inputObj=fObj;
}
if(this.inputObj===null){
return;
}
this.dateFormat=(_797)?_797:$.dr.date.getDefaultFormat();
this._label=(_796)?_796.replace(":",""):_78e.DEFAULT_TEXT;
this.pickerIcon=null;
this.pickerIconId=this.inputId+"_icon";
this.popupId="picker_"+this.inputId;
this.popupObj=null;
this.contentArea=null;
this.calendarArea=null;
this.menuArea=null;
this.overlay=null;
this.todaysDate=null;
this.todaysMonth=null;
this.todaysDay=null;
this.todaysYear=null;
this.displayMonth=null;
this.displayDay=null;
this.displayYear=null;
this.displayDateOffset=null;
this.inputFieldMonth=null;
this.inputFieldDay=null;
this.inputFieldYear=null;
this.currentMonthHasTodaysDate=false;
this.hasInputFieldValue=false;
this.menuBuilt=false;
this.menuMonthSelect=null;
this.menuYearSelect=null;
this.numDaysInMonth=[0,31,28,31,30,31,30,31,31,30,31,30,31];
if(MONTH_NAMES===null){
MONTH_NAMES=[_78f,FEBRUARY,MARCH,APRIL,MAY,JUNE,JULY,AUGUST,SEPTEMBER,OCTOBER,NOVEMBER,DECEMBER];
MONTH_ABBREVIATIONS=[JANUARY_ABBRV,FEBRUARY_ABBRV,MARCH_ABBRV,APRIL_ABBRV,MAY_ABBRV,JUNE_ABBRV,JULY_ABBRV,AUGUST_ABBRV,SEPTEMBER_ABBRV,OCTOBER_ABBRV,NOVEMBER_ABBRV,DECEMBER_ABBRV];
DAY_HEADERS=[SUNDAY_ABBRV,MONDAY_ABBRV,TUESDAY_ABBRV,WEDNESDAY_ABBRV,THURSDAY_ABBRV,FRIDAY_ABBRV,SATURDAY_ABBRV];
}
this.setTodaysDate();
this.attachIcon();
},attachIcon:function(){
if(!$(this.inputObj).hasClass("Enabled")){
var _798=this.inputObj.parentNode;
var _799=false;
while(!_799){
if((_798.tagName=="BODY")||(_798.tagName=="HTML")){
break;
}
if(_798.tagName=="DIV"||_798.tagName=="DD"||_798.tagName=="TD"){
_799=true;
}else{
_798=_798.parentNode;
}
}
var divs=_798.getElementsByTagName("div");
var _79b=false;
var _79c=null;
if(divs.length>0){
if($(divs[0]).hasClass("Handle")){
this.pickerIcon=divs[0];
}
}
if(this.pickerIcon===null){
var d=document.createElement("div");
d.innerHTML="&nbsp;";
d.className="datePickerHandle";
d.id=this.pickerIconId;
var _79e=this;
var func=function(evt){
_79e.toggle(evt);
};
$(d).click(func);
$(this.inputObj).click(func);
this.pickerIcon=DR.Utils.insertAfter(_798,d,this.inputObj);
}
var _7a1=_798.getElementsByTagName("span");
var _7a2=false;
if(_7a1.length>0){
if($(_7a1[0]).hasClass("hint")){
_7a2=true;
}
}
if(!_7a2){
var s=document.createElement("span");
s.className="hint";
var _7a4=new $.dr.date(new Date(),this.dateFormat);
s.innerHTML=this.dateFormat+" ("+_7a4.toFormattedString()+")";
s.title=s.innerHTML;
DR.Utils.insertAfter(_798,s,this.pickerIcon);
}
$(this.inputObj).addClass("datePickerEnabled").attr("autocomplete","off");
}
},toggle:function(evt,_7a6){
if(this.contentArea===null){
var _7a7=document.getElementById(this.popupId);
if(_7a7===null){
var _7a8=document.getElementsByTagName("body")[0];
var d=document.createElement("DIV");
d.id=this.popupId;
d.className="datePickerContent";
this.contentArea=_7a8.appendChild(d);
var d=document.createElement("DIV");
d.id="menuArea_"+this.popupId;
this.menuArea=this.contentArea.appendChild(d);
var d=document.createElement("DIV");
d.id="calendarArea_"+this.popupId;
d.className="calendarArea";
this.calendarArea=this.contentArea.appendChild(d);
}else{
this.contentArea=_7a7;
this.menuArea=document.getElementById("menuArea_"+this.popupId);
this.calendarArea=document.getElementById("calendarArea_"+this.popupId);
}
}
if(this.popupObj===null){
this.show(evt);
}else{
if(this.popupObj.display=="block"){
this.hide();
}else{
this.show(evt);
}
}
},show:function(evt){
ANY_DATE_PICKERS_OPEN=true;
if(this.inputObj.disabled){
return;
}
var _7ab=this;
var func=function(evt){
_7ab.shouldHide(evt);
};
this.shouldHideFunc=func;
$(document).click(func);
this.setInputFieldDate();
this.refreshCalendar();
this.showPopup();
var _7ae=this.overlay.shadowRight;
var _7af=this.overlay.shadowBottom;
var _7b0=-(_7ae/2);
var _7b1=0;
if(DR.Utils.BrowserDetect.browser=="Explorer"&&DR.Utils.BrowserDetect.version<7){
_7b0=0;
_7b1=2;
}
var _7b2="Left";
var _7b3="Bottom";
var _7b4="Right";
var _7b5="Down";
DR.Utils.Position.snapTo(this.inputObj,this.popupObj,_7b0,_7b1,_7b2,_7b3,_7b4,_7b5);
},shouldHide:function(evt){
var o=evt.target;
var _7b8=(o.id==this.inputId+"_todayLink")?true:false;
while(o){
var _7b9=(o.getAttribute)?o.getAttribute("datePickerId"):null;
if(this.inputId==_7b9){
_7b8=true;
break;
}else{
if(o.id!==undefined){
if(o.id==("modal_"+this.popupId)||o.id==this.pickerIconId||o.id==this.inputId){
_7b8=true;
break;
}
}
}
o=o.parentNode;
}
if(!_7b8){
this.hide();
$(document).unbind("click",this.shouldHide);
}
},hide:function(){
if(this.overlay!==null){
$(document).unbind("click",this.shouldHideFunc);
this.overlay.close();
}
ANY_DATE_PICKERS_OPEN=false;
},showPopup:function(){
if(!ANY_DATE_PICKERS_OPEN){
var _7ba=this;
var func=function(){
_7ba.showPopup();
};
window.setTimeout(func,50);
}else{
if(this.popupObj===null){
var _7bc=overlayStack.getById(this.popupId);
if(_7bc===null){
var w=this.contentArea.offsetWidth-10;
var h=this.contentArea.offsetHeight-10;
$("#"+this.popupId).dr.overlay({type:"modeless",width:w,height:h,anchorId:this.popupId});
this.overlay=$("#"+this.popupId).data("overlay");
}else{
this.overlay=_7bc;
}
this.overlay.setTitle(this._label);
this.popupObj=$("#modal_"+this.popupId).addClass("datePickerOverlay")[0];
this.overlay.show();
}else{
this.overlay.show();
}
}
},updateDateInput:function(evt,year,_7c1,day){
this.inputObj.value=this.getDateString(year,_7c1,day);
if(typeof this.inputObj.onchange=="function"){
this.inputObj.onchange();
}
this.hide();
},getDateString:function(year,_7c4,day){
var date=new Date();
date.setFullYear(year,_7c4-1,day);
return new $.dr.date(date,this.dateFormat).toFormattedString();
},refreshCalendar:function(){
if(arguments.length==2){
if(arguments[0]!=this.displayYear||arguments[1]!=this.displayMonth){
this.calculateDisplayDate(arguments[0],arguments[1]);
this.calculateOffset();
this.calendarArea.innerHTML=this.writeCalendar(arguments[0],arguments[1]);
}
}else{
if(arguments.length==3){
this.calculateDisplayDate(arguments[0],arguments[1],arguments[2]);
this.calculateOffset();
this.calendarArea.innerHTML=this.writeCalendar(arguments[0],arguments[1],arguments[2]);
}else{
this.calculateDisplayDate();
this.calculateOffset();
this.calendarArea.innerHTML=this.writeCalendar();
}
}
},setTodaysDate:function(){
this.todaysDate=new $.dr.date(new Date(),this.dateFormat);
this.todaysMonth=this.todaysDate.getMonth()+1;
this.todaysDay=this.todaysDate.getDate();
this.todaysYear=this.todaysDate.getFullYear();
},setInputFieldDate:function(){
this.hasInputFieldValue=false;
if(this.inputObj!==null){
if(this.inputObj.value!==""){
var date=new $.dr.date(this.inputObj.value,this.dateFormat);
if(date.isValid()){
this.inputFieldMonth=date.getMonth()+1;
this.inputFieldDay=date.getDate();
this.inputFieldYear=date.getFullYear();
this.hasInputFieldValue=true;
}
}
}
},loadPreviousMonth:function(){
var _7c8=this.displayMonth-1;
var year=this.displayYear;
if(_7c8<1){
_7c8=12;
year--;
}
this.refreshCalendar(year,_7c8);
},loadNextMonth:function(){
var _7ca=this.displayMonth+1;
var year=this.displayYear;
if(_7ca>12){
_7ca=1;
year++;
}
this.refreshCalendar(year,_7ca);
},calculateDisplayDate:function(){
if(arguments.length>0){
var day=1;
if(arguments.length==3){
day=arguments[2];
}
var date=$.dr.date.getISODate(arguments[0],arguments[1],day);
this.displayMonth=date.getMonth()+1;
this.displayDay=date.getDate();
this.displayYear=date.getFullYear();
}else{
if(this.inputObj){
if(this.inputObj.value!==""){
var date=new $.dr.date(this.inputObj.value,this.dateFormat);
if(date.isValid()){
var _7ce=date.getMonth()+1;
this.displayMonth=date.getMonth()+1;
this.displayDay=date.getDate();
this.displayYear=date.getFullYear();
}
}else{
this.displayMonth=this.todaysMonth;
this.displayDay=this.todaysDay;
this.displayYear=this.todaysYear;
}
}else{
this.displayMonth=this.todaysMonth;
this.displayDay=this.todaysDay;
this.displayYear=this.todaysYear;
}
}
if($.dr.date.isLeapYear(this.displayYear)){
this.numDaysInMonth[2]=29;
}
},calculateOffset:function(){
var date=$.dr.date.getISODate(this.displayYear,this.displayMonth,1);
var _7d0=date.getDay();
this.displayDateOffset=(_7d0>=_78d)?_7d0-_78d:7-_78d+_7d0;
},refreshMenu:function(){
if(this.menuYearSelect!==null){
if(this.menuYearSelect.options.length==0){
this.menuBuilt=false;
}else{
var _7d1=parseInt(this.menuYearSelect.options[0].value,10);
var _7d2=parseInt(this.menuYearSelect.options[this.menuYearSelect.options.length-1].value,10);
if((this.displayYear<=_7d1)||(this.displayYear>=_7d2)){
this.menuBuilt=false;
}
}
}
if(!this.menuBuilt){
var _7d3="";
var _7d4;
_7d3+="<div class=\"monthYearPicker\"><table cellpadding=\"0\" cellspacing=\"0\" border=\"0\" ><tr>\n";
_7d3+="<td class=\"previousArrow\"><a href=\"#\" onclick=\""+this.pickerObjId+".loadPreviousMonth(); return false;\"><span>&lt;&lt;</span></a></td>";
var _7d5=this.pickerObjId+".refreshCalendar("+this.pickerObjId+".displayYear, this.options[this.selectedIndex].value-0)";
var _7d6=this.pickerObjId+".refreshCalendar(this.options[this.selectedIndex].value-0, "+this.pickerObjId+".displayMonth)";
_7d3+="<td class=\"monthTD\"><select name=\"cpMonth\" id=\""+this.inputId+"_monthControl\" onkeyup=\""+_7d5+"\" onchange=\""+_7d5+"\" >";
for(var _7d7=1;_7d7<=12;_7d7++){
_7d4=(_7d7==this.displayMonth)?"SELECTED":"";
_7d3+="<option value=\""+_7d7+"\" "+_7d4+">"+MONTH_NAMES[_7d7-1]+"</option>";
}
_7d3+="</select></td>";
_7d3+="<td class=\"yearTD\"><select name=\"cpYear\" id=\""+this.inputId+"_yearControl\" onkeyup=\""+_7d6+"\" onchange=\""+_7d6+"\" >";
for(var _7d8=this.displayYear-_78e.YEAR_SELECT_OFFSET;_7d8<=this.displayYear+_78e.YEAR_SELECT_OFFSET;_7d8++){
_7d4=(_7d8==this.displayYear)?"selected":"";
_7d3+="<option value=\""+_7d8+"\" "+_7d4+">"+_7d8+"</option>";
}
_7d3+="</select></td><td class=\"nextArrow\" ><a href=\"#\" onclick=\""+this.pickerObjId+".loadNextMonth(); return false;\"><span>&gt;&gt;</span></a></td></tr>\n";
_7d3+="</table></div>\n";
this.menuArea.innerHTML=_7d3;
this.menuMonthSelect=getElem(this.inputId+"_monthControl");
this.menuYearSelect=getElem(this.inputId+"_yearControl");
this.menuBuilt=true;
}else{
DR.Utils.FormUtils.setValue(this.menuMonthSelect,{},this.displayMonth);
DR.Utils.FormUtils.setValue(this.menuYearSelect,{},this.displayYear);
}
},writeCalendar:function(){
this.refreshMenu();
var _7d9="";
_7d9+="<div class=\"datesArea\"><table width=\"100%\" cellpadding=\"0\" cellspacing=\"0\" border=\"0\" class=\"calendar\"><thead><tr>";
var _7da=this.displayMonth;
var _7db=1;
var _7dc=this.displayYear;
if(this.displayDateOffset>0){
_7da--;
if(_7da<1){
_7da=12;
_7dc--;
}
_7db=(this.numDaysInMonth[_7da]-this.displayDateOffset)+1;
}
for(var j=0;j<7;j++){
_7d9+="<th class=\"dayOfWeekName\" width=\"14%\">"+DAY_HEADERS[(_78d+j)%7]+"</th>\n";
}
_7d9+="</thead><tbody>";
for(var row=1;row<=6;row++){
_7d9+="<tr>\n";
for(var col=1;col<=7;col++){
var _7e0=$.dr.date.getISODate(_7dc,_7da,_7db);
var _7e1=this.setDateClassName(_7e0);
if((row>4)&&(col==1)&&(_7e1==_78e.CSS_CLASS_OTHER_MONTH_DATE)){
_7d9+="<td colspan=\"7\">&nbsp;</td>";
break;
}else{
_7d9+="<td class=\""+_78e.CSS_CLASS_DATE+" "+_7e1+"\"><a href=\"#\" onclick=\""+this.pickerObjId+".updateDateInput(event, "+_7dc+", "+_7da+", "+_7db+"); return false;\" class=\""+_7e1+"\">"+_7db+"</a></td>\n";
}
_7db++;
if(_7db>this.numDaysInMonth[_7da]){
_7db=1;
_7da++;
}
if(_7da>12){
_7da=1;
_7dc++;
}
}
_7d9+="</tr>";
}
_7d9+="</tbody></table></div>\n";
if(!this.currentMonthHasTodaysDate){
_7d9+="<div class=\"todayLink\"><a href=\"#\" id=\""+this.inputId+"_todayLink\" onclick=\""+this.pickerObjId+".refreshCalendar("+this.todaysYear+", "+this.todaysMonth+", "+this.todaysDay+"); return false;\">"+TODAY+"</a></div>";
}
this.currentMonthHasTodaysDate=false;
return _7d9;
},setDateClassName:function(date){
var _7e3=date.getMonth()+1;
var year=date.getFullYear();
var day=date.getDate();
var _7e6="";
if(this.hasInputFieldValue&&_7e3==this.inputFieldMonth&&year==this.inputFieldYear&&day==this.inputFieldDay){
_7e6=_78e.CSS_CLASS_DISPLAY_DATE_CLASS+" ";
}
if(_7e3==this.todaysMonth&&year==this.todaysYear&&day==this.todaysDay){
this.currentMonthHasTodaysDate=true;
_7e6+=_78e.CSS_CLASS_TODAYS_DATE;
}else{
if(_7e3==this.displayMonth&&year==this.displayYear){
_7e6+=_78e.CSS_CLASS_DISPLAY_MONTH_DATE;
}else{
_7e6+=_78e.CSS_CLASS_OTHER_MONTH_DATE;
}
}
return _7e6;
}};
$.namespace("dr",{datePicker:function(){
return this.each(function(_7e7){
if(this.type=="text"){
var _7e8=$(this);
if(!_7e8.hasClass("datePicker_inited")){
_7e8.addClass("datePicker");
var _7e9=_7e8.attr("data-format");
var jRef="#"+this.id;
if(!this.id){
var id="datePicker_count_"+_7e7+"_rndNbr_"+new Date().getTime();
_7e8.addClass(id);
jRef="."+id;
_7e8.attr("datePickerId",id);
}
var _7ec="jQuery(jQuery('"+jRef+"').get(0)).data('datePicker')";
var _7ed=$.dr.utils.getLabel(this);
if(_7ed==this.name){
_7ed=null;
}
_7e8.data("datePicker",new _790(_7ec,this,_7ed,_7e9));
_7e8.addClass("datePicker_inited");
}
}
});
}});
var _7ee=function(_7ef){
_7ef.filter("input[type=text].datePicker").dr.datePicker();
};
$.dr.addPlugin("form",_7ee);
$.dr.datePicker={setDefaults:function(_7f0){
if(_7f0){
$.extend(_78e,_7f0);
}
}};
})(jQuery);
(function($){
var _7f2={VALIDATE_HIDDEN_FIELDS:false,VALIDATION_ENABLED:true,SHOW_INLINE_ERRORS:true,SHOW_INLINE_ERRORS_ONBLUR:false,INLINE_ERROR_POSITION:"above",INLINE_ERROR_CLASS:"error",INPUT_ERROR_CLASS:"inputError",GROUP_BOX_CLASS:"errorMessage",GROUP_BOX_POSITION:"above",GROUP_BOX_ENABLED:true,GROUP_BOX_POSITION_ABOVE_FORM:false,NUMBER_LOCALE:"en_US",CURRENCY:"$",TRUNCATE_ONPASTE:false};
var _7f3={EXPAND_BUTTON_TOOL_TIP:"Click here to expand the editing area",COLLAPSE_BUTTON_TOOL_TIP:"Click here to return the editing area to its normal size",GROUP_ERROR_BOX_TITLE:"The following errors occurred:",GROUP_ERROR_BOX_ITEM_TITLE:"Click to jump to field",REQUIRED:"{LABEL} is required.",X_CHARACTERS_REMAINING:"{0} characters remaining",X_OF_Y_CHARACTERS_REMAINING:"{0} of {1} characters remaining",X_OVER_THE_LIMIT:"{0} characters over maximum limit of {1}.",MAX_CHARS:"The field length limit ({LIMIT}) for this field has been reached. The data has been shortened to fit within the limit.",CHAR_LENGTH:"{LABEL} is over the {MAX_CHARS} maximum character limit.",RANGE:"{LABEL} is out of range. Valid range is {MIN} to {MAX}.",RANGE_MIN:"{LABEL} is less than the minimum value of {MIN}.",RANGE_MAX:"{LABEL} is greater than the maximum value of {MAX}.",EMAIL:"{LABEL} is not a valid email address.",URL:"{LABEL} is not a valid url. Valid format is {EXAMPLE}.",PHONE_NUMBER:"{LABEL} is not a valid phone number. Valid format is {EXAMPLE}.",ALPHA:"{LABEL} is not alphabetic.",ALPHA_NUMERIC:"{LABEL} is not alpha numeric.",DECIMAL:"{LABEL} is not a valid decimal number. Valid format is ({EXAMPLE}).",INTEGER:"{LABEL} is not a valid integer.",NUMERIC:"{LABEL} is not a valid number.",CURRENCY:"{LABEL} is not a valid currency amount. Valid format is ({EXAMPLE})."};
var _7f4=function(val,_7f6,msg,_7f8,_7f9){
_7f8=(_7f8)?_7f8:"";
_7f9=(_7f9)?_7f9:"";
return msg.replace(/\{LABEL\}/g,_7f6).replace(/\{VALUE\}/g,val).replace(/\{FORMAT\}/g,_7f8).replace(/\{EXAMPLE\}/g,_7f9);
};
var _7fa={email:[_7f3.EMAIL,"",function(val){
return /^[a-zA-Z0-9\-_.]+[a-zA-Z0-9\-_]@[a-zA-Z0-9][a-zA-Z0-9\-.]*[a-zA-Z0-9]\.[a-zA-Z][a-zA-Z\.]*[a-zA-Z]$/.test(val);
}],url:[_7f3.URL,"http://website.com",function(val,_7fd){
if(_7fd=="website"){
return /^(http:|https:)(\/){2}?[^\/]\S+\.\S+/.test(val);
}else{
return /^[a-zA-Z0-9\-.+]*:(\/){2}[\S]?/.test(val);
}
}],phonenumber:[_7f3.PHONE_NUMBER,"###-###-####",function(val,_7ff){
if(!_7ff){
return /^(\+)?(\d{1,3})?(([0-9]{1})?([- .(]|[ (]{1,2})?([0-9a-zA-Z]{3})([- .)]|[ )]{1,2})?[0-9a-zA-Z]{3}([- .]{1})[0-9a-zA-Z]{4})?(( )?([#][0-9a-zA-Z]{1,10}))?$/.test(val);
}else{
if(_7ff=="strict"){
return /^[1-9]\d{2}-\d{3}-\d{4}$/.test(val);
}else{
if(_7ff=="integer"){
return /^\d{10}$/.test(val);
}
}
}
}],alpha:[_7f3.ALPHA,"",function(val){
return /^[a-zA-Z]+$/.test(val);
}],alphanumeric:[_7f3.ALPHA_NUMERIC,"",function(val){
return /^[0-9A-Za-z-_ @#]+$/.test(val);
}],currency:[_7f3.CURRENCY,"#,###.##",function(val,_803,obj){
if(val===null||val===undefined){
return false;
}
if(!_803){
_803=_7f2.CURRENCY;
}
var num=val.replace(_803,"");
if(_803==" CAD"){
num=num.replace("C$","");
num=num.replace("$","");
}
num=$.dr.utils.normalizeNumber(num,$.dr.utils.getNumberFormat(obj));
return /^\d*[0-9](\.)?(\d){1,2}?$/.test(num);
}],decimal:[_7f3.DECIMAL,"###,###.##",function(val,_807,obj){
if(val===null||val===undefined){
return false;
}
var num=$.dr.utils.normalizeNumber(val,$.dr.utils.getNumberFormat(obj));
return /^\d*[0-9](\.\d*[0-9])?$/.test(num);
}],integer:[_7f3.INTEGER,"",function(val){
return /^[+-]?[0-9]+$/.test(val);
}],numeric:[_7f3.NUMERIC,"",function(val,_80c,obj){
if(val===null||val===undefined){
return false;
}
return !isNaN(Number($.dr.utils.normalizeNumber(val,$.dr.utils.getNumberFormat(obj))));
}]};
var _80e={dataType:function(obj,val,_811,_812){
var _813=true;
var _814=obj.getAttribute("data-type");
var _815=obj.getAttribute("data-example");
var _816=obj.getAttribute("data-format");
var msg="";
var jObj=$(obj);
if(_814!==null){
_814=_814.toLowerCase();
var _819=_7fa[_814];
if(_819===undefined){
if(window.console){
console.log("The validator for data-type=\""+_814+"\" for field with name \""+obj.name+"\" does not exist.");
}
return true;
}
if(val.isBlank()){
$(obj.form).dr.form.removeError(obj,_814);
}else{
var _81a=_819[0];
var _81b=(_815!==null)?_815:_819[1];
if(!$.dr.form.isDataValidForType(_814,val,_816,obj)){
msg=_81a;
}else{
var min=obj.getAttribute("data-min");
var max=obj.getAttribute("data-max");
var _81e=$.dr.form.isDataValidForType(_814,min,_816,obj);
var _81f=$.dr.form.isDataValidForType(_814,max,_816,obj);
if(min!==null||max!==null){
if((min!==null&&!_81e)||(max!==null&&!_81f)){
_813=false;
msg="The value is correct for {LABEL}, but the specified range options are not of the correct data type.";
}else{
var _820,upperBound,value;
if(_814=="date"&&typeof $.dr.date=="function"){
value=new $.dr.date(val,_816).getTime();
_820=(min!==null)?new $.dr.date(min,_816).getTime():null;
upperBound=(max!==null)?new $.dr.date(max,_816).getTime():null;
}else{
if(_814=="time12hr"||_814=="time24hr"){
value=$.dr.date.getDateFromTime(val);
_820=(min!==null)?$.dr.date.getDateFromTime(min):null;
upperBound=(max!==null)?$.dr.date.getDateFromTime(max):null;
}else{
var _821=$.dr.utils.getNumberFormat(obj);
value=$.dr.utils.convertCurrencyToNumber(obj,val,_816,_821);
_820=$.dr.utils.convertCurrencyToNumber(obj,min,_816,_821);
upperBound=$.dr.utils.convertCurrencyToNumber(obj,max,_816,_821);
}
}
if(!isNaN(value)){
if(min!==null&&max!==null){
if(!isNaN(_820)&&!isNaN(upperBound)){
if(!(value>=_820&&value<=upperBound)){
msg=_7f3.RANGE.replace(/\{MAX\}/g,max).replace(/\{MIN\}/g,min);
}
}
}else{
if(max!==null&&!isNaN(upperBound)){
if(value>upperBound){
msg=_7f3.RANGE_MAX.replace(/\{MAX\}/g,max);
}
}else{
if(min!==null&&!isNaN(_820)){
if(value<_820){
msg=_7f3.RANGE_MIN.replace(/\{MIN\}/g,min);
}
}
}
}
}
}
}
}
if(msg!==""&&_812){
_813=false;
var _822=_7f4(val,jObj.data("label"),msg,_816,_81b);
$(obj.form).dr.form.throwError(obj,_814,_822,_811);
}else{
$(obj.form).dr.form.removeError(obj,_814);
}
}
}
return _813;
},required:function(obj,val,_825,_826){
var _827=true;
var _828=(obj.getAttribute("data-required")=="true")?true:false;
if(_828){
switch(obj.type){
case "select-one":
case "text":
case "textarea":
_827=!val.isBlank();
break;
case "checkbox":
case "radio":
_827=$(obj.form[obj.name]);
var _829=obj.form[obj.name];
_827=false;
if(!_829.length){
_829=[obj];
}
for(var i=0;i<_829.length;i++){
if(_829[i].checked){
_827=true;
}
}
if(!_827){
obj=_829[0];
var _82b=$(obj).parents("dl:first").find("dt:first label").text();
$(obj).data("label",(_82b.length>0)?_82b.replace(":",""):"A selection");
}
break;
case "select-multiple":
if(val!==null){
_827=!(val+"").isBlank();
}else{
_827=false;
}
break;
}
if(!_827&&_826){
var _82c=_7f4(val,$(obj).data("label"),_7f3.REQUIRED);
$(obj.form).dr.form.throwError(obj,"required",_82c,_825);
}else{
$(obj.form).dr.form.removeError(obj,"required");
}
}
return _827;
},customValidator:function(obj,val,_82f,_830){
var _831=true;
var _832=obj.getAttribute("data-custom-validator");
var _833=obj.getAttribute("data-custom-validator-message");
if(_832!==null){
var _834=eval(_832);
if(!_834&&_830){
_831=false;
if(_833!==null){
var _835=_833;
$(obj.form).dr.form.throwError(obj,"custom",_835,_82f);
}
}else{
$(obj.form).dr.form.removeError(obj,"custom");
}
}
return _831;
},maxLength:function(obj,val,_838,_839){
var _83a=true;
var jObj=$(obj);
var _83c=jObj.attr("data-maxlength");
if(_83c!==undefined){
if(!isNaN(_83c)&&_839){
if(obj.type=="textarea"){
var _83d=(jObj.attr("data-force-truncate")=="true")?true:false;
_83a=$.dr.utils.validateTextAreaLength(obj,_83c,_83d);
}else{
var _83e=DR.Utils.FormUtils.getUTF8Bytes(val).byteCount;
_83a=(_83e<=_83c)?true:false;
}
}
if(!_83a){
var _83f=_7f3.CHAR_LENGTH.replace(/\{LABEL\}/g,$(obj).data("label")).replace(/\{MAX_CHARS\}/g,_83c);
$(obj.form).dr.form.throwError(obj,"maxlength",_83f,_838);
}else{
$(obj.form).dr.form.removeError(obj,"maxlength");
}
}
return _83a;
}};
$.dr.form.isDataValidForType=function(_840,val,_842,obj){
var _844=_7fa[_840.toLowerCase()];
if(_840===undefined){
return undefined;
}else{
return _844[2].call(this,val,_842,obj);
}
};
$.dr.utils.getNumberFormat=function(obj){
var _846=$(obj).attr("data-number-locale");
return (_846!==null)?_846:_7f2.NUMBER_LOCALE;
};
var _847=["IL","CN","JP","MY","KR","KP","TH","TW","PH","IN","PK","SG","HK","MX","PR","NG","BW","ZW"];
$.dr.utils.convertCurrencyToNumber=function(obj,val,_84a,_84b){
if(val===null||val===undefined){
return false;
}
if(!_84a){
_84a=_7f2.CURRENCY;
}
var num=val.replace(_84a,"");
if(_84a==" CAD"){
num=num.replace("C$","");
num=num.replace("$","");
}
num=Number($.dr.utils.normalizeNumber(num,_84b));
return num;
};
$.dr.utils.normalizeNumber=function(num,_84e){
if(num===null||num===undefined){
return null;
}
_84e=(_84e)?_84e:_7f2.NUMBER_LOCALE;
var arr=_84e.split("_");
if(arr.length!=2){
_84e="en_US";
arr=["en","US"];
}
var _850=arr[0].toLowerCase();
var _851=arr[1].toUpperCase();
var _852=(_850=="en")?true:false;
for(var i=0;i<_847.length;i++){
if(_847[i]==_851){
_852=true;
break;
}
}
var _854=num.indexOf(",");
var _855=num.indexOf(".");
if(_852){
if(_855>=_854||_855==-1||_854==-1){
num=num.replace(/,/g,"");
}
}else{
if(_854>=_855||_855==-1||_854==-1){
num=num.replace(/\./g,"").replace(/,/g,".");
var _856=_84e.split(".");
if(_856.length==2){
num=_856[0].replace(/ /g,"");
}else{
num=num.replace(/ /g,"");
}
}
}
return num;
};
$.dr.form.addValidators=function(_857){
if(typeof method=="object"){
$.extend(_80e,_857);
}
};
$.dr.form.addDataTypeValidator=function(_858){
if(typeof _858=="object"){
$.extend(_7fa,_858);
}
};
$.dr.form.validateField=function(obj,_85a){
try{
var _85b=($(obj).data("validationEnabled")===false)?false:true;
var jObj=$(obj);
var val=jObj.val();
var _85e=jObj.data("label");
if(!_85e){
_85e=$.dr.utils.getLabel(obj);
jObj.data("label",_85e);
}
var _85f=true;
var _860=true;
var _861=jObj.attr("data-conditional-validation");
if(_861|!$(obj.form).dr.form.isValidationEnabled()){
if(!eval(_861)){
_860=false;
$(obj.form).dr.form.removeErrors(obj);
}
}
if(_860){
for(var _862 in _80e){
var _863=_80e[_862].call(this,obj,val,_85a,_85b);
if(!_863){
_85f=false;
}
}
}
return _85f;
}
catch(e){
$.dr.utils.logError("Javascript exception when validating field (id="+obj.id+")",e);
}
};
var _864=function(){
$.dr.form.validateField(this,true);
};
var _865=function(_866){
if(_866.length>0){
var _867=$(this.formObj).data("formValidator");
if(_867){
var _868=_866.filter(":input:not(:button)").filter("[data-maxlength], [data-required], [data-type], [data-custom-validator]");
if(_868.length>0){
_867.fieldsWithValidation=_868;
_867.options.validationEnabled=true;
var _869=($.browser.msie)?"paste":"input";
_868.filter(":not([id])").each(function(){
$(this).attr("id","rndID_"+new Date().getTime());
}).end().filter("input[type=text], select, textarea").blur(_864).change(_864).filter("*[data-maxlength]").keyup(_864).bind(_869,_864).end().end().filter(":radio, :checkbox").click(_864).end();
if($.browser.mozilla){
_868.filter("input[type=file]").bind("change",_864);
}
}
}
}
};
$.dr.addPlugin("form",_865);
var _86a=function(_86b,_86c){
this.formObj=_86b;
this.options=_86c;
this.init();
};
_86a.prototype={init:function(){
this.options=$.extend({},_7f2);
this.validationErrors=[];
this.fieldsWithValidation=null;
this.errorGroupBoxOpen=false;
this.validationErrors=[];
},validate:function(){
try{
var _86d=this.fieldsWithValidation;
if(_86d===null){
return true;
}
if(!this.options.VALIDATE_HIDDEN_FIELDS){
_86d=_86d.filter(":visible");
}
_86d.each(function(){
$.dr.form.validateField(this,false);
});
if(this.validationErrors.length>0){
this.showValidationErrors(true);
return false;
}else{
this.hideErrorGroupBox();
return true;
}
}
catch(e){
$.dr.utils.logError("Error when validating form.",e);
}
},showErrorGroupBox:function(h){
var _86f=document.getElementById(DR.CONTENT_AREA_ID+"_groupErrorBox");
if(!_86f||this.options.GROUP_BOX_POSITION_ABOVE_FORM){
_86f=document.getElementById(this.formObj._formName+"_groupErrorBox");
}
if(!_86f){
var _870=this.formObj.parentNode;
var d=document.createElement("div");
d.className=this.options.GROUP_BOX_CLASS;
d.id=this.formObj._formName+"_groupErrorBox";
if(this.options.GROUP_BOX_POSITION=="above"){
var f=this.formObj;
_870.insertBefore(d,f);
}else{
d.style.marginTop="15px";
_870.appendChild(d,this);
}
_86f=d;
}
var s="<div style=\"margin-bottom:10px;\"><strong>"+_7f3.GROUP_ERROR_BOX_TITLE+"</strong></div><ul>";
s+=h;
s+="</ul>";
_86f.innerHTML=s;
_86f.style.display="block";
this.errorGroupBoxOpen=true;
},hideErrorGroupBox:function(){
var _874=document.getElementById(DR.CONTENT_AREA_ID+"_groupErrorBox");
if(!_874||this.options.GROUP_BOX_POSITION_ABOVE_FORM){
_874=document.getElementById(this.formObj._formName+"_groupErrorBox");
}
if(_874){
_874.style.display="none";
this.errorGroupBoxOpen=false;
}
},hideError:function(fObj,_876){
var _877=document.getElementById(fObj.id+"_"+_876+"_error");
var _878=document.getElementById(fObj.id+"_"+_876+"_group_error");
var _879;
if(_877){
_879=_877.parentNode;
_879.removeChild(_877);
_877=null;
_879=null;
}
if(_878){
_879=_878.parentNode;
_879.removeChild(_878);
_878=null;
_879=null;
}
if(this.validationErrors.length===0){
this.hideErrorGroupBox();
}else{
if(this.errorGroupBoxOpen){
this.showValidationErrors(false);
}
}
if(this.checkErrorExists(fObj)==-1){
$(fObj).removeClass(this.options.INPUT_ERROR_CLASS);
}
},displayInlineError:function(fObj,_87b,_87c,_87d){
if((_87d&&this.options.SHOW_INLINE_ERRORS_ONBLUR)||(!_87d)){
var _87e=document.getElementById(fObj.id+"_"+_87b+"_error");
if(!_87e){
var _87f=fObj.parentNode;
var a=_87f.childNodes;
var _881=false;
for(var i=0;i<a.length;i++){
if(a[i].className=="error"){
_881=true;
a[i].style.display="none";
}
}
var e=document.createElement("div");
e.className=this.options.INLINE_ERROR_CLASS;
e.innerHTML=_87c;
e.id=fObj.id+"_"+_87b+"_error";
if(this.options.INLINE_ERROR_POSITION=="above"){
var o=document.getElementById(fObj.id);
_87f.insertBefore(e,o);
}else{
_87f.appendChild(e,fObj);
}
}
}
if(!($.browser.safari&&fObj.type=="file")&&fObj.type!="radio"&&fObj.type!="checkbox"){
$(fObj).addClass(this.options.INPUT_ERROR_CLASS);
}
},showValidationErrors:function(_885){
var h="";
var a=this.validationErrors;
var _888=false;
for(var i=0;i<a.length;i++){
var _88a=false;
var _88b=a[i].errMsg;
var fObj=a[i].obj;
var type=fObj.type;
var _88e=a[i].errType;
if(this.options.SHOW_INLINE_ERRORS){
this.displayInlineError(fObj,_88e,_88b,false);
}
if(DR.Utils.FormUtils.checkAllowFocus(fObj)){
if(!_888&&_885){
var e=document.getElementById(fObj.id+"_"+_88e+"_error");
if(e){
e.scrollIntoView();
}
fObj.focus();
_888=true;
}
_88a=true;
}
var _890=_88b;
if(_88a){
_890="<a href=\"#\" title=\""+_7f3.GROUP_ERROR_BOX_ITEM_TITLE+"\" onclick=\"document.getElementById('"+fObj.id+"_"+_88e+"_error').scrollIntoView();document.getElementById('"+fObj.id+"').focus();return false;\" >"+_88b+"</a>";
}
if(this.options.GROUP_BOX_ENABLED){
h+="<li id=\""+fObj.id+"_"+_88e+"_group_error\" >"+_890+"</li>";
}
fObj=null;
}
if(this.options.GROUP_BOX_ENABLED){
this.showErrorGroupBox(h);
}
},checkErrorExists:function(fObj,_892){
var _893=-1;
var a=this.validationErrors;
for(var i=0;i<a.length;i++){
if(a[i].obj.id==fObj.id&&(a[i].errType==_892||_892===undefined)){
_893=i;
break;
}
}
return _893;
},throwError:function(fObj,_897,_898,_899){
var _89a=this.checkErrorExists(fObj,_897);
if(_89a==-1){
var e={};
e.errMsg=_898;
e.errType=_897;
e.obj=fObj;
this.validationErrors.push(e);
if(_899){
this.displayInlineError(fObj,_897,_898,_899);
}
e=null;
}
return _89a;
},removeError:function(fObj,_89d){
var _89e=this.checkErrorExists(fObj,_89d);
if(_89e!=-1){
this.validationErrors.splice(_89e,1);
this.hideError(fObj,_89d);
}
},removeErrors:function(fObj){
var a=this.validationErrors;
for(var i=0;i<a.length;i++){
if(a[i].obj.id==fObj.id){
var _8a2=a[i].errType;
this.validationErrors.splice(i,1);
this.hideError(fObj,_8a2);
}
}
}};
var _8a3=function(evt){
$(this).data("formValidator",new _86a(this));
};
$("form").live("beforeIndexFields",_8a3);
function getValidatorObj(_8a5){
if(_8a5.length>0){
return $(_8a5[0]).data("formValidator");
}
}
$.namespace("dr.form",{validate:function(){
return getValidatorObj(this).validate();
},enableValidation:function(flag){
var v=getValidatorObj(this);
v.options.validationEnabled=flag;
v.validate();
},isValidationEnabled:function(){
return getValidatorObj(this).options.validationEnabled;
},throwError:function(obj,_8a9,_8aa,_8ab){
getValidatorObj(this).throwError(obj,_8a9,_8aa,_8ab);
},removeError:function(obj,_8ad){
getValidatorObj(this).removeError(obj,_8ad);
},removeErrors:function(obj){
getValidatorObj(this).removeErrors(obj);
}});
$.namespace("dr.form.field",{enableValidation:function(flag){
flag=(!flag)?false:true;
return this.each(function(){
$(this).data("validationEnabled",flag);
$.dr.form.validateField(this,flag);
});
}});
var _8b0=function(_8b1,_8b2,_8b3){
var _8b4=(_8b1.hasClass("largeHeight"))?"large":(_8b1.hasClass("medium"))?"medium":"small";
var _8b5=_8b4;
var _8b6=_8b1.data("originalHeight");
if(!_8b6){
var _8b7=_8b1.attr("data-default-height");
if(_8b7!==undefined){
_8b6=_8b7.replace("Height","");
}else{
_8b6=_8b4;
}
_8b1.data("originalHeight",_8b6);
}
if(_8b3){
_8b5=(_8b4=="large")?_8b6:"large";
_8b1.addClass(_8b5+"Height").removeClass(_8b4+"Height");
}
var _8b8=_7f3.COLLAPSE_BUTTON_TOOL_TIP,text=BUTTON_COLLAPSE,linkClass="collapse";
if(_8b5!="large"){
_8b8=_7f3.EXPAND_BUTTON_TOOL_TIP;
text=BUTTON_EXPAND;
linkClass="expand";
}
_8b2.text(text).attr({"title":_8b8,"class":linkClass});
if(_8b1.attr("data-persist-state")=="true"&&DR.USER_DATA!==null){
var _8b9=_8b1.attr("data-persist-page-name");
if(_8b9===undefined&&pageInfo){
_8b9=pageInfo.pageName;
}
DR.USER_DATA.save(_8b9,_8b1.id+"Height",_8b5,"String");
}
};
$.dr.utils.validateTextAreaLength=function(obj,_8bb,_8bc){
if(obj){
var _8bd=(_8bc===true)?true:_7f2.TRUNCATE_ONPASTE;
var _8be=(obj.getAttribute("alertOpen")=="true")?true:false;
var c=document.getElementById(obj.id+"_counter");
if(!c){
return;
}
var v=obj.value;
var _8c1=v.length;
if(_8bd){
if(v.length>_8bb){
v=v.substr(0,_8bb);
}
}
var _8c2=DR.Utils.FormUtils.getUTF8Bytes(v).byteCount;
var _8c3;
if(_8c2===0){
_8c3=_7f3.X_CHARACTERS_REMAINING.replace("{0}",_8bb);
}else{
var _8c4=_8bb-_8c2;
if(_8bd){
_8c4=Math.max(_8c4,0);
}
if(_8c2>_8bb&&!_8bd){
_8c4=_8c4*(-1);
_8c3=_7f3.X_OVER_THE_LIMIT.replace("{0}",_8c4);
_8c3=_8c3.replace("{1}",_8bb);
}else{
_8c3=_7f3.X_OF_Y_CHARACTERS_REMAINING.replace("{0}",_8c4);
_8c3=_8c3.replace("{1}",_8bb);
}
}
c.innerHTML=_8c3;
var _8c5=true;
if(_8c2>_8bb){
_8c5=false;
}
if(_8c2>=_8bb){
if(_8bd){
_8c5=true;
var _8c6=v.makeUT8CharsFitLength(_8c2,_8bb);
if(obj.value!=_8c6){
obj.value=_8c6;
}
if((_8c1>_8bb||_8c2>_8bb)&&!_8be){
obj.setAttribute("alertOpen","true");
var _8c7=_7f3.MAX_CHARS.replace(/\{LIMIT\}/g,_8bb);
alert(_8c7);
}else{
obj.setAttribute("alertOpen","false");
}
}
$(obj).addClass(_7f2.INPUT_ERROR_CLASS);
$(c.parentNode).addClass("limit");
}else{
$(obj).removeClass(_7f2.INPUT_ERROR_CLASS);
$(c.parentNode).removeClass("limit");
obj.setAttribute("alertOpen","false");
}
return _8c5;
}
};
var _8c8=function(_8c9){
_8c9.filter("textarea:not(.wysiwyg, .basic_wysiwyg)").each(function(){
var obj=this;
var _8cb=$(this);
if(_8cb.data("textarea_inited")){
return;
}
var _8cc=false;
var _8cd=_8cb.attr("data-maxlength");
var _8ce=(_8cb.attr("data-expand-collapse")=="false")?false:true;
if($.browser.safari){
_8ce=false;
var _8cf=parseInt(document.defaultView.getComputedStyle(obj,"").getPropertyValue("width"),10);
if(_8cf>0){
obj.style.maxWidth=_8cf+"px";
}
}
if((_8cd!==undefined&&parseInt(_8cd,10)>0)||_8ce){
_8cc=true;
}
if(_8cc){
var _8d0=obj.className;
var gs=_8d0.match(/(gridSpan[\d]+(\s|$))/);
var _8d2=(gs)?gs[0]:"gridSpan11";
var _8d3=document.createElement("div");
_8d3.className=_8d2;
var _8d4=document.createElement("div");
_8d4.className="textareaInfo";
var _8d5="<table cellpadding=\"0\" cellspacing=\"0\" border=\"0\" style=\"width:100%;\" ><tr>";
if(_8cd!==undefined){
_8d5+="<td class=\"remaining\"><span id=\""+obj.id+"_counter\" >&nbsp;</span></td>";
}
if(_8ce){
if($.browser.safari){
obj.style.maxWidth=_8cb.width()+"px";
}else{
_8d5+="<td class=\"expandCollapseButton\"><a></a></td>";
}
}
_8d5+="</tr></table>";
_8d4.innerHTML=_8d5;
$("a",_8d4).click(function(){
_8b0(_8cb,$(this),true);
}).each(function(){
_8b0(_8cb,$(this),false);
});
_8d3.appendChild(_8d4);
var _8d6=obj.parentNode;
_8d6.insertBefore(_8d3,obj.nextSibling);
if(_8cd!==undefined){
var _8d7=(_8cb.attr("data-force-truncate")=="true")?true:false;
$.dr.utils.validateTextAreaLength(obj,_8cd,_8d7);
}
_8cb.data("textarea_inited","true");
}
});
};
$.dr.addPlugin("form",_8c8);
var _8d8=function(){
$.extend(_7f3,$.dr.form.getMessages());
};
var _8d9=function(){
$.extend(_7f2,$.dr.form.getDefaults());
};
$(document).bind("afterFormSetMessages",_8d8);
$(document).bind("afterFormSetDefaults",_8d9);
$.dr.addDomReadyEvent(_8d8,"early");
$.dr.addDomReadyEvent(_8d9,"early");
})(jQuery);
Utils=DR.Utils;
Utils.Prompt=DR.Utils.prompt;
Utils.confirm=DR.Utils.confirm;
submitActionForm=DR.Utils.FormUtils.submitActionForm;
BrowserDetect=DR.Utils.BrowserDetect;
customOnload=DR.Utils.customOnload;
FormUtils=DR.Utils.FormUtils;
Cookie=DR.Utils.Cookie;
PanelSet=DR.Widgets.PanelSet;
Toggle=DR.Utils.Toggle;
getElem=DR.Utils.getElem;
DatePicker=DR.Widgets.DatePicker;
ListControls=DR.Widgets.ListControls;
FauxTree=DR.Widgets.FauxTree;
ModalOverlay=DR.Widgets.ModalOverlay;
InlineModalOverlay=DR.Widgets.InlineModalOverlay;
iframeCallback=DR.Widgets.ModalOverlay.iframeCallback;

