Merge lp:~daker/loco-team-portal/fix.657310 into lp:loco-team-portal

Proposed by Adnane Belmadiaf
Status: Merged
Merged at revision: 309
Proposed branch: lp:~daker/loco-team-portal/fix.657310
Merge into: lp:loco-team-portal
Diff against target: 73 lines (+13/-13)
1 file modified
loco_directory/templates/teams/team_detail.html (+13/-13)
To merge this branch: bzr merge lp:~daker/loco-team-portal/fix.657310
Reviewer Review Type Date Requested Status
Daniel Holbach (community) Approve
Review via email: mp+38047@code.launchpad.net
To post a comment you must log in.
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/templates/teams/team_detail.html'
2--- loco_directory/templates/teams/team_detail.html 2010-10-07 12:18:15 +0000
3+++ loco_directory/templates/teams/team_detail.html 2010-10-09 14:23:44 +0000
4@@ -14,22 +14,17 @@
5 {% block search %}{% endblock %}
6
7 {% block extrahead %}{{ block.super }}
8-{% if team.flickr_id %}
9+{% if team.flickr_id or team.picasa_id or team.pixie_id %}
10 <script type="text/javascript" src="{{MEDIA_URL}}jquery/jquery.js"></script>
11 <script type="text/javascript" src="{{MEDIA_URL}}js/jquery.lightbox-0.5.min.js"></script>
12-<link rel="stylesheet" href="{{MEDIA_URL}}css/jquery.lightbox-0.5.css" type="text/css" media="screen" />
13+<link rel="stylesheet" href="{{MEDIA_URL}}css/jquery.lightbox-0.5.css" type="text/css" media="screen" />
14 <script type="text/javascript">
15-
16-
17-
18 $(function() {
19 var apiKey = '{{ flickr_api_key }}';
20 var perPage = '27';
21+{% endif %}
22+{% if team.flickr_id %}
23 var flickr_userId = '{{ team.flickr_id }}';
24- var picasa_userId = '{{ team.picasa_id }}';
25- var pixie_userId = '{{ team.pixie_id }}';
26-
27-
28 $.getJSON('http://api.flickr.com/services/rest/?format=json&method='+
29 'flickr.photos.search&api_key=' + apiKey + '&user_id=' + flickr_userId +
30 '&per_page=' + perPage + '&jsoncallback=?',
31@@ -51,6 +46,9 @@
32 });
33 $("a.lightbox").lightBox();
34 });
35+{% endif %}
36+{% if team.picasa_id %}
37+ var picasa_userId = '{{ team.picasa_id }}';
38 $.getJSON('http://picasaweb.google.com/data/feed/base/user/'+ picasa_userId +'?alt=json&kind=photo'+
39 '&access=public&thumbsize=72&max-results=' + perPage + '&hl=en_US&callback=?',
40 function(data) {
41@@ -69,7 +67,9 @@
42 });
43 $("a.lightbox").lightBox();
44 });
45-
46+{% endif %}
47+{% if team.pixie_id %}
48+ var pixie_userId = '{{ team.pixie_id }}';
49 $.getJSON('http://api.pix.ie/v0.81/account/'+ pixie_userId +'/photos.json?oauth_consumer_key=1dcc8233-a6da-46b0-acb0-4e29aa612b30&page=1&perpage=' + perPage
50 + '&sortby=recent&extras=items_item_owner,items_item_Description,items_item_sizes_all&jsonp=?',
51 function(data){
52@@ -84,10 +84,10 @@
53 });
54 $("a.lightbox").lightBox();
55 });
56+{% endif %}
57+{% if team.flickr_id or team.picasa_id or team.pixie_id %}
58 });
59
60-
61-
62 </script>
63 <style type="text/css">
64 div#flickr a.lightbox img {
65@@ -226,7 +226,7 @@
66 <img id="locobranding" src="{{ team.mugshot_url }}" alt="" title="{{ team.name }}" />
67 </article>
68
69-{% if team.flickr_id %}
70+{% if team.flickr_id or team.picasa_id or team.pixie_id %}
71 <article class="minor-content alone" style="width:95%;">
72 <h2>{% trans "Photos from" %} {{ team.name }}</h2>
73 <div style="width:100%;" id="flickr"> </div>

Subscribers

People subscribed via source and target branches