Project

General

Profile

Actions

Patch #738

closed

my page: new "Projects I am in" block

Added by chris mcharg over 16 years ago. Updated almost 12 years ago.

Status:
Closed
Priority:
Normal
Assignee:
-
Category:
UI
Target version:
-
Start date:
2008-02-25
Due date:
% Done:

100%

Estimated time:

Description

The info that I really want on my my page is a list of tickets assigned to me and a list of projects I'm in.

This patch adds a block for the list of projects... nice and simple.

It is based on existing code, so it should work OK :)


Files

mypage-block-projects.patch (2.27 KB) mypage-block-projects.patch chris mcharg, 2008-02-25 15:50
mypage-block-projects_2.patch (1.87 KB) mypage-block-projects_2.patch Romain GEORGES, 2009-03-09 10:51
Actions #1

Updated by Raz Mataz over 16 years ago

i vote +1 for that feature

Actions #2

Updated by Bill Marquette over 16 years ago

This is also something I just wrote for my own install within two hours of installation. The biggest difference between the attached patch and what I did, was that I used the find code right out of the projects controller to find the list of projects (Project.find :all, :conditions => Project.visible_by(User.current), :include => :parent)

Actions #3

Updated by Romain GEORGES over 15 years ago

update for the new version (resolve the bug with "parent")
The code is like in account/show

<h3><%=l(:label_projects_i_am_in)%></h3>

<% user = User.active.current
memberships = user.memberships.select do |membership|
membership.project.is_public? || (User.current.member_of?(membership.project))
end
>
<
unless memberships.empty? >
<h3><
=l(:label_project_plural)%></h3>
<ul>
<% for membership in memberships >
<li><
= link_to(h(membership.project.name), :controller => 'projects', :action => 'show', :id => membership.project) >
(<
=h membership.role.name >, <= format_date(membership.created_on) >)</li>
<
end >
</ul>
<
end %>

<p class="small"><%= link_to l(:label_project_all), :controller => 'projects', :action => 'index' %></p>

Actions #4

Updated by Romain GEORGES over 15 years ago

Oups sorry for this crash text ;)
I will join a new version of the patch file

Actions #6

Updated by Ladislav Nesnera almost 14 years ago

  • Status changed from New to Resolved
  • % Done changed from 0 to 100

It seems be resolved. I'm closing ;?)

Actions #7

Updated by Jan Niggemann (redmine.org team member) almost 12 years ago

  • Status changed from Resolved to Closed

Closing this, status is resolved since 400 days and more (issue was last updated more than 400 days ago)...

Actions

Also available in: Atom PDF