Mailinglist Archive: yast-devel (152 mails)

< Previous Next >
[yast-devel] Re: [ruby-devel] Studio and AJAX calls
  • From: Josef Reidinger <jreidinger@xxxxxxx>
  • Date: Thu, 02 Jul 2009 14:55:09 +0200
  • Message-id: <4A4CAE2D.3060409@xxxxxxx>
Cornelius Schumacher wrote:
On Thursday 02 July 2009, Josef Reidinger wrote:
I heard that suse studion use for ajax calls pure jquery. I want use in
webyast rails helpers, but that uses scipt.aulo backend (and that breaks
all out jquery stuff), but also exist plugin 'jrails' which use jquery
as backend for helpers. Is there any reason why studion use pure jquery?

We are using jquery, because it's the superior javascript framework. When we
started, there was no working rails integration, that's why we have written
most of the stuff ourselves. Maybe we should reinvestigate the current state
of the Rails plugins.

Garrett is our jquery expert, maybe he has something to add. He is traveling
right now, though, so it might take a bit.

Thanks for reply,
today I try replace my AJAX helpers with jquery stuff, but I am not much
How you implement observer ajax? (observer is reaction on change of
another object on page)

in helpers it is
:frequency => 0.25,
:update => :timezones,
:url => { :action => :timezones_for_region },
:with => "'disabled=' + "+ (disabled ? "true":"false")+" +
'&value=' +value")

I look how do it jrails and it is this:
<script type="text/javascript">

$('#region').delayedObserver(0.25, function(element, value)
{$.ajax({data:value + '&authenticity_token=' + encodeURIComponent('<%=
form_authenticity_token %>'),
success:function(request){$('#timezones').html(request);}, type:'post',

but delayedObserved is another helper, which is defined in jrails.js and
look this:
delayedObserver:function(delay,callback){var el=$(this);if(typeof

That is enought cryptic for me to avoid use it in my code :)
So if you in studion use some nice observer ajax stuff I welcome it at
least to test before we decide if we should use jrails or not.
Josef Reidinger
YaST team
maintainer of perl-Bootloader, YaST2-Repair, webyast modules language
and time
To unsubscribe, e-mail: yast-devel+unsubscribe@xxxxxxxxxxxx
For additional commands, e-mail: yast-devel+help@xxxxxxxxxxxx

< Previous Next >
This Thread