diff --git a/scipost/static/scipost/assets/config/preconfig.scss b/scipost/static/scipost/assets/config/preconfig.scss index fab6e0f9c8376734b4e5028546d55ff677c6521b..e5b43ec35c21350f2adfc6ed11242801f0096bce 100644 --- a/scipost/static/scipost/assets/config/preconfig.scss +++ b/scipost/static/scipost/assets/config/preconfig.scss @@ -72,6 +72,8 @@ $font-size-h4: 0.8rem; $font-size-h5: 0.8rem; $font-size-h6: 0.8rem; +$close-font-weight: 100; + // Tables // $table-cell-padding: 0.25rem 0.5rem; diff --git a/scipost/static/scipost/assets/css/_icons.scss b/scipost/static/scipost/assets/css/_icons.scss new file mode 100644 index 0000000000000000000000000000000000000000..9f68baa05b0d0fa19482957e13d22c4a28a22dc3 --- /dev/null +++ b/scipost/static/scipost/assets/css/_icons.scss @@ -0,0 +1,18 @@ +[data-toggle="collapse"] { + + > h3:after { + background: url("data:image/svg+xml;base64,PHN2ZyBmaWxsPSIjMDAwMDAwIiB2aWV3Qm94PSIwIDAgMjQgMjQiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyI+CiAgICA8cGF0aCBkPSJNNy40MSA3Ljg0TDEyIDEyLjQybDQuNTktNC41OEwxOCA5LjI1bC02IDYtNi02eiIvPgogICAgPHBhdGggZD0iTTAtLjc1aDI0djI0SDB6IiBmaWxsPSJub25lIi8+Cjwvc3ZnPg=="); + content: ''; + display: inline-block; + height: 16px; + width: 16px; + vertical-align: baseline; + float: right; + } + + &.collapsed > h3:after { + -ms-transform: rotate(180deg); /* IE 9 */ + -webkit-transform: rotate(180deg); /* Chrome, Safari, Opera */ + transform: rotate(180deg); + } +} diff --git a/submissions/templates/submissions/_arxiv_queryresult.html b/submissions/templates/submissions/_arxiv_queryresult.html new file mode 100644 index 0000000000000000000000000000000000000000..6d27ad83fbb256515ca15721c543eb0f860e2fd0 --- /dev/null +++ b/submissions/templates/submissions/_arxiv_queryresult.html @@ -0,0 +1,10 @@ +<div class="card-block"> + <h3 class="card-title">{{ item.title }}</h3> + <div class="card-text"> + {% for author in item.authors %} + {{ author.name }}{% if not forloop.last %},{% endif %} + {% endfor %} + - <a href="{{ item.id }}" target="_blank">{{ item.id }}</a> + </div> + <p class="card-text text-muted">Published: {{ item.published }}</p> +</div> diff --git a/submissions/templates/submissions/_pool_base.html b/submissions/templates/submissions/_pool_base.html new file mode 100644 index 0000000000000000000000000000000000000000..a60e5b5b1129a08d124e3bc4a5c52d9719eee89f --- /dev/null +++ b/submissions/templates/submissions/_pool_base.html @@ -0,0 +1,11 @@ +{% extends 'scipost/base.html' %} + +{% block breadcrumb %} + <nav class="breadcrumb py-md-2 px-0"> + <div class="container"> + {% block breadcrumb_items %} + <a href="{% url 'scipost:personal_page' %}" class="breadcrumb-item">Personal Page</a> + {% endblock %} + </div> + </nav> +{% endblock %} diff --git a/submissions/templates/submissions/pool.html b/submissions/templates/submissions/pool.html index 537cdffcae1ed8f9c50be9d86237f2baeb54a625..5720d0204c39116553ef9afb5475e53990b3901e 100644 --- a/submissions/templates/submissions/pool.html +++ b/submissions/templates/submissions/pool.html @@ -37,12 +37,12 @@ </div> </div> - {% for rec in recommendations_undergoing_voting %} - {% if not forloop.first %} - <hr> - {% endif %} + <div class="row"> + {% for rec in recommendations_undergoing_voting %} + {% if not forloop.first %} + <hr> + {% endif %} - <div class="row"> <div class="col-12"> <div class="card card-outline-secondary"> {% include 'submissions/_submission_card_fellow_content.html' with submission=rec.submission %} @@ -257,44 +257,46 @@ </ul> </div><!-- end status --> - {% if recommendations_undergoing_voting %} - <!-- Preparing --> - <a href="#rec_filter_voting" data-toggle="collapse" class="collapsed"> - <h3 class="card-title text-gray-dark">Recommendations undergoing voting ({{recommendations_to_prepare_for_voting|length}})</h3> - </a> - <div id="rec_filter_voting" class="collapse"> - <ul class="list-group list-group-flush"> - {% for recommendation in recommendations_undergoing_voting %} - <li class="list-group-item"> - <div class="card-block"> - <a href="#prepare_rec_{{recommendation.id}}">{{recommendation.submission.title}}</a> - <p class="text-muted my-0">{{recommendation.submission.author_list}}</p> - <p class="my-0">Formulated on {{recommendation.date_submitted}}</p> - </div> - </li> - {% endfor %} - </ul> - </div><!-- end preparing --> - {% endif %} + {% if is_ECAdmin %} + {% if recommendations_undergoing_voting %} + <!-- Preparing --> + <a href="#rec_filter_voting" data-toggle="collapse" class="collapsed"> + <h3 class="card-title text-gray-dark">Recommendations undergoing voting ({{recommendations_undergoing_voting|length}})</h3> + </a> + <div id="rec_filter_voting" class="collapse"> + <ul class="list-group list-group-flush"> + {% for recommendation in recommendations_undergoing_voting %} + <li class="list-group-item"> + <div class="card-block"> + <a href="#prepare_rec_{{recommendation.id}}">{{recommendation.submission.title}}</a> + <p class="text-muted my-0">{{recommendation.submission.author_list}}</p> + <p class="my-0">Formulated on {{recommendation.date_submitted}}</p> + </div> + </li> + {% endfor %} + </ul> + </div><!-- end preparing --> + {% endif %} - {% if recommendations_to_prepare_for_voting %} - <!-- Preparing --> - <a href="#rec_filter_prepare" data-toggle="collapse" class="collapsed"> - <h3 class="card-title text-gray-dark">Recommendations to prepare ({{recommendations_to_prepare_for_voting|length}})</h3> - </a> - <div id="rec_filter_prepare" class="collapse"> - <ul class="list-group list-group-flush"> - {% for recommendation in recommendations_to_prepare_for_voting %} - <li class="list-group-item"> - <div class="card-block"> - <a href="#prepare_rec_{{recommendation.id}}">{{recommendation.submission.title}}</a> - <p class="text-muted my-0">{{recommendation.submission.author_list}}</p> - <p class="my-0">Formulated on {{recommendation.date_submitted}}</p> - </div> - </li> - {% endfor %} - </ul> - </div><!-- end preparing --> + {% if recommendations_to_prepare_for_voting %} + <!-- Preparing --> + <a href="#rec_filter_prepare" data-toggle="collapse" class="collapsed"> + <h3 class="card-title text-gray-dark">Recommendations to prepare ({{recommendations_to_prepare_for_voting|length}})</h3> + </a> + <div id="rec_filter_prepare" class="collapse"> + <ul class="list-group list-group-flush"> + {% for recommendation in recommendations_to_prepare_for_voting %} + <li class="list-group-item"> + <div class="card-block"> + <a href="#prepare_rec_{{recommendation.id}}">{{recommendation.submission.title}}</a> + <p class="text-muted my-0">{{recommendation.submission.author_list}}</p> + <p class="my-0">Formulated on {{recommendation.date_submitted}}</p> + </div> + </li> + {% endfor %} + </ul> + </div><!-- end preparing --> + {% endif %} {% endif %} <!-- Pool --> diff --git a/submissions/templates/submissions/prepare_for_voting.html b/submissions/templates/submissions/prepare_for_voting.html index def94b0e4949850f24b5bd6499d01ed8d43db0a9..cf1e8af3936202f0377943aaaac21ab9f6db4ce9 100644 --- a/submissions/templates/submissions/prepare_for_voting.html +++ b/submissions/templates/submissions/prepare_for_voting.html @@ -14,7 +14,6 @@ {% block content %} - <div class="row"> <div class="col-12"> <div class="card card-grey"> diff --git a/submissions/views.py b/submissions/views.py index 1c82f1e7281768999ae32cec52832213649458e3..2e28d88ef2d30f64a3c7f2df08b0f5f1ad0139be 100644 --- a/submissions/views.py +++ b/submissions/views.py @@ -1,6 +1,7 @@ import datetime import feedparser +from django.contrib import messages from django.contrib.auth.decorators import login_required, permission_required from django.contrib.auth.models import Group from django.core.exceptions import PermissionDenied @@ -1174,8 +1175,9 @@ def prepare_for_voting(request, rec_id): recommendation.save() recommendation.submission.status = 'put_to_EC_voting' recommendation.submission.save() - return render(request, 'scipost/acknowledgement.html', - context={'ack_message': 'We have registered your selection.'}) + messages.success(request, 'We have registered your selection.') + return redirect(reverse('submissions:editorial_page', + args=[recommendation.submission.arxiv_identifier_w_vn_nr])) else: # Identify possible co-authorships in last 3 years, disqualifying Fellow from voting: if recommendation.submission.metadata is not None: