minors
This commit is contained in:
parent
066e0ca73c
commit
3aa5acd740
|
@ -3,6 +3,7 @@ package eu.dnetlib.is;
|
|||
import java.util.Optional;
|
||||
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.beans.factory.annotation.Value;
|
||||
import org.springframework.http.MediaType;
|
||||
import org.springframework.stereotype.Controller;
|
||||
import org.springframework.ui.ModelMap;
|
||||
|
@ -30,6 +31,9 @@ public class MainController {
|
|||
@Autowired
|
||||
private ResourceTypeRepository resourceTypeRepository;
|
||||
|
||||
@Value("${logging.file.name:not specified}")
|
||||
private String logFile;
|
||||
|
||||
@GetMapping("/main")
|
||||
public void mainPage() {}
|
||||
|
||||
|
@ -78,7 +82,7 @@ public class MainController {
|
|||
}
|
||||
|
||||
@GetMapping("/info")
|
||||
public void wfHistory(final ModelMap map) throws Exception {}
|
||||
public void wfHistory() throws Exception {}
|
||||
|
||||
@ModelAttribute("resTypes")
|
||||
public Iterable<ResourceType> resourceTypes() {
|
||||
|
|
|
@ -30,9 +30,11 @@ import org.springframework.web.bind.annotation.GetMapping;
|
|||
import org.springframework.web.bind.annotation.RequestMapping;
|
||||
import org.springframework.web.bind.annotation.RestController;
|
||||
|
||||
import eu.dnetlib.common.controller.AbstractDnetController;
|
||||
|
||||
@RestController
|
||||
@RequestMapping("/api/info")
|
||||
public class InfoRestController {
|
||||
public class InfoRestController extends AbstractDnetController {
|
||||
|
||||
@Autowired
|
||||
private ConfigurableEnvironment configurableEnvironment;
|
||||
|
|
|
@ -57,7 +57,6 @@
|
|||
|
||||
app.controller('infoController', function($scope, $http) {
|
||||
$scope.info = [];
|
||||
$scope.modules = {};
|
||||
|
||||
$http.get('./api/info/?' + $.now()).then(function successCallback(res) {
|
||||
angular.forEach(res.data, function(section) {
|
||||
|
@ -71,7 +70,7 @@
|
|||
});
|
||||
$scope.info = res.data;
|
||||
}, function errorCallback(res) {
|
||||
alert('ERROR: ' + res.data.message);
|
||||
alert('ERROR: ' + res.data.message);
|
||||
});
|
||||
});
|
||||
</script>
|
||||
|
|
Loading…
Reference in New Issue