Merge lp:~mhall119/loco-team-portal/event-list-as-table into lp:loco-team-portal

Proposed by Michael Hall
Status: Merged
Merged at revision: not available
Proposed branch: lp:~mhall119/loco-team-portal/event-list-as-table
Merge into: lp:loco-team-portal
Diff against target: 105 lines (+59/-16)
3 files modified
loco_directory/media/css/events.css (+31/-0)
loco_directory/templates/events/global_event_list.inc.html (+13/-8)
loco_directory/templates/events/team_event_list.inc.html (+15/-8)
To merge this branch: bzr merge lp:~mhall119/loco-team-portal/event-list-as-table
Reviewer Review Type Date Requested Status
Daniel Holbach (community) Approve
Review via email: mp+24135@code.launchpad.net

Description of the change

Replace lists with tables for displaying upcoming events

To post a comment you must log in.
111. By Michael Hall

Remove misplaced /

Revision history for this message
Daniel Holbach (dholbach) wrote :

Good work!

review: Approve

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file 'loco_directory/media/css/events.css'
2--- loco_directory/media/css/events.css 2010-04-07 00:24:48 +0000
3+++ loco_directory/media/css/events.css 2010-04-26 16:45:34 +0000
4@@ -10,6 +10,37 @@
5 font-weight: bold;
6 }
7
8+#team_event_list {
9+ width: 80%;
10+}
11+
12+#global_event_list {
13+ width: 60%;
14+}
15+
16+#team_event_list TH {
17+ white-space: nowrap;
18+}
19+
20+#global_event_list .odd, #team_event_list .odd {
21+ background-color: #fcf7e6;
22+}
23+#global_event_list .even, #team_event_list .even {
24+ background-color: #ffffff;
25+}
26+#team_event_list TD, #global_event_list TD {
27+ text-align: center;
28+ white-space: nowrap;
29+}
30+#team_event_list TH.event_name, #global_event_list TH.event_name {
31+ text-align: left;
32+ white-space: normal;
33+}
34+#team_event_list TD.event_name, #global_event_list TD.event_name {
35+ text-align: left;
36+ white-space: normal;
37+}
38+
39 #global-event-attending-teamevents li.col_left {
40 float: left;
41 width: 50%;
42
43=== modified file 'loco_directory/templates/events/global_event_list.inc.html'
44--- loco_directory/templates/events/global_event_list.inc.html 2010-03-20 11:47:47 +0000
45+++ loco_directory/templates/events/global_event_list.inc.html 2010-04-26 16:45:34 +0000
46@@ -1,14 +1,19 @@
47 {% load i18n %}
48-<table width="100%">
49-<tr>
50-<td width="100%" valign="top" class="col2_container">
51-<ul>
52+<table id="global_event_list">
53+<tr id="global_event_list_header">
54+<th class="event_name">{% trans "Event name" %}</th>
55+<th class="event_begin">{% trans "Start" %}</th>
56+<th class="event_end">{% trans "End" %}</th>
57+<th class="event_tems">{% trans "Team Events" %}</th>
58+</tr>
59 {% for global_event in global_event_list %}
60-<li class="{% cycle 'col_left' 'col_right'%}"><a href="{{global_event.get_absolute_url }}">{{ global_event.name }}</a> {% trans "starts on: " %}{{ global_event.date_begin|date}} ({{global_event.teamevent_set.all.count}} {% trans "team events attend." %})</li>
61+<tr class="global_event_list_row {% cycle "odd" "even" %}">
62+<td class="event_name"><a title="{% trans "more information about this event" %}" href="{{ global_event.get_absolute_url }}">{{ global_event.name }}</a></td>
63+<td class="event_begin">{{global_event.date_begin|date}}</td>
64+<td class="event_end">{{global_event.date_end|date}}</td>
65+<td class="event_teams">{{global_event.teamevent_set.all.count}}</td>
66+</tr>
67 {% endfor %}
68-</ul>
69-</td>
70-</tr>
71 </table>
72
73
74
75=== modified file 'loco_directory/templates/events/team_event_list.inc.html'
76--- loco_directory/templates/events/team_event_list.inc.html 2010-03-23 11:16:45 +0000
77+++ loco_directory/templates/events/team_event_list.inc.html 2010-04-26 16:45:34 +0000
78@@ -1,14 +1,21 @@
79 {% load i18n %}
80-<table width="100%">
81-<tr>
82-<td width="100%" valign="top" class="col2_container">
83-<ul>
84+<table id="team_event_list">
85+<tr id="team_event_list_header">
86+<th class="event_name">{% trans "Event name" %}</th>
87+<th class="event_begin">{% trans "Start" %}</th>
88+<th class="event_end">{% trans "End" %}</th>
89+<th class="event_global">{% trans "Global Event" %}</th>
90+<th class="event_teams">{% trans "Teams" %}</th>
91+</tr>
92 {% for team_event in team_event_list %}
93-<li class="{% cycle 'col_left' 'col_right'%}"><a title="{% trans "more information about this event" %}" href="{{ team_event.get_absolute_url }}">{{ team_event.name }}</a> {% trans "starts on: " %}{{ team_event.date_begin|date}} ({% for team in team_event.teams.all %}<a title="{% trans "more information about this team" %}" href="{{ team.get_absolute_url }}">{{team.lp_name}}</a>{% if not forloop.last %},{% endif %}{% endfor %})</li>
94+<tr class="team_event_list_row {% cycle "odd" "even" %}">
95+<td class="event_name"><a title="{% trans "more information about this event" %}" href="{{ team_event.get_absolute_url }}">{{ team_event.name }}</a></td>
96+<td class="event_begin">{{team_event.date_begin|date}} {{ team_event.date_begin|date:"H:i T"}}</td>
97+<td class="event_end">{{team_event.date_end|date}} {{ team_event.date_end|date:"H:i T"}}</td>
98+<td class="event_global">{% if team_event.global_event %}<a href="{{ team_event.global_event.get_absolute_url }}">{{ team_event.global_event.name}}</a>{% else %}--{% endif %}</td>
99+<td class="event_teams">{% for team in team_event.teams.all %}<a title="{% trans "more information about this team" %}" href="{{ team.get_absolute_url }}">{{team.lp_name}}</a>{% if not forloop.last %}<br/>{% endif %}{% endfor %}</td>
100+</tr>
101 {% endfor %}
102-</ul>
103-</td>
104-</tr>
105 </table>
106
107

Subscribers

People subscribed via source and target branches