プロジェクト

全般

プロフィール

Vote #68953

未完了

Activity page displays wrong status of modified issues

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

ステータス:
New
優先度:
高め
担当者:
-
カテゴリ:
Issues_2
開始日:
2011/01/11
期日:
進捗率:

0%

予定工数:
category_id:
2
version_id:
33
issue_org_id:
7293
author_id:
6508
assigned_to_id:
0
comments:
22
status_id:
1
tracker_id:
1
plus1:
0
affected_version:
closed_on:
affected_version_id:
20
ステータス-->[New]

説明

Constated on Redmin's main website and demo site as well :

In the Activity tab, the (New) entry displayed for an issue creation changes for a (Resolved) entry if issue's status is modify to be Resolved and so on...

E.g., look at item 7292 on today's page.

This is very weird, so maybe is it a browser (IE8) bug...although I rebooted.


journals

This is not a bug, I still don't understand the way events are recorded but it seems that issue creation event displayed in the Activity page is a pseudo-event, meanin it is not stored in database.

Which is wrong is that the status displayed in the title of the issue creation event is the actual status of the issue !

Either the pseudo event object's status should be forced to "New" or a real event should be stored (better, imho) ?
--------------------------------------------------------------------------------
Etienne Massip wrote:
> This is not a bug, I still don't understand the way events are recorded but it seems that issue creation event displayed in the Activity page is a pseudo-event, meanin it is not stored in database.
>
> Which is wrong is that the status displayed in the title of the issue creation event is the actual status of the issue !
>
> Either the pseudo event object's status should be forced to "New" or a real event should be stored (better, imho) ?

I meant this IS a bug, this is NOT a browser bug.
--------------------------------------------------------------------------------
Easy fix ?

<pre><code class="diff">
--- Base (BASE)
+++ Locally Modified (Based On LOCAL)
@@ -42,7 +42,7 @@
:include => [:project, :journals],
# sort by id so that limited eager loading doesn't break with postgresql
:order_column => "#{table_name}.id"
- acts_as_event :title => Proc.new {|o| "#{o.tracker.name} ##{o.id} (#{o.status}): #{o.subject}"},
+ acts_as_event :title => Proc.new {|o| "#{o.tracker.name} ##{o.id} (#{IssueStatus.default}): #{o.subject}"},
:url => Proc.new {|o| {:controller => 'issues', :action => 'show', :id => o.id}},
:type => Proc.new {|o| 'issue' + (o.closed? ? ' closed' : '') }
</code></pre>
--------------------------------------------------------------------------------
Etienne Massip wrote:
> Easy fix ?
>
> [...]

Bad fix actually, initial status may be any status.
--------------------------------------------------------------------------------
<pre>
h2. werewrerewrewrerew****
> > </pre>[[erererwe!ererewr!]]erewrer
rtrer-reter-ret-erter+retert_ertrtret*rtr*_+---retrtrt
--------------------------------------------------------------------------------
I got a working fix !

See attachment, simply added an @initial_status()@ method to Issue to get the actual status the Issue was open with.

--------------------------------------------------------------------------------
I experienced same bug.

It can be also seen on redmine.org's activity page.

!7293-redmine_org.png!
--------------------------------------------------------------------------------
v2, with test and fixtures (not exactly the same implementation, theoretically not as fast but simpler).

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

--------------------------------------------------------------------------------
I agree with this issue but I think the patch has an undesirable side-effect as it will show the initial issue status on search results as well.
--------------------------------------------------------------------------------
You're right ! I'll post a better patch soon !
--------------------------------------------------------------------------------

--------------------------------------------------------------------------------
Ok, v3.

Sorry, but I didn't find a better way than separating the event concept from the searchable one.
I don't know if this is some desirable thing or not, though, even if I would tend to say that searchables are not events, please tell me.

Also added @options.assert_valid_keys@ in @acts_as_searchable@ and modified the @class@ of the HTML @div@ containing the datetime of the searchable from "author" to "datetime" (none have specific css style).

Tests pass.

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

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

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

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

--------------------------------------------------------------------------------
v4, in a very different style, maybe much cleaner.

Test pass.
--------------------------------------------------------------------------------
Weird, modified files containing a single line are not displayed in the preview page, although they do on my local trunk server.
--------------------------------------------------------------------------------
Note: could use r11412 to solve this.
--------------------------------------------------------------------------------
This bug is still present in version 2.5.1. Within 3 years...
--------------------------------------------------------------------------------
Hi, are there any plans to fix this upstream in versions 3.x?
--------------------------------------------------------------------------------

Admin Redmine さんが約2年前に更新

  • カテゴリIssues_2 にセット
  • 対象バージョンCandidate for next minor release_33 にセット

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

いいね!0
いいね!0