diff --git a/Resources/public/js/recommendationrestclient.js b/Resources/public/js/recommendationrestclient.js index 0d37bce..79e508f 100644 --- a/Resources/public/js/recommendationrestclient.js +++ b/Resources/public/js/recommendationrestclient.js @@ -20,7 +20,7 @@ this.language = config.language || ''; this.fields = config.fields || []; this.contentType = config.contentType || ''; - this.outputTypeId = config.outputTypeId || ''; + this.outputType = config.outputType || ''; this.contextItems = config.contextItems || ''; this.categoryPath = config.categoryPath || ''; this.errorMessage = config.errorMessage || 'Error occurred while loading recommendations'; @@ -70,7 +70,7 @@ '.json?numrecs=', this.limit, '&contextitems=', this.contextItems, '&contenttype=', this.contentType, - '&outputtypeid=', this.outputTypeId, + '&outputtype=', this.outputType, '&categorypath=', encodeURIComponent(this.categoryPath), '&lang=', this.language, attributes diff --git a/Resources/public/views/show_recommendations.html.twig b/Resources/public/views/show_recommendations.html.twig index 36bf8a7..f672e5c 100644 --- a/Resources/public/views/show_recommendations.html.twig +++ b/Resources/public/views/show_recommendations.html.twig @@ -12,7 +12,7 @@ endpointUrl: '{{ endpointUrl }}', language: '{{ language }}', contentType: '{{ contentType }}', - outputTypeId: '{{ outputTypeId }}', + outputType: '{{ outputType }}', contextItems: '{{ contentId }}', categoryPath: '{{ categoryPath }}', fields: [{% for entry in fields %}'{{ entry }}', {% endfor %}], diff --git a/Twig/RecommendationTwigExtension.php b/Twig/RecommendationTwigExtension.php index 0539ce1..7a1cf0a 100644 --- a/Twig/RecommendationTwigExtension.php +++ b/Twig/RecommendationTwigExtension.php @@ -240,7 +240,7 @@ public function showRecommendations( 'endpointUrl' => $this->getEndPointUrl(), 'feedbackUrl' => $this->getFeedbackUrl($this->getContentTypeId($contentType)), 'contentType' => $this->getContentTypeId($this->getContentIdentifier($contentId)), - 'outputTypeId' => $this->getContentTypeId($contentType), + 'outputType' => $this->getContentTypeId($contentType), 'categoryPath' => $this->getLocationPathString($contentId) ) );