Forum: Ruby on Rails Drag and drop tutorials/examples?

Announcement (2017-05-07): www.ruby-forum.com is now read-only since I unfortunately do not have the time to support and maintain the forum any more. Please see rubyonrails.org/community and ruby-lang.org/en/community for other Rails- und Ruby-related community platforms.
87e4363c61cea7fd62feee2dfcddc93a?d=identicon&s=25 Nick Coyne (nick)
on 2006-05-15 14:34
Just finished our first proper rails app and I'm trying to add some AJAX
effects for the first time. I've got Rails Recipes and the Rails
Cookbook, none of their examples seem to be a good fit with what I'm
trying to achieve. Which is...

I have 2 lists of users. One for assigned users, one for unassigned
users. I want to be able to drag users between the lists to either
assign or unassign them.

Pointers? Can anyone suggest some good tutorials or example code?

Thx
Nick
455ac2a64d06dc8461f4d258d7f7e980?d=identicon&s=25 Michael Trier (Guest)
on 2006-05-15 16:11
(Received via mailing list)
Check out the scriptaculous sortables demo:

http://wiki.script.aculo.us/scriptaculous/show/Sor...

Michael
87e4363c61cea7fd62feee2dfcddc93a?d=identicon&s=25 Nick Coyne (nick)
on 2006-05-15 17:04
Michael Trier wrote:
> Check out the scriptaculous sortables demo:
>
> http://wiki.script.aculo.us/scriptaculous/show/Sor...
>
> Michael

That's pretty much what I'm after. Unfortunately rails' sortable_element
doesn't seem to support dragging to another container. What's the
workaround?

thx
Nick
68cc0d50a7daceeebc83dabd8293bbf9?d=identicon&s=25 Erlend Simonsen (Guest)
on 2006-05-16 11:51
(Received via mailing list)
On Mon, 2006-05-15 at 17:04 +0200, Nick Coyne wrote:
> Michael Trier wrote:
> > Check out the scriptaculous sortables demo:
> >
> > http://wiki.script.aculo.us/scriptaculous/show/Sor...
> >
> > Michael
>
> That's pretty much what I'm after. Unfortunately rails' sortable_element
> doesn't seem to support dragging to another container. What's the
> workaround?

The workaround is reading the documentation, especially the containment
section at
http://wiki.script.aculo.us/scriptaculous/show/Sor...

( :containment => ['sortable_id_1', 'sortable_id_2'] )
--
Erlend Simonsen <mr@fudgie.org>
This topic is locked and can not be replied to.