Merge lp:~wallyworld/launchpad/sharee-display-details-1002954 into lp:launchpad
Status: | Merged | ||||
---|---|---|---|---|---|
Approved by: | William Grant | ||||
Approved revision: | no longer in the source branch. | ||||
Merged at revision: | 15333 | ||||
Proposed branch: | lp:~wallyworld/launchpad/sharee-display-details-1002954 | ||||
Merge into: | lp:launchpad | ||||
Diff against target: | 0 lines | ||||
To merge this branch: | bzr merge lp:~wallyworld/launchpad/sharee-display-details-1002954 | ||||
Related bugs: |
|
Reviewer | Review Type | Date Requested | Status |
---|---|---|---|
William Grant | code | Approve | |
Review via email: mp+107912@code.launchpad.net |
Commit message
Display team icon and launchpad name of grantee in sharing table.
Description of the change
== Implementation ==
Add the icon url to the json data sent when the client asks for grantee data to display.
Update the mustache template used to render the grantee row.
The table now shows the icon (if there is one) plus the Luanchpad id of the grantee.
== Demo and QA ==
http://
== Tests ==
Update shareetable yui test.
Update sharing service jsonData tests.
Add 1 to view query count tests since there is a new query to cache the icon info.
== Lint ==
Checking for conflicts and issues in changed files.
Linting changed files:
lib/lp/
lib/lp/
lib/lp/
lib/lp/
lib/lp/
137 + grantee_ids = [grantee[0].id for grantee in grant_permissions]
This is not an entirely insignificant change: it causes grant_permissions to be iterated before the main loop. It looks like all callsites currently pass in a list, but if it happens to be a ResultSet then the pre-consumption will cause jsonShareeData to return an empty list. Hopefully not a concern here, though.
148 + image_url = display_ api.custom_ icon_url( ) or ''
I think it feels slightly nicer to use None instead of ''. I'd also consider s/image/icon/.
149 + sprite_css = display_ api.sprite_ css() or 'sprite bullet'
Can sprite_css for a person or team ever return something that evaluates to false? This seems like over-nice handling of a case that should at best crash.