Chris Habgood wrote:

> I just do this in my application.html page:
>
> <% unless @mop.state.eql?("Being_Edited") %>
>       <%= link_to "New Mop", :action => "new" %></h3></td>
>       <%= link_to "Review Mop", :action => "review" %></h3></td>
> <% end %>
>
> Same thing really for the Show page,  I just put an unless condition to
> remove the "edit" link if the mop is being edited or looked at.

As a View style thing, a button should not just disappear if it wouldn't 
have worked. Let the user click on the button, then provide a timely error 
message.

How about you disable the link (make it grey, not <a>), and then put a 
message next to it "Asok started editing this at 3:11"? Can someone think of 
a way to do that, with a command override if Asok went home and left his 
browser running? 




--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "Ruby 
on Rails: Talk" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to 
[email protected]
For more options, visit this group at 
http://groups.google.com/group/rubyonrails-talk?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to