diff --git a/SciPost_v1/settings/local_JSC.py b/SciPost_v1/settings/local_JSC.py new file mode 100644 index 0000000000000000000000000000000000000000..f4dcbe1891cd9a9b8ba42739749f2528e168a2f0 --- /dev/null +++ b/SciPost_v1/settings/local_JSC.py @@ -0,0 +1,13 @@ +from .base import * + +# THE MAIN THING HERE +DEBUG = True + +# Static and media +STATIC_ROOT = '/Users/jscaux/Sites/SciPost.org/scipost_v1/local_files/static/' +MEDIA_ROOT = '/Users/jscaux/Sites/SciPost.org/scipost_v1/local_files/media/' +WEBPACK_LOADER['DEFAULT']['BUNDLE_DIR_NAME'] =\ + '/Users/jscaux/Sites/SciPost.org/scipost_v1/local_files/static/bundles/' + +MAILCHIMP_API_USER = get_secret("MAILCHIMP_API_USER") +MAILCHIMP_API_KEY = get_secret("MAILCHIMP_API_KEY") diff --git a/production/constants.py b/production/constants.py index 63d9f65fef9e6df30ea6af26cb5767a5fa46bec8..0a0b7ec8a445d3f04da78430cf52f28a55930147 100644 --- a/production/constants.py +++ b/production/constants.py @@ -12,6 +12,7 @@ PRODUCTION_EVENTS = ( ('message_supervisor_to_officer', 'Message from Supervisor to Officer'), ('message_officer_to_supervisor', 'Message from Officer to Supervisor'), ('proofs_produced', 'Proofs have been produced'), + ('proofs_checked_by_supervisor', 'Proofs have been checked by Supervisor'), ('proofs_sent_to_authors', 'Proofs sent to Authors'), ('proofs_returned_by_authors', 'Proofs returned by Authors'), ('corrections_implemented', 'Corrections implemented'), diff --git a/production/migrations/0003_auto_20170522_1021.py b/production/migrations/0003_auto_20170522_1021.py new file mode 100644 index 0000000000000000000000000000000000000000..b3ad736e99a30f24eb8fd4ace5dc7e96499d1b3d --- /dev/null +++ b/production/migrations/0003_auto_20170522_1021.py @@ -0,0 +1,20 @@ +# -*- coding: utf-8 -*- +# Generated by Django 1.10.3 on 2017-05-22 08:21 +from __future__ import unicode_literals + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('production', '0002_auto_20170517_1942'), + ] + + operations = [ + migrations.AlterField( + model_name='productionevent', + name='event', + field=models.CharField(choices=[('assigned_to_supervisor', 'Assigned by EdAdmin to Supervisor'), ('message_edadmin_to_supervisor', 'Message from EdAdmin to Supervisor'), ('message_supervisor_to_edadmin', 'Message from Supervisor to EdAdmin'), ('officer_tasked_with_proof_production', 'Supervisor tasked officer with proofs production'), ('message_supervisor_to_officer', 'Message from Supervisor to Officer'), ('message_officer_to_supervisor', 'Message from Officer to Supervisor'), ('proofs_produced', 'Proofs have been produced'), ('proofs_checked_by_supervisor', 'Proofs have been checked by Supervisor'), ('proofs_sent_to_authors', 'Proofs sent to Authors'), ('proofs_returned_by_authors', 'Proofs returned by Authors'), ('corrections_implemented', 'Corrections implemented'), ('authors_have_accepted_proofs', 'Authors have accepted proofs')], max_length=64), + ), + ] diff --git a/scipost/services.py b/scipost/services.py index d9a03b5295223b71908cc8d7e97d0753f89ddc1a..7a6707e8f7b84fab44f80726a0046724ed38bd23 100644 --- a/scipost/services.py +++ b/scipost/services.py @@ -51,7 +51,8 @@ class DOICaller: # For Physical Review pages = data.get('article-number', '') # For other journals? - pages = data.get('page', '') + if not pages: + pages = data.get('page', '') return pages def _get_pub_date(self, data): diff --git a/submissions/constants.py b/submissions/constants.py index 845ecbb2ebd49f4117139978bbc36cd0d1b2fc86..84638110f30c4a2829a9f8a29c125b2a57baf46c 100644 --- a/submissions/constants.py +++ b/submissions/constants.py @@ -62,6 +62,7 @@ SUBMISSION_STATUS_PUBLICLY_INVISIBLE = [ STATUS_RESUBMISSION_INCOMING, 'assignment_failed', 'resubmitted_rejected', + STATUS_RESUBMITTED_REJECTED, 'rejected', 'withdrawn', ] @@ -70,6 +71,7 @@ SUBMISSION_STATUS_PUBLICLY_INVISIBLE = [ SUBMISSION_STATUS_PUBLICLY_UNLISTED = SUBMISSION_STATUS_PUBLICLY_INVISIBLE + [ 'resubmitted', 'resubmitted_rejected_visible', + STATUS_RESUBMITTED_REJECTED_VISIBLE, 'published' ] diff --git a/submissions/views.py b/submissions/views.py index 446ac11166250c58ebdc6af6f4896eb69cd179bb..56fc14ca6c9a17d72555f191f449c9b4eea76942 100644 --- a/submissions/views.py +++ b/submissions/views.py @@ -924,13 +924,13 @@ def communication(request, arxiv_identifier_w_vn_nr, comtype, referee_id=None): (Submission, 'arxiv_identifier_w_vn_nr', 'arxiv_identifier_w_vn_nr')) @transaction.atomic def eic_recommendation(request, arxiv_identifier_w_vn_nr): - submission = get_object_or_404(Submission.objects.get_pool(request.user), + submission = get_object_or_404(Submission.objects.filter_editorial_page(request.user), arxiv_identifier_w_vn_nr=arxiv_identifier_w_vn_nr) if submission.eic_recommendation_required(): messages.warning(request, ('<h3>An Editorial Recommendation is not required</h3>' 'This submission\'s current status is: <em>%s</em>' % submission.get_status_display())) - return redirect(reverse('scipost:editorial_page', + return redirect(reverse('submissions:editorial_page', args=[submission.arxiv_identifier_w_vn_nr])) form = EICRecommendationForm(request.POST or None)