-
Notifications
You must be signed in to change notification settings - Fork 6
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat: exact match modifier for fulltext #2208
Conversation
JIRA ticket: EC-6647 |
Preview deployment: https://pr-2208.portal-js.dev.eanadev.org/ |
@@ -12,7 +12,7 @@ const FIELD_SUGGEST_CONCEPT = 'concept'; | |||
const FIELD_SUGGEST_PLACE = 'place'; | |||
|
|||
const advancedSearchFields = [ | |||
{ name: 'fulltext', type: FIELD_TYPE_FULLTEXT }, | |||
{ name: 'fulltext', type: FIELD_TYPE_FULLTEXT, supportsExact: true }, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Instead of adding supportsExact to specific fields, derive it from the fact the the field type has a query property in the exact modifier.
packages/portal/src/lang/en.js
Outdated
@@ -1078,6 +1078,7 @@ export default { | |||
"individual": "Individual fields" | |||
}, | |||
"modifiers": { | |||
"exact": "exact match", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It would be better if this made grammatical sense when the full rule is read, which Full-text exact match european union
does not (whereas Full-text contains european union
does).
text: this.$t(`search.advanced.modifiers.${mod.name}`) | ||
})) | ||
options: this.advancedSearchModifiers.map((mod) => { | ||
if (mod.name === 'exact' && (this.field !== this.fulltextFieldName)) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This should be derived instead of hard-coded. See comment re supportsExact
in the mixin.
Quality Gate passedIssues Measures |
See #2256 |
No description provided.