1
|
/**
|
2
|
* Copyright (C) 2020 EDIT
|
3
|
* European Distributed Institute of Taxonomy
|
4
|
* http://www.e-taxonomy.eu
|
5
|
*
|
6
|
* The contents of this file are subject to the Mozilla Public License Version 1.1
|
7
|
* See LICENSE.TXT at the top of this package for the full license terms.
|
8
|
*/
|
9
|
package eu.etaxonomy.cdm.remote.controller;
|
10
|
|
11
|
import java.util.Arrays;
|
12
|
import java.util.List;
|
13
|
|
14
|
import org.springframework.beans.factory.annotation.Autowired;
|
15
|
import org.springframework.stereotype.Controller;
|
16
|
import org.springframework.web.bind.annotation.RequestMapping;
|
17
|
|
18
|
import eu.etaxonomy.cdm.api.service.IPolytomousKeyNodeService;
|
19
|
import io.swagger.annotations.Api;
|
20
|
|
21
|
/**
|
22
|
* @author a.kohlbecker
|
23
|
* @since Sep 9, 2020
|
24
|
*/
|
25
|
@Controller
|
26
|
@Api(value="portal_polytomousKeyNode")
|
27
|
@RequestMapping(value = {"/portal/polytomousKeyNode/{uuid}"})
|
28
|
public class PolytomousKeyNodePortalController extends PolytomousKeyNodeController {
|
29
|
|
30
|
private static final List<String> NODE_INIT_STRATEGY = Arrays.asList(new String[]{
|
31
|
"$",
|
32
|
"question.label",
|
33
|
"statement.label",
|
34
|
"children.statement.label",
|
35
|
"children.subkey",
|
36
|
"otherNode",
|
37
|
"taxon.name.nomenclaturalSource.citation.authorship",
|
38
|
"taxon.name.nomenclaturalSource.citation.inReference.authorship",
|
39
|
"subkey.$"
|
40
|
});
|
41
|
|
42
|
public PolytomousKeyNodePortalController() {
|
43
|
super();
|
44
|
setInitializationStrategy(NODE_INIT_STRATEGY);
|
45
|
}
|
46
|
|
47
|
@Override
|
48
|
@Autowired
|
49
|
public void setService(IPolytomousKeyNodeService service) {
|
50
|
this.service = service;
|
51
|
}
|
52
|
|
53
|
|
54
|
}
|