Project

General

Profile

Actions

Feature #2471

closed

Add my activities to my page

Added by Guilherme Schneider almost 16 years ago. Updated about 6 years ago.

Status:
Closed
Priority:
Normal
Assignee:
Category:
My page
Target version:
Start date:
2009-01-08
Due date:
% Done:

0%

Estimated time:
Resolution:
Fixed

Description

I would like to see my user activities in my page.


Files

patch-2471.diff (2.29 KB) patch-2471.diff Go MAEDA, 2014-06-26 03:39
my_activity_block.png (55.4 KB) my_activity_block.png Go MAEDA, 2014-06-26 03:48
add-my-activities-to-my-page.patch (7.82 KB) add-my-activities-to-my-page.patch Mizuki ISHIKAWA, 2018-06-07 04:18
fix_test.patch (950 Bytes) fix_test.patch Mizuki ISHIKAWA, 2018-08-03 02:12
build-status@2x.png (149 KB) build-status@2x.png Go MAEDA, 2018-08-03 02:19

Related issues

Related to Redmine - Feature #574: Add "My issues" to main menuNew

Actions
Related to Redmine - Patch #1081: Add Activity block to My PageClosed2008-04-21

Actions
Related to Redmine - Defect #29816: MyHelper::render_activity_block is not timezone awareClosed

Actions
Actions #1

Updated by Guilherme Schneider almost 16 years ago

This is related to #1002

Actions #2

Updated by Toshi MARUYAMA over 10 years ago

  • Category set to My page
Actions #3

Updated by Toshi MARUYAMA over 10 years ago

  • Related to Feature #574: Add "My issues" to main menu added
Actions #4

Updated by Go MAEDA over 10 years ago

This feature is useful to look back on what I did.

I have made a patch.

Actions #5

Updated by Go MAEDA over 10 years ago

Here is the screenshot of the "My activity" block.

Actions #6

Updated by Toshi MARUYAMA over 10 years ago

  • Related to Patch #1081: Add Activity block to My Page added
Actions #7

Updated by Go MAEDA over 9 years ago

  • Target version set to Candidate for next major release

I think this is useful for project members to look back on their work.

Actions #8

Updated by Mizuki ISHIKAWA over 6 years ago

I fixed a patch written by Go MAEDA (#2471#note-4) to apply to trunk.
In addition, I made partial "activities" and use it in multiple places (my page, activities/index, users/show).

I think that this feature is still necessary now.

Actions #9

Updated by Marius BÄ‚LTEANU over 6 years ago

+1

Actions #10

Updated by Bernhard Rohloff over 6 years ago

For issues I've made something similar with a custom query, but this is much better.
+1

Actions #11

Updated by Go MAEDA over 6 years ago

  • Target version changed from Candidate for next major release to 4.1.0

Setting target version to 4.1.0.

Actions #12

Updated by Go MAEDA over 6 years ago

  • Assignee set to Go MAEDA
Actions #13

Updated by Go MAEDA over 6 years ago

  • Status changed from New to Closed
  • Target version changed from 4.1.0 to 4.0.0
  • Resolution set to Fixed

Committed. Thank you for improving Redmine.

Actions #14

Updated by Mizuki ISHIKAWA over 6 years ago

Thank you for committing.
I checked https://www.redmine.org/builds/ and discovered that testing this feature failed.

Failure:
MyControllerTest#test_page_with_activity [/var/lib/jenkins/workspace/trunk/DATABASE_ADAPTER/mysql/RUBY_VER/ruby-2.4/test/functional/my_controller_test.rb:209]:
Expected at least 1 element matching "a[href="/activity?from=2018-08-01&user_id=2"]", found 0..
Expected 0 to be >= 1.

bin/rails test test/functional/my_controller_test.rb:201

This attached patch will fix the test.

Actions #15

Updated by Go MAEDA over 6 years ago

Mizuki ISHIKAWA wrote:

I checked https://www.redmine.org/builds/ and discovered that testing this feature failed.

Failure:
MyControllerTest#test_page_with_activity [/var/lib/jenkins/workspace/trunk/DATABASE_ADAPTER/mysql/RUBY_VER/ruby-2.4/test/functional/my_controller_test.rb:209]:
Expected at least 1 element matching "a[href="/activity?from=2018-08-01&user_id=2"]", found 0..
Expected 0 to be >= 1.

bin/rails test test/functional/my_controller_test.rb:201

Thank you for pointing it out. I found that the test failed depending on the time.

NG: 2018-08-01 23:30:01 -0700 : https://www.redmine.org/builds/logs/build_trunk_mysql_ruby-2.5_315.html
OK: 2018-08-01 08:00:01 -0700 : https://www.redmine.org/builds/logs/build_trunk_mysql_ruby-2.5_314.html
NG: 2018-07-31 20:00:01 -0700 : https://www.redmine.org/builds/logs/build_trunk_mysql_ruby-2.5_313.html
OK: 2018-07-29 01:00:02 -0700 : https://www.redmine.org/builds/logs/build_trunk_mysql_ruby-2.5_312.html

Actions #16

Updated by Go MAEDA over 6 years ago

Using Date.current which is aware of the application's timezone also should fix the issue.

--- test/functional/my_controller_test.rb    (revision 17462)
+++ test/functional/my_controller_test.rb    (working copy)
@@ -208,7 +208,7 @@

     assert_select 'div#block-activity' do
       assert_select 'h3' do
-        assert_select 'a[href=?]', activity_path(from: Date.today, user_id: user.id),  :text => 'Activity'
+        assert_select 'a[href=?]', activity_path(from: Date.current, user_id: user.id),  :text => 'Activity'
       end
       assert_select 'div#activity' do
         assert_select 'dt', 10
Time Date.today Date.current
08:59 JST (23:59 UTC) FAIL PASS
09:01 JST (00:01 UTC) PASS PASS
Actions #17

Updated by Go MAEDA over 6 years ago

  • Status changed from Reopened to Closed

Mizuki ISHIKAWA wrote:

I checked https://www.redmine.org/builds/ and discovered that testing this feature failed.

Failure:
MyControllerTest#test_page_with_activity [/var/lib/jenkins/workspace/trunk/DATABASE_ADAPTER/mysql/RUBY_VER/ruby-2.4/test/functional/my_controller_test.rb:209]:
Expected at least 1 element matching "a[href="/activity?from=2018-08-01&user_id=2"]", found 0..
Expected 0 to be >= 1.

bin/rails test test/functional/my_controller_test.rb:201

The problem was fixed by r17465.

Actions #18

Updated by Go MAEDA about 6 years ago

  • Related to Defect #29816: MyHelper::render_activity_block is not timezone aware added
Actions #19

Updated by Go MAEDA about 6 years ago

  • Status changed from Closed to Reopened

The new block is not aware of timezone when grouping events by date. The patch to fix the issue was posted as #29816.

Actions #20

Updated by Go MAEDA about 6 years ago

  • Status changed from Reopened to Closed

Go MAEDA wrote:

The new block is not aware of timezone when grouping events by date. The patch to fix the issue was posted as #29816.

Committed the patch.

Actions

Also available in: Atom PDF