/** * Ruby On Rails common Ajax operations conventional wrapper * and underscored aliases for core methods * * http://github.com/MadRabbit/right-rails * * Copyright (C) 2009-2010 Nikolay V. Nemshilov */ eval((function(s,d){for(var i=d.length-1;i>-1;i--)if(d[i])s=s.replace(new RegExp(i,'g'),d[i]);return s})("8 RR={6:{17at:'js',36:'flashes',37:'slide',14:3200,1688:59,30:'fade',26:'.45_edit',23:'.45_delete',109089:59},update_flash:4(c){8 e=$(5.6.36);if(e)5.11(e,c).24();7 5},24:4(){if(5.6.14>-1){8 e=$(5.6.36);if(e&&e.visible())e.79.82(e,5.6.37).delay(5.6.14)}7 5},16:4(i){if(5.6.1688)$(i).16();7 5},19:4(a,w){7 5.16($(a).19(w).lastChild).10(a)},11:4(i,s){$(i).11(s);7 5.16(i).10(i)},41:4(i){8 e=$(i);if(e){8 r=e.41.82(e).chain(Lightbox.10);if(5.6.30)e.79(5.6.30,{onFinish:r});47 r}},15:4(i){8 f=$(i);if(f)f.remotize().enable().65+='.'+5.6.17at;7 5},11_17:4(i,s){8 f=$(i);if(f){f.11(s);5.15(i)}7 5.10(i)},show_17_86:4(i,s){$(i).select('17').46('41');$(i).19(s);7 5.15($(i).50('17')).10(i)},28:4(e){8 t=e.tar29,l=[t].68(t.53()).50('34','a');if(l){if(l.34(5.6.26)){e.33();85.81(l.58+'.'+5.6.17at)}47 if(l.34(5.6.23)&&l.87('52')){e.33();eval('({f:'+l.52.to66().11('.39','.78')+'})').f.call(l)}}},10:4(s){$w('Draggable Droppable Tabs Slider Selectable').46(4(n){if(84[n])84[n].10(5.6.109089?s:80)},5);7 5}};(4(){8 u=4(a,e){8 m=e.29('31-57');if(m&&!57(m)){a.33();7 59}};8 c=4(e,o){7 63.merge({onCreate:4(){e.43('45:81ing',5)},onComplete:4(){e.43('45:complete',5)},onSuccess:4(){e.43('45:success',5)},onFailure:4(){e.43('45:failure',5)}},o)};8 g=4(e,l){8 m=l.29('31-38'),r=l.29('31-69');if(u(e,l))7;if(m||r)e.33();if(r)85.81(l.58,c(l,{38:m||'29',55:l.29('31-55')}));47 if(m){8 p=$$('83[44=77-param]')[0],t=$$('83[44=77-token]')[0],f=$E('17',{65:l.58,38:'post'});if(p&&t)f.19('<73 60=\"62\" 44=\"'+p.29('56')+'\" 71=\"'+t.29('56')+'\" />');f.19('<73 60=\"62\" 44=\"_38\" 71=\"'+m+'\"/>').19To(18.body).39()}};8 d=4(e,b){if(!u(e,b)&&$(b.17).87('31-69')){e.33();b.17.78(c(b.17))}};18.on({72:4(e){8 t=e.tar29,f=t.17,l=[t].68(t.53()).50('34','a');if(f&&['39','image'].54(t.60))d(e,t);47 if(l)g(e,l)},keydown:4(e){8 t=e.tar29,f=t.17;if(f&&t.tagName==='INPUT'&&e.keyCode==13)d(e,t)}})})();18.on({ready:4(){RR.24()},72:4(e){RR.28(e)}});[66.9,70.9,Function.9,63,6,49,49.9,window,18].46(4(o){86(8 k in o)try{if(/[A-Z]/.76(k)&&60of(o[k])==='4'){8 u=k.35();if(o[u]===80||o[u]===undefined)o[u]=o[k]}}catch(e){}});[51,Event,75,75.51].46(4(o){8 a={},m=o.Methods;86(8 k in m)if(/[A-Z]/.76(k)&&60of(m[k])==='4')a[k.35()]=m[k];o.54(a)});61(66.9,{48:'25',27:'12',to_f:'toFloat',to_i:'toInt',gsub:'11',downcase:'toLower91',upcase:'toUpper91',74:'25',67:'12',strip:'trim'});61(70.9,{collect:'map',detect:'filter',48:'25',27:'12',74:'25',67:'12'});",",,,,function,this,Options,return,var,prototype,rescan,replace,lastIndexOf,,flashHideDelay,remotize_form,highlight,form,document,insert,,highlightUpdates,rescanWithScopes,linkToAjaxDelete,hide_flash,indexOf,linkToAjaxEdit,last_index_of,process_click,get,removeFx,data,,stop,match,underscored,flashId,flashHideFx,method,submit,format,remove,target,fire,name,ajax,each,else,index_of,Observer,first,Element,onclick,parents,include,spinner,content,confirm,href,true,type,$alias,hidden,Object,typeof,action,String,rindex,concat,remote,Array,value,click,input,index,Form,test,csrf,send,hide,null,load,bind,meta,self,Xhr,for,has,Updates,Scopes,With,Case".split(",")));