<% if (offset + index - 1) != 1 %>
-
<%= link_to("Move First",
{:action => 'move_first', :id => object}.update(extra_params),
{:title => "Move to the first position", :post => true }) %>
-
<%= link_to("Move Up",
{:action => 'move_up', :id => object}.update(extra_params),
{:title => "Move up", :post => true }) %>
<% else %>
- Move First
- Move Up
<% end %>
<% if (offset + index - 1) != object_count %>
-
<%= link_to("Move Down",
{:action => 'move_down', :id => object}.update(extra_params),
{:title => "Move down", :post => true }) %>
-
<%= link_to("Move Last",
{:action => 'move_last', :id => object}.update(extra_params),
{:title => "Move to the last position", :post => true }) %>
<% else %>
- Move Down
- Move Last
<% end %>