i´m working on a page consisting of several components (film, star,
interview) for retrieving specific data from a mysql-database.
the view should look something like this:
<div id="2cols">
<div id="2cols_leftcol">
<%= render_component :controller => "film", :action =>
"get_film" :params =>
{ "id" => "1327" } -%>
<%= render_component :controller => "star", :action =>
"get_star" :params =>
{ "id" => "968" } -%>
</div>
<div id="2cols_rightcol">
<%= render_component :controller => "star", :action =>
"get_star" :params =>
{ "id" => "745" } -%>
<%= render_component :controller => "interview", :action =>
"get_interview"
:params => { "id" => "145" } -%>
</div>
</div>
now i want the user to be able to move and edit the components. e.g., moving
the second component in "2cols_leftcol" up, or edit the first
component in
"2cols_rightcol" (changing the "id" to retrieve another star
from the
database).
now my questions:
1. is this an appropriate method or is it "usually" done different
with RoR?
2. how can i build an interface for the user to move and edit the
components?
any help is appreciated.