Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix error on bookmark deletion #558

Merged
merged 1 commit into from
Sep 8, 2017
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion website/models.py
Original file line number Diff line number Diff line change
Expand Up @@ -300,7 +300,7 @@ class UserProfile(models.Model):
user_avatar = models.ImageField(upload_to=user_images_path, blank=True, null=True)
title = models.IntegerField(choices=title, default=0)
winnings = models.DecimalField(max_digits=10, decimal_places=2, null=True, blank=True)
issue_upvoted = models.ManyToManyField(Issue, null=True, blank=True, related_name="upvoted")
issue_upvoted = models.ManyToManyField(Issue, blank=True, related_name="upvoted")
issue_saved = models.ManyToManyField(Issue, blank=True, related_name="saved")

def avatar(self, size=36):
Expand Down
20 changes: 15 additions & 5 deletions website/templates/profile.html
Original file line number Diff line number Diff line change
Expand Up @@ -73,8 +73,8 @@
display: none;
width: 200px;
}
.general{
color:white;
.fa-cogs {
color: white;
}
.fa-exclamation-triangle {
color: #ff4444;
Expand Down Expand Up @@ -115,6 +115,10 @@
margin-right: 30px;
margin-top: 10px;
}
.icon-block kbd a {
color: inherit;
text-decoration: none;
}
{% endblock %}

{% block content %}
Expand Down Expand Up @@ -144,7 +148,7 @@ <h1 class="page-header text-capitalize">{{ user.username }}</h1>
{% include 'followers.html' %}
</div>
<div class="icon-block">
<kbd class="fa general">
<kbd class="fa fa-cogs">
<a href="/label_activity?user={{ user.username }}&label=General">General {{ bug_type_0 | length }}</a>
</kbd>
<kbd class="fa fa-exclamation-triangle">
Expand Down Expand Up @@ -214,8 +218,12 @@ <h1 class="page-header text-capitalize">{{ user.username }}</h1>
<div class="icon-block">
<kbd class="fa fa-trophy"> Bugs Reported {{ total_bugs }}</kbd>
<kbd class="fa fa-star"> Points {{ my_score|default:0 }}</kbd>
<a href="/label_activity?user={{ user.username }}&label=open"><kbd class="fa fa-bug"> Open Issues {{total_open}}</kbd></a>
<a href="/label_activity?user={{ user.username }}&label=closed"><kbd class="fa fa-code-fork"> Closed Issues {{total_closed}}</kbd></a>
<a href="/label_activity?user={{ user.username }}&label=open">
<kbd class="fa fa-bug"> Open Issues {{total_open}}</kbd>
</a>
<a href="/label_activity?user={{ user.username }}&label=closed">
<kbd class="fa fa-code-fork"> Closed Issues {{total_closed}}</kbd>
</a>
</div>
</div>
</div>
Expand Down Expand Up @@ -286,6 +294,7 @@ <h1 class="page-header text-capitalize">{{ user.username }}</h1>
});
});

{% if activities %}
var all_months = ["Jan", "Feb", "Mar", "Apr", "May", "June", "July", "Aug", "Sept", "Oct", "Nov", "Dec"];
var months = [], data = [];
var all_data = new Array(12).fill(0);
Expand Down Expand Up @@ -351,6 +360,7 @@ <h1 class="page-header text-capitalize">{{ user.username }}</h1>
}
}
});
{% endif %}

$('body').on('click', '.follow_unfollow', function (e){
e.preventDefault();
Expand Down