Commit 28435b2c authored by Gradl, Tobias's avatar Gradl, Tobias
Browse files

1328: Fix integrations view not loaded for result

parent 63710b2e
Pipeline #11904 failed with stages
in 7 seconds
......@@ -129,12 +129,12 @@ public class ItemController extends BaseController {
@GetMapping(value = "/data")
public @ResponseBody String getItem(@PathVariable String type, @PathVariable String itemId, @RequestParam(name="type") String dataType, Model model, Locale locale, HttpServletResponse response) throws IOException {
ExtendedDatamodelContainer datamodel = datamodelService.findById(type);
JsonNode itemSource = itemService.getItem(datamodel.getIndexName(), itemId, locale, dataType.equals("integrations"), dataType.equals("original"));
JsonNode itemSource = itemService.getItem(datamodel.getIndexName(), itemId, locale, dataType.equals(RootElementKeys.INTEGRATIONS.toString()), dataType.equals(RootElementKeys.CONTENT.toString()));
ResultElement item = itemService.renderResultElement(itemSource, datamodel.getIndexName(), itemId, locale);
if (dataType.equals("integrations")) {
if (dataType.equals(RootElementKeys.INTEGRATIONS.toString())) {
return item.getIntegrationHtml();
} else if (dataType.equals("metadata")) {
} else if (dataType.equals(RootElementKeys.META.toString())) {
return item.getMetadataHtml();
} else {
return item.getContentHtml();
Supports Markdown
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