Topic: Automatic execute action at certain time

I want to automatic execution action in other controller at certain time. I read more similar posts on stackoverflow(and googling), and all of them tell about whenever or delayed job. But i don't understand how it works=( This is an example of what i want.

def create
@user = User.find(params[:user_id])
@client = @user.clients.create(params[:client])
if @client.save
redirect_to user_clients_path(@user)
      else
render :action => 'new'
      end
Timeout(@client.event_time)
    redirect_to :controller => :some_controller, action => some_action
end

Last edited by kotara (2012-08-07 05:50:33)

Re: Automatic execute action at certain time

anybody any ideas?

Re: Automatic execute action at certain time

I don't get what you want to achieve...

Re: Automatic execute action at certain time

smile  smile wink