Bug 35903 - In cataloguing authority plugin using autocomplete should set operator exact after selecting an entry
Summary: In cataloguing authority plugin using autocomplete should set operator exact ...
Status: Pushed to main
Alias: None
Product: Koha
Classification: Unclassified
Component: MARC Authority data support (show other bugs)
Version: Main
Hardware: All All
: P5 - low enhancement (vote)
Assignee: Fridolin Somers
QA Contact: Testopia
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2024-01-25 08:46 UTC by Fridolin Somers
Modified: 2024-04-29 07:38 UTC (History)
1 user (show)

See Also:
Change sponsored?: ---
Patch complexity: Small patch
Documentation contact:
Documentation submission:
Text to go in the release notes:
Version(s) released in:
24.05.00


Attachments
Bug 35903: In cataloguing authority plugin using autocomplete must set operator exact (4.55 KB, patch)
2024-01-25 09:34 UTC, Fridolin Somers
Details | Diff | Splinter Review
Bug 35903: In cataloguing authority plugin using autocomplete must set operator exact (4.60 KB, patch)
2024-01-25 16:53 UTC, ByWater Sandboxes
Details | Diff | Splinter Review
Bug 35903: In cataloguing authority plugin using autocomplete must set operator exact (4.60 KB, patch)
2024-01-25 16:53 UTC, ByWater Sandboxes
Details | Diff | Splinter Review
Bug 35903: In cataloguing authority plugin using autocomplete must set operator exact (4.70 KB, patch)
2024-04-18 13:06 UTC, Marcel de Rooy
Details | Diff | Splinter Review

Note You need to log in before you can comment on or make changes to this bug.
Description Fridolin Somers 2024-01-25 08:46:22 UTC
When cataloguing and using authority plugin, there is auto-completion on inputs and default operator is "contains".
When using auto-completion and selecting a result it would be logical to set operator "exact" and submit form.
So the usually unique result appears.
Comment 1 Fridolin Somers 2024-01-25 09:05:42 UTC
Forget about submitting the from it creates strange behavior
Comment 2 Fridolin Somers 2024-01-25 09:34:54 UTC
Created attachment 161376 [details] [review]
Bug 35903: In cataloguing authority plugin using autocomplete must set operator exact

When cataloguing and using authority plugin, there is auto-completion on inputs and default operator is "contains".
When using auto-completion and selecting a result it would be logical to set operator "exact".

See doc https://api.jqueryui.com/autocomplete/#event-select

This patch also adds auto-completion missing on "Search all headings".

Test plan:
1) Create a new authority Topical Term with heading "Cart"
2) Create a new authority Topical Term with heading "Carthage"
3) Create a new biblio record
4) Use authority plugin on field 650
5) You see current operator are "contains"
6) Enter "Car" in "Search main heading ($a only):"
7) You see auto-completion showing "Cart" and "Carthage"
8) Click on "Cart"
9) You see operator changes to "is exactly"
10) Submit form to see the results
11) Clear form and repeat 6-9 for the three other inputs
Comment 3 ByWater Sandboxes 2024-01-25 16:53:23 UTC
Created attachment 161447 [details] [review]
Bug 35903: In cataloguing authority plugin using autocomplete must set operator exact

When cataloguing and using authority plugin, there is auto-completion on inputs and default operator is "contains".
When using auto-completion and selecting a result it would be logical to set operator "exact".

See doc https://api.jqueryui.com/autocomplete/#event-select

This patch also adds auto-completion missing on "Search all headings".

Test plan:
1) Create a new authority Topical Term with heading "Cart"
2) Create a new authority Topical Term with heading "Carthage"
3) Create a new biblio record
4) Use authority plugin on field 650
5) You see current operator are "contains"
6) Enter "Car" in "Search main heading ($a only):"
7) You see auto-completion showing "Cart" and "Carthage"
8) Click on "Cart"
9) You see operator changes to "is exactly"
10) Submit form to see the results
11) Clear form and repeat 6-9 for the three other inputs

Signed-off-by: Michelle Spinney <mspinney@clamsnet.org>
Comment 4 ByWater Sandboxes 2024-01-25 16:53:49 UTC
Created attachment 161448 [details] [review]
Bug 35903: In cataloguing authority plugin using autocomplete must set operator exact

When cataloguing and using authority plugin, there is auto-completion on inputs and default operator is "contains".
When using auto-completion and selecting a result it would be logical to set operator "exact".

See doc https://api.jqueryui.com/autocomplete/#event-select

This patch also adds auto-completion missing on "Search all headings".

Test plan:
1) Create a new authority Topical Term with heading "Cart"
2) Create a new authority Topical Term with heading "Carthage"
3) Create a new biblio record
4) Use authority plugin on field 650
5) You see current operator are "contains"
6) Enter "Car" in "Search main heading ($a only):"
7) You see auto-completion showing "Cart" and "Carthage"
8) Click on "Cart"
9) You see operator changes to "is exactly"
10) Submit form to see the results
11) Clear form and repeat 6-9 for the three other inputs

Signed-off-by: Michelle Spinney <mspinney@clamsnet.org>
Comment 5 Marcel de Rooy 2024-04-18 13:06:49 UTC
Created attachment 165087 [details] [review]
Bug 35903: In cataloguing authority plugin using autocomplete must set operator exact

When cataloguing and using authority plugin, there is auto-completion on inputs and default operator is "contains".
When using auto-completion and selecting a result it would be logical to set operator "exact".

See doc https://api.jqueryui.com/autocomplete/#event-select

This patch also adds auto-completion missing on "Search all headings".

Test plan:
1) Create a new authority Topical Term with heading "Cart"
2) Create a new authority Topical Term with heading "Carthage"
3) Create a new biblio record
4) Use authority plugin on field 650
5) You see current operator are "contains"
6) Enter "Car" in "Search main heading ($a only):"
7) You see auto-completion showing "Cart" and "Carthage"
8) Click on "Cart"
9) You see operator changes to "is exactly"
10) Submit form to see the results
11) Clear form and repeat 6-9 for the three other inputs

Signed-off-by: Michelle Spinney <mspinney@clamsnet.org>

Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Comment 6 Katrin Fischer 2024-04-29 07:38:26 UTC
Pushed for 24.05!

Well done everyone, thank you!