Docker-in-Docker (DinD) capabilities of public runners deactivated. More info

Commit 2e0c065c authored by LE GAC Renaud's avatar LE GAC Renaud
Browse files

Update Articles to improve reject message

parent bef21e0a
......@@ -598,6 +598,7 @@
'Reject preprint is a conference': 'Rejeté ce preprint est une conférence',
'Reject preprint is a published paper': 'Rejeté ce preprint est un article publié',
'Reject preprint is a thesis': 'Rejeté ce preprint est une thèse',
'Reject publication is a preprint': 'Rejeté la publication est un preprint',
'Reject publisher is unknown.': "Rejeté l'éditeur est inconnu.",
'Reject publishers is not defined': "Rejeté la revue n'est pas définie",
'Reject submission date is not well formed': "Rejeté la date de soumission n'est pas correcte",
......
......@@ -12,6 +12,7 @@ from .base import (learn_my_authors,
from plugin_dbui import get_id, UNDEF_ID
from store_tools import CheckException
MSG_IS_PREPRINT = "Reject publication is a preprint"
MSG_NO_EDITOR = "Reject article is not published"
MSG_NOT_ARTICLE = "Reject publication is not and article"
MSG_TRANSFORM_PREPRINT = "Transform the preprint into an article"
......@@ -55,8 +56,10 @@ class Articles(Automaton):
"""
self.logger.debug(f"{T4}check and fix record (article)")
if record.subtype() != "article":
self.logs[-1].reject(MSG_NOT_ARTICLE, record)
stype = record.subtype()
if stype != "article":
msg = (MSG_IS_PREPRINT if stype == "preprint" else MSG_NOT_ARTICLE)
self.logs[-1].reject(msg, record)
return False
try:
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment