I have created a button, which acts as a 'Dummy' delete button, so
that those users cannot immediately delete an instance of one of my
models, eg.

<%= button_to "Remove This Model", { :action => "remove" }, :confirm
=> "Are you sure?" %>

The controller action is called - "remove", which will show a flash
message - notifying the user that the application will be removed
shortly.

But I also want this controller action to manipulate - or 'update'
certain features of the model they want to remove.

i.e - change field 'pending_delete' to true if the 'remove' function
has been called.

but I can't seem to figure out how to update the model from a
controller action.

This also seems to cause issues for me when I try to send an email
from this action, as no id is passed with it, so I cannot reference
the model requested for removal.

Is there a way of calling model methods after clicking this button?

-- 
You received this message because you are subscribed to the Google Groups "Hobo 
Users" 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/hobousers?hl=en.

Reply via email to