プロジェクト

全般

プロフィール

Vote #74082

未完了

Email Reminder doesn't have the right behavior

Admin Redmine さんが約4年前に追加. 約4年前に更新.

ステータス:
New
優先度:
通常
担当者:
-
カテゴリ:
Email notifications_9
対象バージョン:
-
開始日:
2022/05/09
期日:
進捗率:

0%

予定工数:
category_id:
9
version_id:
0
issue_org_id:
14400
author_id:
81414
assigned_to_id:
0
comments:
8
status_id:
1
tracker_id:
1
plus1:
0
affected_version:
closed_on:
affected_version_id:
ステータス-->[New]

説明

Hello there,

Let's start by a small complaint.
Here https://github.com/chantra/redmine_whining/issues/25, it is said that

redmine now include the rake task send_reminders.
So this plugin is now redundant.

WELL, not exactly. Redmine Whining had the bright idea to send a reminder to assignees who didn't process a ticket for X days.
The send_reminders now included in Redmine sends a reminder to assignees whose issue's due date is in X days.
Quite a difference here, notably when the due date is empty or rarely used.

While patching send_reminders (./app/models/mailer.rb) to meet my needs, I've encountered the following:

scope = Issue.open.where("#{Issue.table_name}.assigned_to_id IS NOT NULL" +
      " AND #{Project.table_name}.status = #{Project::STATUS_ACTIVE}" +
      " AND #{Issue.table_name}.due_date >= ?", days.day.from_now.to_date
    )

for which the last line would generate something like

 AND issues.due_date >= 'Fri, 12 Jul 2013'

issues.due_date being of type DATE, that is just not going to work properly.

For those interested, I replaced the line by

" AND DATEDIFF(NOW(),#{Issue.table_name}.updated_on) >= ?", days

journals

This is not a defect in redmine.

Benjamin Billon wrote:
> Let's start by a small complaint.
> Here https://github.com/chantra/redmine_whining/issues/25, it is said that
>> redmine now include the rake task send_reminders.
>>So this plugin is now redundant.
>
> WELL, not exactly. Redmine Whining had the bright idea to send a reminder to assignees who didn't process a ticket for X days.
> The send_reminders now included in Redmine sends a reminder to assignees whose issue's due date is in X days.
> Quite a difference here, notably when the due date is empty or rarely used.
Please tell the plugin developer that you disagree with his view and that he update his plugin.
--------------------------------------------------------------------------------
Sorry to insist, but as far as I understand, the Email Reminder _is_ part of redmine: http://www.redmine.org/projects/redmine/wiki/RedmineReminderEmails
And the "days.day.from_now.to_date" part returning an invalid value for a MySQL Date type comparison, it would make the feature behavioring unexpectingly.

If not, I apologize for the noise.
--------------------------------------------------------------------------------
You're right, but I'm not sure this is a Redmine issue, it's very likely that the AR DB adapter is responsible for the translation of the Date object into a format that the DB can understand.

Could you please give more details about your setup, as described in [[SubmittingBugs]]?
--------------------------------------------------------------------------------

--------------------------------------------------------------------------------
Am I getting this wrong? OP points out that the rake task doesn't to the same as the plugin, and that is true, isn't it?

--------------------------------------------------------------------------------
Redmine version 2.3.0.stable
Ruby version 1.9.3 (x86_64-linux)
Rails version 3.2.13
Mysql Server version: 5.5.30-30.2 Percona Server (GPL), Release 30.2

@Jan> sorry, my initial post contained two main points: one about the plugin (which doesn't concern redmine itself indeed), and another one about what looked like a bug in the code (that I felt I had to report).
--------------------------------------------------------------------------------

--------------------------------------------------------------------------------
I also had this itch... here's a patch to enable more fine grained control of reminder emails

--------------------------------------------------------------------------------

他の形式にエクスポート: Atom PDF

いいね!0
いいね!0