Ruby on Rails - 用户调度任务 [英] Ruby on Rails - Users Scheduling Tasks

查看:40
本文介绍了Ruby on Rails - 用户调度任务的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在开发一个应用程序,人们可以注册并安排要完成的任务.

I am working on an application which people can sign up to and schedule tasks to be done.

当用户安排任务时,他们会输入日期和时间.我希望应用程序唤醒并在用户输入的日期和时间向用户发送电子邮件.

When the user schedules a task they enter a date and time. I want the application to wake up and send an email to the user at the date and time they have entered.

我不确定在 rails 中使用什么 gems/plugins 来实现这一点,有人有建议吗?

I am unsure what gems/plugins to use in rails to achieve this, anyone have a suggestion?

干杯

伊夫

推荐答案

delayed_job 应该可以解决问题.它允许您安排任务在特定时间运行.您需要做的就是安排发送电子邮件的功能.

delayed_job should do the trick. It allows you to schedule tasks to run at a particular time. All you need to do is schedule a function that sends an email.

这篇关于Ruby on Rails - 用户调度任务的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆