Skip to content

Commit

Permalink
Improved defaults and wizard experience for Algolia endpoints (#987)
Browse files Browse the repository at this point in the history
  • Loading branch information
chuckmeyer authored Mar 27, 2024
1 parent 577aa70 commit 7e18be0
Show file tree
Hide file tree
Showing 6 changed files with 10 additions and 8 deletions.
Binary file removed app/assets/images/algolia-icon.png
Binary file not shown.
Binary file added app/assets/images/algolia.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
10 changes: 5 additions & 5 deletions app/assets/javascripts/services/settingsSvc.js
Original file line number Diff line number Diff line change
Expand Up @@ -155,16 +155,16 @@ angular.module('QuepidApp')
headerType: 'Custom',
customHeaders: [
'{',
' "x-algolia-application-id": "YOUR_ALGOLIA_APPLICATION_ID",',
' "x-algolia-api-key": "YOUR_ALGOLIA_API_KEY"',
' "x-algolia-application-id": "OKF83BFQS4",',
' "x-algolia-api-key": "2ee1381ed11d3fe70b60605b1e2cd3f4"',
'}'
].join('\n'),
idField: 'objectID',
titleField: 'name',
additionalFields: [],
titleField: 'title',
additionalFields: ['overview', 'cast', 'thumb:poster_path'],
numberOfRows: 10,
searchEngine: 'algolia',
searchUrl: 'https://78J6LMFN9N-dsn.algolia.net/1/indexes/dev_quepid/query',
searchUrl: 'https://OKF83BFQS4-dsn.algolia.net/1/indexes/movies_demo_quepid/query',
urlFormat: 'https://<APPLICATION-ID>-dsn.algolia.net/1/indexes/<index>/query',
proxyRequests: true,
basicAuthCredential: ''
Expand Down
6 changes: 4 additions & 2 deletions app/assets/javascripts/tour.js
Original file line number Diff line number Diff line change
Expand Up @@ -110,13 +110,15 @@ this.setupTour = function() {

tour.addStep('tune', {
title: 'Tune Relevance',
text: `This is where all the magic happens!<br />If you are not familiar with how this work, read the <a href="http://quepid.com/docs/#tuning" target="_blank" title="Knowledge Base">Tuning Relevance</a> section in the Knowledge Base.<br />TL;DR: always make sure this <code>#$query##</code> exists somewhere.<br />Let\s make change this up and see what happens.<br />If you are using Solr, change the query sandbox to: <code>q=#$query##&defType=edismax&qf=title overview</code><br />or to <code>{ \
text: `This is where all the magic happens!<br />If you are not familiar with how this work, read the <a href="http://quepid.com/docs/#tuning" target="_blank" title="Knowledge Base">Tuning Relevance</a> section in the Knowledge Base.<br />TL;DR: always make sure this <code>#$query##</code> exists somewhere.<br />Let\s make change this up and see what happens.<br />If you are using Solr, change the query sandbox to: <code>q=#$query##&defType=edismax&qf=title overview</code><br />, to <code>{ \
"query": { \
"match": { \
"title": "#$query##" \
} \
} \
}</code> if you are using Elasticsearch<br />(adjust appropriately if you are not using the demo case).`,
}</code> if you are using Elasticsearch,<br /> or add <code>"restrictSearchableAttributes": [ \
"title" \
]</code> for Algolia, (adjust appropriately if you are not using the demo case).`,
attachTo: '.pane_east left',
advanceOn: '#tune-relevance-link a click',
buttons: [{
Expand Down
2 changes: 1 addition & 1 deletion app/assets/templates/views/wizardModal.html
Original file line number Diff line number Diff line change
Expand Up @@ -93,7 +93,7 @@ <h2>What Search Endpoint do you want to connect to?</h2>
<div style="text-align: center;">
<label style="margin-right: 25px;">
<input type="radio" value="algolia" ng-model="pendingWizardSettings.searchEngine" ng-change="changeSearchEngine()">
<img ng-src="images/algolia-icon.png" alt='Algolia' height="50px" />
<img ng-src="images/algolia.png" alt='Algolia' width="150px" />
</label>
</div>

Expand Down
Binary file added public/images/algolia.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.

0 comments on commit 7e18be0

Please sign in to comment.