Commit fca13ec7 authored by LE GAC Renaud's avatar LE GAC Renaud
Browse files

Propagate improved chackandfix author tools to EditAndInsert controller.

parent c385482f
......@@ -6,8 +6,7 @@ import traceback
from gluon import current
from gluon.restricted import RestrictedError
from harvest_tools import (Automaton,
build_harvester_tool,
from harvest_tools import (build_harvester_tool,
format_author_fr,
family_name_fr,
ToolException)
......@@ -124,16 +123,6 @@ def edit_insert():
values = {}
check = CheckAndFix()
# NOTE
# publication tool is only require to extract the list of my authors
tool = Automaton(db,
selector.id_teams,
selector.id_projects,
selector.controller,
selector.id_categories,
dry_run=True,
debug=False)
# title, preprint, URL, report number
values['PublicationsTitle'] = record.title()
values['PublicationsPreprint'] = record.preprint_number()
......@@ -143,11 +132,9 @@ def edit_insert():
# authors
try:
check.authors(record)
check.my_affiliation(record, selector.id_projects, selector.id_teams)
check.format_authors(record, format_author_fr)
check.my_authors(record,
reference=tool._my_author_list(record),
cmpFct=family_name_fr)
check.get_my_authors(record, cmpFct=family_name_fr)
except CheckException:
pass
......
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