Merge lp:~bac/launchpad/bug-429455-team-pages into lp:launchpad
- bug-429455-team-pages
- Merge into devel
Status: | Merged | ||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|
Approved by: | Curtis Hovey | ||||||||||||
Approved revision: | no longer in the source branch. | ||||||||||||
Merged at revision: | not available | ||||||||||||
Proposed branch: | lp:~bac/launchpad/bug-429455-team-pages | ||||||||||||
Merge into: | lp:launchpad | ||||||||||||
Diff against target: | None lines | ||||||||||||
To merge this branch: | bzr merge lp:~bac/launchpad/bug-429455-team-pages | ||||||||||||
Related bugs: |
|
Reviewer | Review Type | Date Requested | Status |
---|---|---|---|
Curtis Hovey (community) | code | Approve | |
Canonical Launchpad Engineering | Pending | ||
Review via email: mp+11739@code.launchpad.net |
Commit message
Description of the change
Brad Crittenden (bac) wrote : | # |
Curtis Hovey (sinzui) wrote : | # |
This looks pretty good. I have a few remarks that I think will improve the code before you land it.
> === modified file 'lib/canonical/
> --- lib/canonical/
> +++ lib/canonical/
> @@ -1033,8 +1033,6 @@
> team_mailinglis
> 'Mailing list subscribers for the %s team')
>
> -team_map = ContextBrowsern
> -
> team_members = ContextBrowsern
>
> team_mugshots = ContextBrowsern
Why didn't you remove these? IS it because base-layout still requires a
page_title. I think you can do this in the page views.
page_title = label
So that you can remove the entries from pagetitles.py
> === modified file 'lib/lp/
> --- lib/lp/
> +++ lib/lp/
...
> @@ -4564,6 +4568,10 @@
> getUtility(
>
> @cachedproperty
> + def label(self):
> + return "Who's in this team?"
This does not need to be a cachedproperty.
label = "Who's in this team?"
> === modified file 'lib/lp/
> --- lib/lp/
> +++ lib/lp/
> @@ -1019,6 +1019,10 @@
> self.request.
>
> @cachedproperty
> + def label(self):
> + return "Team member locations"
This does not need to be a cachedproperty.
label = "Team member locations"
Barry Warsaw (barry) wrote : | # |
On Sep 14, 2009, at 5:35 PM, Curtis Hovey wrote:
> Why didn't you remove these? IS it because base-layout still
> requires a
> page_title. I think you can do this in the page views.
>
> page_title = label
>
> So that you can remove the entries from pagetitles.py
base-layout only requires page_title in some limited circumstances.
https:/
Brad Crittenden (bac) wrote : | # |
On Sep 14, 2009, at 17:35 , Curtis Hovey wrote:
> Review: Approve code
> This looks pretty good. I have a few remarks that I think will
> improve the code before you land it.
>
>> === modified file 'lib/canonical/
>> --- lib/canonical/
>> +++ lib/canonical/
>> @@ -1033,8 +1033,6 @@
>> team_mailinglis
>> 'Mailing list subscribers for the %s team')
>>
>> -team_map = ContextBrowsern
>> -
>> team_members = ContextBrowsern
>>
>> team_mugshots = ContextBrowsern
>> team'))
>
> Why didn't you remove these? IS it because base-layout still
> requires a
> page_title. I think you can do this in the page views.
I just forgot. Thanks for catching them.
>
> page_title = label
>
> So that you can remove the entries from pagetitles.py
These views did not require a page_title.
>
>> === modified file 'lib/lp/
>> --- lib/lp/
>> +++ lib/lp/
>
> ...
>
>> @@ -4564,6 +4568,10 @@
>> getUtility(
>> (self.allmembers)
>>
>> @cachedproperty
>> + def label(self):
>> + return "Who's in this team?"
>
> This does not need to be a cachedproperty.
>
> label = "Who's in this team?"
Of course. Done.
>
>> === modified file 'lib/lp/
>> --- lib/lp/
>> +++ lib/lp/
>> @@ -1019,6 +1019,10 @@
>> self.request.
>>
>> @cachedproperty
>> + def label(self):
>> + return "Team member locations"
>
> This does not need to be a cachedproperty.
>
> label = "Team member locations"
>
Done.
Preview Diff
1 | === modified file 'configs/development/launchpad-lazr.conf' | |||
2 | --- configs/development/launchpad-lazr.conf 2009-08-19 12:28:32 +0000 | |||
3 | +++ configs/development/launchpad-lazr.conf 2009-09-14 19:32:10 +0000 | |||
4 | @@ -145,6 +145,7 @@ | |||
5 | 145 | restricted_upload_port: 58095 | 145 | restricted_upload_port: 58095 |
6 | 146 | restricted_download_port: 58085 | 146 | restricted_download_port: 58085 |
7 | 147 | restricted_download_url: http://launchpad.dev:58085/ | 147 | restricted_download_url: http://launchpad.dev:58085/ |
8 | 148 | use_https = False | ||
9 | 148 | 149 | ||
10 | 149 | [librarian_server] | 150 | [librarian_server] |
11 | 150 | root: /var/tmp/fatsam | 151 | root: /var/tmp/fatsam |
12 | 151 | 152 | ||
13 | === modified file 'lib/canonical/config/schema-lazr.conf' | |||
14 | --- lib/canonical/config/schema-lazr.conf 2009-09-14 09:12:58 +0000 | |||
15 | +++ lib/canonical/config/schema-lazr.conf 2009-09-14 19:32:10 +0000 | |||
16 | @@ -1144,6 +1144,8 @@ | |||
17 | 1144 | # datatype: urlbase | 1144 | # datatype: urlbase |
18 | 1145 | restricted_download_url: http://restricted-librarian.launchpad.net/ | 1145 | restricted_download_url: http://restricted-librarian.launchpad.net/ |
19 | 1146 | 1146 | ||
20 | 1147 | use_https = True | ||
21 | 1148 | |||
22 | 1147 | [librarian_gc] | 1149 | [librarian_gc] |
23 | 1148 | # The database user which will be used by this process. | 1150 | # The database user which will be used by this process. |
24 | 1149 | # datatype: string | 1151 | # datatype: string |
25 | 1150 | 1152 | ||
26 | === modified file 'lib/canonical/launchpad/database/librarian.py' | |||
27 | --- lib/canonical/launchpad/database/librarian.py 2009-08-27 01:32:01 +0000 | |||
28 | +++ lib/canonical/launchpad/database/librarian.py 2009-09-14 19:32:10 +0000 | |||
29 | @@ -98,7 +98,7 @@ | |||
30 | 98 | 98 | ||
31 | 99 | def getURL(self): | 99 | def getURL(self): |
32 | 100 | """See ILibraryFileAlias.getURL""" | 100 | """See ILibraryFileAlias.getURL""" |
34 | 101 | if config.vhosts.use_https: | 101 | if config.librarian.use_https: |
35 | 102 | return self.https_url | 102 | return self.https_url |
36 | 103 | else: | 103 | else: |
37 | 104 | return self.http_url | 104 | return self.http_url |
38 | 105 | 105 | ||
39 | === modified file 'lib/canonical/launchpad/pagetitles.py' | |||
40 | --- lib/canonical/launchpad/pagetitles.py 2009-09-14 15:16:12 +0000 | |||
41 | +++ lib/canonical/launchpad/pagetitles.py 2009-09-14 19:38:57 +0000 | |||
42 | @@ -1033,8 +1033,6 @@ | |||
43 | 1033 | team_mailinglist_subscribers = ContextBrowsername( | 1033 | team_mailinglist_subscribers = ContextBrowsername( |
44 | 1034 | 'Mailing list subscribers for the %s team') | 1034 | 'Mailing list subscribers for the %s team') |
45 | 1035 | 1035 | ||
46 | 1036 | team_map = ContextBrowsername('Map of %s participants') | ||
47 | 1037 | |||
48 | 1038 | team_members = ContextBrowsername(smartquote('"%s" members')) | 1036 | team_members = ContextBrowsername(smartquote('"%s" members')) |
49 | 1039 | 1037 | ||
50 | 1040 | team_mugshots = ContextBrowsername(smartquote('Mugshots in the "%s" team')) | 1038 | team_mugshots = ContextBrowsername(smartquote('Mugshots in the "%s" team')) |
51 | 1041 | 1039 | ||
52 | === modified file 'lib/lp/registry/browser/person.py' | |||
53 | --- lib/lp/registry/browser/person.py 2009-09-14 14:10:10 +0000 | |||
54 | +++ lib/lp/registry/browser/person.py 2009-09-14 19:32:10 +0000 | |||
55 | @@ -1327,7 +1327,11 @@ | |||
56 | 1327 | 1327 | ||
57 | 1328 | 1328 | ||
58 | 1329 | class TeamMembershipView(LaunchpadView): | 1329 | class TeamMembershipView(LaunchpadView): |
60 | 1330 | """The view behins ITeam/+members.""" | 1330 | """The view behind ITeam/+members.""" |
61 | 1331 | |||
62 | 1332 | @cachedproperty | ||
63 | 1333 | def label(self): | ||
64 | 1334 | return smartquote('Members of "%s"' % self.context.displayname) | ||
65 | 1331 | 1335 | ||
66 | 1332 | @cachedproperty | 1336 | @cachedproperty |
67 | 1333 | def active_memberships(self): | 1337 | def active_memberships(self): |
68 | @@ -4564,6 +4568,10 @@ | |||
69 | 4564 | getUtility(IPersonSet).cacheBrandingForPeople(self.allmembers) | 4568 | getUtility(IPersonSet).cacheBrandingForPeople(self.allmembers) |
70 | 4565 | 4569 | ||
71 | 4566 | @cachedproperty | 4570 | @cachedproperty |
72 | 4571 | def label(self): | ||
73 | 4572 | return "Who's in this team?" | ||
74 | 4573 | |||
75 | 4574 | @cachedproperty | ||
76 | 4567 | def allmembers(self): | 4575 | def allmembers(self): |
77 | 4568 | return list(self.context.allmembers) | 4576 | return list(self.context.allmembers) |
78 | 4569 | 4577 | ||
79 | 4570 | 4578 | ||
80 | === modified file 'lib/lp/registry/browser/team.py' | |||
81 | --- lib/lp/registry/browser/team.py 2009-09-01 19:43:30 +0000 | |||
82 | +++ lib/lp/registry/browser/team.py 2009-09-14 19:32:10 +0000 | |||
83 | @@ -1019,6 +1019,10 @@ | |||
84 | 1019 | self.request.needs_gmap2 = True | 1019 | self.request.needs_gmap2 = True |
85 | 1020 | 1020 | ||
86 | 1021 | @cachedproperty | 1021 | @cachedproperty |
87 | 1022 | def label(self): | ||
88 | 1023 | return "Team member locations" | ||
89 | 1024 | |||
90 | 1025 | @cachedproperty | ||
91 | 1022 | def mapped_participants(self): | 1026 | def mapped_participants(self): |
92 | 1023 | """Participants with locations.""" | 1027 | """Participants with locations.""" |
93 | 1024 | return self.context.getMappedParticipants(limit=self.limit) | 1028 | return self.context.getMappedParticipants(limit=self.limit) |
94 | 1025 | 1029 | ||
95 | === modified file 'lib/lp/registry/stories/foaf/xx-team-membership.txt' | |||
96 | --- lib/lp/registry/stories/foaf/xx-team-membership.txt 2009-01-03 19:32:48 +0000 | |||
97 | +++ lib/lp/registry/stories/foaf/xx-team-membership.txt 2009-09-14 20:37:47 +0000 | |||
98 | @@ -3,8 +3,6 @@ | |||
99 | 3 | >>> browser.open('http://launchpad.dev/~ubuntu-team/+members') | 3 | >>> browser.open('http://launchpad.dev/~ubuntu-team/+members') |
100 | 4 | >>> 'Ubuntu Team' in browser.contents | 4 | >>> 'Ubuntu Team' in browser.contents |
101 | 5 | True | 5 | True |
102 | 6 | >>> 'Mark Shuttleworth' in browser.contents | ||
103 | 7 | True | ||
104 | 8 | 6 | ||
105 | 9 | Let's take a look at Colin's subscription page. Colin is an | 7 | Let's take a look at Colin's subscription page. Colin is an |
106 | 10 | administrator and his subscription never expires. | 8 | administrator and his subscription never expires. |
107 | @@ -240,4 +238,3 @@ | |||
108 | 240 | >>> indirect = find_portlet(browser.contents, 'Indirect membership') | 238 | >>> indirect = find_portlet(browser.contents, 'Indirect membership') |
109 | 241 | >>> print indirect | 239 | >>> print indirect |
110 | 242 | None | 240 | None |
111 | 243 | |||
112 | 244 | 241 | ||
113 | === modified file 'lib/lp/registry/stories/location/team-map.txt' | |||
114 | --- lib/lp/registry/stories/location/team-map.txt 2009-06-12 16:36:02 +0000 | |||
115 | +++ lib/lp/registry/stories/location/team-map.txt 2009-09-14 21:01:18 +0000 | |||
116 | @@ -15,16 +15,12 @@ | |||
117 | 15 | >>> 'build/lp/mapping.js' in markup | 15 | >>> 'build/lp/mapping.js' in markup |
118 | 16 | True | 16 | True |
119 | 17 | 17 | ||
122 | 18 | You should also be able to see a map of the team, with links to the people | 18 | You should also be able to see a map of the team. |
121 | 19 | who need to have location data added to complete the team. | ||
123 | 20 | 19 | ||
124 | 21 | >>> maplink = nopriv_browser.getLink('View map and time zones') | 20 | >>> maplink = nopriv_browser.getLink('View map and time zones') |
125 | 22 | >>> maplink.click() | 21 | >>> maplink.click() |
126 | 23 | >>> nopriv_browser.url | 22 | >>> nopriv_browser.url |
127 | 24 | 'http://launchpad.dev/~guadamen/+map' | 23 | 'http://launchpad.dev/~guadamen/+map' |
128 | 25 | >>> link = nopriv_browser.getLink('Edgar Bursic') | ||
129 | 26 | >>> link.url | ||
130 | 27 | 'http://launchpad.dev/~edgar/+editlocation?for_team=guadamen' | ||
131 | 28 | 24 | ||
132 | 29 | The map depends on a stream of XML-formatted data, giving the locations of | 25 | The map depends on a stream of XML-formatted data, giving the locations of |
133 | 30 | all members of the team. We show that this stream works for teams with, and | 26 | all members of the team. We show that this stream works for teams with, and |
134 | @@ -60,24 +56,6 @@ | |||
135 | 60 | </participants> | 56 | </participants> |
136 | 61 | <BLANKLINE> | 57 | <BLANKLINE> |
137 | 62 | 58 | ||
138 | 63 | We have a nice way to add locations for all the members of a team. We look | ||
139 | 64 | at a page which shows all the members of the team on a map, together with | ||
140 | 65 | links to edit the location of folks who have not yet been mapped. When we | ||
141 | 66 | click on those links, we pass the name of the team, so when the location is | ||
142 | 67 | added, we come back to the team map, and from there we can click on the next | ||
143 | 68 | person. | ||
144 | 69 | |||
145 | 70 | >>> admin_browser.open('http://launchpad.dev/~guadamen/+map') | ||
146 | 71 | >>> admin_browser.getLink('Edgar Bursic').click() | ||
147 | 72 | >>> admin_browser.url | ||
148 | 73 | 'http://launchpad.dev/~edgar/+editlocation?for_team=guadamen' | ||
149 | 74 | >>> admin_browser.getControl(name='field.location.latitude').value = '37.3' | ||
150 | 75 | >>> admin_browser.getControl(name='field.location.longitude').value = '2.45' | ||
151 | 76 | >>> admin_browser.getControl(name='field.location.time_zone').value = ['Europe/Madrid'] | ||
152 | 77 | >>> admin_browser.getControl('Update').click() | ||
153 | 78 | >>> admin_browser.url | ||
154 | 79 | 'http://launchpad.dev/~guadamen/+map' | ||
155 | 80 | |||
156 | 81 | It doesn't make sense to edit the location of the team itself, not even | 59 | It doesn't make sense to edit the location of the team itself, not even |
157 | 82 | if we are an admin, so a team's +editlocation page will simply redirect | 60 | if we are an admin, so a team's +editlocation page will simply redirect |
158 | 83 | to +map. | 61 | to +map. |
159 | @@ -92,13 +70,13 @@ | |||
160 | 92 | The display name of all team participants will be escaped to prevent | 70 | The display name of all team participants will be escaped to prevent |
161 | 93 | XSS attacks on any callsite of +mapdata. | 71 | XSS attacks on any callsite of +mapdata. |
162 | 94 | 72 | ||
164 | 95 | >>> admin_browser.open('http://launchpad.dev/~edgar/+edit') | 73 | >>> admin_browser.open('http://launchpad.dev/~kamion/+edit') |
165 | 96 | >>> admin_browser.getControl('Display Name').value = ( | 74 | >>> admin_browser.getControl('Display Name').value = ( |
167 | 97 | ... "<script>alert('John \"nasty\"');</script>") | 75 | ... "<script>alert('Colin \"nasty\"');</script>") |
168 | 98 | >>> admin_browser.getControl('Save Changes').click() | 76 | >>> admin_browser.getControl('Save Changes').click() |
169 | 99 | 77 | ||
170 | 100 | >>> anon_browser.open('http://launchpad.dev/~guadamen/+mapdata') | 78 | >>> anon_browser.open('http://launchpad.dev/~guadamen/+mapdata') |
171 | 101 | >>> print anon_browser.contents | 79 | >>> print anon_browser.contents |
172 | 102 | <?xml version="1.0"... | 80 | <?xml version="1.0"... |
174 | 103 | ...displayname="&lt;script&gt;alert('John &quot;nasty&quot;');&lt;/script&gt;" | 81 | ...displayname="&lt;script&gt;alert('Colin &quot;nasty&quot;');&lt;/script&gt;" |
175 | 104 | ... | 82 | ... |
176 | 105 | 83 | ||
177 | === modified file 'lib/lp/registry/templates/team-map.pt' | |||
178 | --- lib/lp/registry/templates/team-map.pt 2009-07-17 17:59:07 +0000 | |||
179 | +++ lib/lp/registry/templates/team-map.pt 2009-09-14 20:48:51 +0000 | |||
180 | @@ -3,10 +3,7 @@ | |||
181 | 3 | xmlns:tal="http://xml.zope.org/namespaces/tal" | 3 | xmlns:tal="http://xml.zope.org/namespaces/tal" |
182 | 4 | xmlns:metal="http://xml.zope.org/namespaces/metal" | 4 | xmlns:metal="http://xml.zope.org/namespaces/metal" |
183 | 5 | xmlns:i18n="http://xml.zope.org/namespaces/i18n" | 5 | xmlns:i18n="http://xml.zope.org/namespaces/i18n" |
188 | 6 | xml:lang="en" | 6 | metal:use-macro="view/macro:page/main_only" |
185 | 7 | lang="en" | ||
186 | 8 | dir="ltr" | ||
187 | 9 | metal:use-macro="view/macro:page/onecolumn" | ||
189 | 10 | i18n:domain="launchpad" | 7 | i18n:domain="launchpad" |
190 | 11 | > | 8 | > |
191 | 12 | 9 | ||
192 | @@ -14,28 +11,6 @@ | |||
193 | 14 | 11 | ||
194 | 15 | <div metal:fill-slot="main"> | 12 | <div metal:fill-slot="main"> |
195 | 16 | 13 | ||
196 | 17 | <h1>Members' location</h1> | ||
197 | 18 | |||
198 | 19 | <tal:unmapped condition="view/unmapped_participants_count"> | ||
199 | 20 | <div style="margin: 4px;"> | ||
200 | 21 | <h2>Complete the map!</h2> | ||
201 | 22 | Do you know the current location for these team members? Set their | ||
202 | 23 | locations! | ||
203 | 24 | </div> | ||
204 | 25 | |||
205 | 26 | <div style="margin-bottom: 2em;"> | ||
206 | 27 | <span style="float: left; width: 15em" | ||
207 | 28 | tal:repeat="person view/unmapped_participants"> | ||
208 | 29 | <a tal:condition="person/name|nothing" | ||
209 | 30 | tal:attributes=" | ||
210 | 31 | href string:${person/fmt:url}/+editlocation?for_team=${context/name}" | ||
211 | 32 | title="Set this person's location" | ||
212 | 33 | ><img src="/@@/edit" /> | ||
213 | 34 | <tal:person replace="person/displayname" /></a> | ||
214 | 35 | </span> | ||
215 | 36 | </div> | ||
216 | 37 | </tal:unmapped> | ||
217 | 38 | |||
218 | 39 | <div style="height:420px;"> | 14 | <div style="height:420px;"> |
219 | 40 | <div tal:condition="not: view/has_mapped_participants"> | 15 | <div tal:condition="not: view/has_mapped_participants"> |
220 | 41 | None of the current participants in | 16 | None of the current participants in |
221 | 42 | 17 | ||
222 | === modified file 'lib/lp/registry/templates/team-members.pt' | |||
223 | --- lib/lp/registry/templates/team-members.pt 2009-07-17 17:59:07 +0000 | |||
224 | +++ lib/lp/registry/templates/team-members.pt 2009-09-14 19:32:10 +0000 | |||
225 | @@ -3,27 +3,16 @@ | |||
226 | 3 | xmlns:tal="http://xml.zope.org/namespaces/tal" | 3 | xmlns:tal="http://xml.zope.org/namespaces/tal" |
227 | 4 | xmlns:metal="http://xml.zope.org/namespaces/metal" | 4 | xmlns:metal="http://xml.zope.org/namespaces/metal" |
228 | 5 | xmlns:i18n="http://xml.zope.org/namespaces/i18n" | 5 | xmlns:i18n="http://xml.zope.org/namespaces/i18n" |
233 | 6 | xml:lang="en" | 6 | metal:use-macro="view/macro:page/main_only" |
230 | 7 | lang="en" | ||
231 | 8 | dir="ltr" | ||
232 | 9 | metal:use-macro="context/@@main_template/master" | ||
234 | 10 | i18n:domain="launchpad" | 7 | i18n:domain="launchpad" |
235 | 11 | > | 8 | > |
236 | 12 | 9 | ||
237 | 13 | <body> | 10 | <body> |
238 | 14 | 11 | ||
239 | 15 | <metal:portlets fill-slot="portlets"> | ||
240 | 16 | <div tal:replace="structure context/@@+portlet-details" /> | ||
241 | 17 | </metal:portlets> | ||
242 | 18 | |||
243 | 19 | <div metal:fill-slot="main" | 12 | <div metal:fill-slot="main" |
244 | 20 | tal:define="user_can_edit_memberships context/required:launchpad.Edit; | 13 | tal:define="user_can_edit_memberships context/required:launchpad.Edit; |
245 | 21 | active_member_count context/active_member_count"> | 14 | active_member_count context/active_member_count"> |
246 | 22 | 15 | ||
247 | 23 | <h1>Members of | ||
248 | 24 | “<span tal:replace="context/displayname" />” | ||
249 | 25 | </h1> | ||
250 | 26 | |||
251 | 27 | <p>Active, pending and former members of this team.</p> | 16 | <p>Active, pending and former members of this team.</p> |
252 | 28 | 17 | ||
253 | 29 | <ul> | 18 | <ul> |
254 | @@ -34,7 +23,7 @@ | |||
255 | 34 | 23 | ||
256 | 35 | <p> | 24 | <p> |
257 | 36 | There are <span tal:replace="active_member_count">15</span> | 25 | There are <span tal:replace="active_member_count">15</span> |
259 | 37 | direct members of the | 26 | direct members of the |
260 | 38 | "<span tal:replace="context/displayname">Ubuntu Members</span>" team, | 27 | "<span tal:replace="context/displayname">Ubuntu Members</span>" team, |
261 | 39 | and <span tal:replace="context/all_member_count">23</span> people are | 28 | and <span tal:replace="context/all_member_count">23</span> people are |
262 | 40 | members in total, directly and indirectly through other team | 29 | members in total, directly and indirectly through other team |
263 | @@ -103,7 +92,7 @@ | |||
264 | 103 | 92 | ||
265 | 104 | <li tal:condition="not: active_member_count"> | 93 | <li tal:condition="not: active_member_count"> |
266 | 105 | <h2> | 94 | <h2> |
268 | 106 | “<span tal:replace="context/displayname" />” has no | 95 | “<span tal:replace="context/displayname" />” has no |
269 | 107 | members | 96 | members |
270 | 108 | </h2> | 97 | </h2> |
271 | 109 | 98 | ||
272 | 110 | 99 | ||
273 | === modified file 'lib/lp/registry/templates/team-mugshots.pt' | |||
274 | --- lib/lp/registry/templates/team-mugshots.pt 2009-07-17 17:59:07 +0000 | |||
275 | +++ lib/lp/registry/templates/team-mugshots.pt 2009-09-14 19:32:10 +0000 | |||
276 | @@ -3,32 +3,25 @@ | |||
277 | 3 | xmlns:tal="http://xml.zope.org/namespaces/tal" | 3 | xmlns:tal="http://xml.zope.org/namespaces/tal" |
278 | 4 | xmlns:metal="http://xml.zope.org/namespaces/metal" | 4 | xmlns:metal="http://xml.zope.org/namespaces/metal" |
279 | 5 | xmlns:i18n="http://xml.zope.org/namespaces/i18n" | 5 | xmlns:i18n="http://xml.zope.org/namespaces/i18n" |
284 | 6 | xml:lang="en" | 6 | metal:use-macro="view/macro:page/main_only" |
281 | 7 | lang="en" | ||
282 | 8 | dir="ltr" | ||
283 | 9 | metal:use-macro="context/@@main_template/master" | ||
285 | 10 | i18n:domain="launchpad" | 7 | i18n:domain="launchpad" |
286 | 11 | > | 8 | > |
287 | 12 | 9 | ||
288 | 13 | <body> | 10 | <body> |
289 | 14 | 11 | ||
290 | 15 | <metal:heading fill-slot="pageheading"> | ||
291 | 16 | <h1>Who's in this team?</h1> | ||
292 | 17 | </metal:heading> | ||
293 | 18 | |||
294 | 19 | <div metal:fill-slot="main"> | 12 | <div metal:fill-slot="main"> |
295 | 20 | 13 | ||
307 | 21 | <tal:per_member repeat="member view/allmembers"> | 14 | <tal:per_member repeat="member view/allmembers"> |
308 | 22 | <a tal:condition="member/mugshot" | 15 | <a tal:condition="member/mugshot" |
309 | 23 | tal:attributes=" | 16 | tal:attributes=" |
310 | 24 | href member/fmt:url; | 17 | href member/fmt:url; |
311 | 25 | title member/displayname"> | 18 | title member/displayname"> |
312 | 26 | <img tal:attributes="src member/mugshot/http_url"/> | 19 | <img tal:attributes="src member/mugshot/http_url"/> |
313 | 27 | </a> | 20 | </a> |
314 | 28 | <span style="white-space: nowrap;" tal:condition="not: member/mugshot"> | 21 | <span style="white-space: nowrap;" tal:condition="not: member/mugshot"> |
315 | 29 | [<a tal:content="member/displayname" | 22 | [<a tal:content="member/displayname" |
316 | 30 | tal:attributes="href member/fmt:url">Foo Bar</a>]</span> | 23 | tal:attributes="href member/fmt:url">Foo Bar</a>]</span> |
317 | 31 | </tal:per_member> | 24 | </tal:per_member> |
318 | 32 | 25 | ||
319 | 33 | </div> | 26 | </div> |
320 | 34 | </body> | 27 | </body> |
= Summary =
Bug 429455 requires the conversion of three team pages to UI 3.0:
team-map.pt
team-mugshots.pt
team-members.pt
== Proposed fix ==
Provide changes to fulfill the new UI requirements.
== Pre-implementation notes ==
N/A
== Implementation details ==
* team-map.pt
* Convert to main_only.
* Remove from pagetitles.py
* Create label property
* Remove h1
* Remove the section that displays team members with no location
data and invites anyone to set it for them - Bug 262193
* team-mugshots.pt
* Convert to main_only.
* Remove from pagetitles.py
* Create label property
* Remove h1
* team-members.pt
== Tests ==
bin/test -vvm lp.registry -t team-map.txt mailinglists/ moderation. txt
-t stories/
== Demo and Q/A ==
Screenshots are available at people. canonical. com/~bac/ bug-429455- team-pages
http://
* As Mark, go to: https:/ /launchpad. dev/~hwdb- team/+map
* Note page title, label, and breadcrumbs.
* Go to https:/ /launchpad. dev/~hwdb- team/+mugshots
* Note page title, label, and breadcrumbs.
* Without the side there is much more real estate for photos.
* Go to https:/ /launchpad. dev/~hwdb- team/+members
* Note page title, label, and breadcrumbs.
= Launchpad lint =
Checking for conflicts. and issues in doctests and templates.
Running jslint, xmllint, pyflakes, and pylint.
Using normal rules.
Linting changed files: registry/ stories/ foaf/xx- team-membership .txt /config/ schema- lazr.conf /launchpad/ pagetitles. py /launchpad/ database/ librarian. py registry/ browser/ team.py registry/ templates/ team-mugshots. pt registry/ templates/ team-members. pt registry/ templates/ team-map. pt registry/ browser/ person. py registry/ stories/ location/ team-map. txt development/ launchpad- lazr.conf
lib/lp/
lib/canonical
lib/canonical
lib/canonical
lib/lp/
lib/lp/
lib/lp/
lib/lp/
lib/lp/
lib/lp/
configs/
== Pylint notices ==
lib/lp/ registry/ browser/ person. py interface' (No module named restful)
119: [F0401] Unable to import 'lazr.delegates' (No module named delegates)
120: [F0401] Unable to import 'lazr.config' (No module named config)
121: [F0401] Unable to import 'lazr.restful.
--
Brad Crittenden
<email address hidden>