diff --git a/commentaries/templates/commentaries/commentary_detail.html b/commentaries/templates/commentaries/commentary_detail.html index 80a53f4f2865bc84b0c61837cdc65ed23d9f6838..ce339e1b84442e22095daf06535aa9c9762a59cb 100644 --- a/commentaries/templates/commentaries/commentary_detail.html +++ b/commentaries/templates/commentaries/commentary_detail.html @@ -16,9 +16,6 @@ }); </script> -<script type="text/javascript" async src="https://cdn.mathjax.org/mathjax/latest/MathJax.js?config=TeX-MML-AM_CHTML"></script> -<script type="text/javascript">MathJax.Hub.Config({"tex2jax": {"inlineMath": [["$", "$"], ["\\(", "\\)"]], "processEscapes": true}});</script> - {% endblock headsup %} diff --git a/scipost/static/scipost/SciPost.css b/scipost/static/scipost/SciPost.css index 914eb04da25687b8ef708fd9a0cd6f31e89b5131..130363d3a7ef099ab3898e2a7d77bbde464c86e9 100644 --- a/scipost/static/scipost/SciPost.css +++ b/scipost/static/scipost/SciPost.css @@ -270,7 +270,7 @@ nav a:active { } nav p { display: inline-block; - margin: 0px; + margin: 10px; padding: 0px; } nav form { diff --git a/scipost/templates/scipost/base.html b/scipost/templates/scipost/base.html index c10153ebb661632e8e5e817a4d905f590557dfdd..0699a9f25539bb5a1cf527257a417e4791e0ca5e 100644 --- a/scipost/templates/scipost/base.html +++ b/scipost/templates/scipost/base.html @@ -5,6 +5,11 @@ <link rel="stylesheet" type="text/css" href="{% static 'scipost/SciPost.css' %}" /> <script src="https://code.jquery.com/jquery-2.2.0.min.js"></script> + + <script type="text/x-mathjax-config"> + MathJax.Hub.Config({tex2jax: {inlineMath: [['$','$'], ['\\(','\\)']]}}); + </script> + <script type="text/javascript" async src="https://cdn.mathjax.org/mathjax/latest/MathJax.js?config=TeX-MML-AM_CHTML"></script> <title>SciPost{% block pagetitle %}{% endblock pagetitle %}</title> diff --git a/scipost/templates/scipost/personal_page.html b/scipost/templates/scipost/personal_page.html index 7dc275c8f070459bafa4fcba2b4c04dbbde575f8..319d2d57f5da047b7d3526e3cedc39252fc88b89 100644 --- a/scipost/templates/scipost/personal_page.html +++ b/scipost/templates/scipost/personal_page.html @@ -125,4 +125,15 @@ </section> {% endif %} +{% if own_comments %} +<section> + <h1>Your Comments</h1> + <ul> + {% for own_comment in own_comments %} + <li>{{ own_comment.comment_text }}</li> + {% endfor %} + </ul> +</section> +{% endif %} + {% endblock bodysup %} diff --git a/scipost/views.py b/scipost/views.py index 2b0c94e9d6320f7e1bc50109982b5a0b6f29c8ab..b86c4af974968a4078e5493f6c7d5e5597a91fe1 100644 --- a/scipost/views.py +++ b/scipost/views.py @@ -282,7 +282,8 @@ def personal_page(request): nr_comments_to_vet = Comment.objects.filter(status=0).count() nr_author_replies_to_vet = AuthorReply.objects.filter(status=0).count() nr_reports_to_vet = Report.objects.filter(status=0).count() - context = {'contributor': contributor, 'nr_reg_to_vet': nr_reg_to_vet, 'nr_reg_awaiting_validation': nr_reg_awaiting_validation, 'nr_commentary_page_requests_to_vet': nr_commentary_page_requests_to_vet, 'nr_comments_to_vet': nr_comments_to_vet, 'nr_author_replies_to_vet': nr_author_replies_to_vet, 'nr_reports_to_vet': nr_reports_to_vet, 'nr_submissions_to_process': nr_submissions_to_process } + own_comments = Comment.objects.filter(author=contributor) + context = {'contributor': contributor, 'nr_reg_to_vet': nr_reg_to_vet, 'nr_reg_awaiting_validation': nr_reg_awaiting_validation, 'nr_commentary_page_requests_to_vet': nr_commentary_page_requests_to_vet, 'nr_comments_to_vet': nr_comments_to_vet, 'nr_author_replies_to_vet': nr_author_replies_to_vet, 'nr_reports_to_vet': nr_reports_to_vet, 'nr_submissions_to_process': nr_submissions_to_process, 'own_comments': own_comments} return render(request, 'scipost/personal_page.html', context) else: form = AuthenticationForm()