Skip to content

Commit

Permalink
Interests added to RSSViewer + Admin Dashboard
Browse files Browse the repository at this point in the history
  • Loading branch information
DEKHTIARJonathan committed Aug 14, 2017
1 parent 4eada9b commit 8611597
Show file tree
Hide file tree
Showing 3 changed files with 25 additions and 26 deletions.
3 changes: 2 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -112,4 +112,5 @@ FeedCrunch.IO.zip
boto-develop/build/
application/fixtures/feedcrunch_dump8.json
application/fixtures/feedcrunch_dump9.json
media/images/interest_photos/
media/images/interest_photos/
scripts/django_q.sql
14 changes: 5 additions & 9 deletions feedcrunch_rssadmin/templates/admin/admin_dashboard.html
Original file line number Diff line number Diff line change
Expand Up @@ -18,15 +18,11 @@
<h4 class="card-title grey-text text-darken-4">{{ user.get_full_name }}</h4>
<p class="medium-small grey-text">@{{ user.username }}</p>
</div>
{% for interest in user.interests.all %}
<div class="col s2 center-align">
<h4 class="card-title grey-text text-darken-4 title-interest">Data Science</h4>
</div>
<div class="col s2 center-align">
<h4 class="card-title grey-text text-darken-4 title-interest">Machine Learning</h4>
</div>
<div class="col s2 center-align">
<h4 class="card-title grey-text text-darken-4 title-interest">Computer Vision</h4>
<h4 class="card-title grey-text text-darken-4 title-interest">{{ interest }}</h4>
</div>
{% endfor %}
</div>
</div>
</div>
Expand All @@ -37,7 +33,7 @@ <h4 class="card-title grey-text text-darken-4 title-interest">Computer Vision</h
<div class="card stats-card">
<div class="card-content KPI-Card">
<span class="card-title">Articles Posted</span>
<span class="stats-counter"><span class="counter">{{ user.get_post_count }}</span><small>Article(s) posted since {{ user.date_joined }}</small></span>
<span class="stats-counter"><span class="counter">{{ user.get_post_count }}</span><small>Article(s) posted since {{ user.date_joined|date:"F Y" }}</small></span>
</div>
<div class="progress stats-card-progress no-progress"></div>
</div>
Expand All @@ -62,7 +58,7 @@ <h4 class="card-title grey-text text-darken-4 title-interest">Computer Vision</h
<div class="card stats-card">
<div class="card-content KPI-Card">
<span class="card-title">Clicks on all Articles</span>
<span class="stats-counter"><span class="counter">{{ user.get_clicks_count_on_user_posts }}</span><small>Clicks since {{ user.date_joined }}</small></span>
<span class="stats-counter"><span class="counter">{{ user.get_clicks_count_on_user_posts }}</span><small>Click(s) since {{ user.date_joined|date:"F Y" }}</small></span>
</div>
<div class="progress stats-card-progress no-progress"></div>
</div>
Expand Down
34 changes: 18 additions & 16 deletions feedcrunch_rssviewer/templates/rssviewer.html
Original file line number Diff line number Diff line change
Expand Up @@ -4,22 +4,24 @@
{% block body %}

<div class="container user_desc">
<div class="label label--smaller u-inlineBlock js-followeesWhoFollow" style="padding-left: 0px;">
<span style="color: #525252;">
Categories:
</span>
<a class="link u-baseColor--link" href="/category/datascience">
Data Science
</a>
,&nbsp;
<a class="link u-baseColor--link" href="/category/machinelearning">
Machine Learning
</a>
and&nbsp;
<a class="link u-baseColor--link" href="/category/computervision">
Computer Vision
</a>
</div>
{% if requested_user.interests.count != 0 %}
<div class="label label--smaller u-inlineBlock js-followeesWhoFollow" style="padding-left: 0px;">
<span style="color: #525252;">
Interests:
</span>

{% for interest in requested_user.interests.all %}
<a class="link u-baseColor--link" href="#">
{{ interest }}
</a>
{% if forloop.counter0 == 0 %}
,&nbsp;
{% elif forloop.counter0 == 1 %}
and&nbsp;
{% endif %}
{% endfor %}
</div>
{% endif %}
<header class="hero hero--profile">
<div class="hero-avatar u-floatRight js-profileAvatar">
<div class="avatar">
Expand Down

0 comments on commit 8611597

Please sign in to comment.