Bug 24192

Summary: Show host record items in cart and list in staff interface
Product: Koha Reporter: Julian Maurice <julian.maurice>
Component: CatalogingAssignee: Julian Maurice <julian.maurice>
Status: Failed QA --- QA Contact: Testopia <testopia>
Severity: enhancement    
Priority: P5 - low CC: dcook, eden.bacani, fridolin.somers, Laura.escamilla, m.de.rooy
Version: Main   
Hardware: All   
OS: All   
See Also: https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=36317
Change sponsored?: --- Patch complexity: ---
Documentation contact: Documentation submission:
Text to go in the release notes:
Version(s) released in:
Circulation function:
Attachments: Bug 24192: Show host record items in basket/shelves
Bug 24192: Show host record items in basket/shelves
Bug 24192: Show host record items in basket/shelves

Description Julian Maurice 2019-12-09 16:13:26 UTC
If EasyAnalyticalRecords is enabled, and if record has no items, display host record items in baskets and lists (staff interface only)

Also, show items.enumchron in both pages
Comment 1 Julian Maurice 2019-12-09 16:14:02 UTC
Created attachment 96104 [details] [review]
Bug 24192: Show host record items in basket/shelves

If EasyAnalyticalRecords is enabled, and if record has no items, display
host record items in baskets and lists (staff interface only)

Also, show items.enumchron in both pages

Test plan:
0. Login to staff interface
1. Set EasyAnalyticalRecords to "Display"
2. Create a biblio record without items
3. On the biblio record detail page, click in the menu Edit > Link
to host item, and enter a valid barcode
4. Add the biblio record to your cart
5. Open your cart and verify that the linked item is displayed
6. Add the biblio record to a list
7. Open the list and verify that the linked item is displayed
8. Edit the linked item and enter something that will be saved in
items.enumchron (check the biblio framework mappings, add a new item
field if needed)
9. Re-open your cart and list and verify that the enumchron is shown
Comment 2 Katrin Fischer 2019-12-11 07:12:52 UTC
I think it might have been nice to split the enumchron into a separate bug - this way it would show up in the release notes.
Comment 3 Eden 2021-01-18 23:05:30 UTC
Followed the test plan but enomchron is not showing
Comment 4 Julian Maurice 2022-11-10 08:04:54 UTC
Created attachment 143624 [details] [review]
Bug 24192: Show host record items in basket/shelves

If EasyAnalyticalRecords is enabled, and if record has no items, display
host record items in baskets and lists (staff interface only)

Test plan:
0. Login to staff interface
1. Set EasyAnalyticalRecords to "Display"
2. Create a biblio record without items
3. On the biblio record detail page, click in the menu Edit > Link
to host item, and enter a valid barcode
4. Add the biblio record to your cart
5. Open your cart and verify that the linked item is displayed
6. Add the biblio record to a list
7. Open the list and verify that the linked item is displayed
Comment 5 Julian Maurice 2022-11-10 08:06:00 UTC
Rebased on master and removed the parts related to enumchron (this will go in a separate bug)
Comment 6 Laura Escamilla 2023-03-06 13:07:04 UTC
(In reply to Julian Maurice from comment #4)
> Created attachment 143624 [details] [review] [review]
> Bug 24192: Show host record items in basket/shelves
> 
> If EasyAnalyticalRecords is enabled, and if record has no items, display
> host record items in baskets and lists (staff interface only)
> 
> Test plan:
> 0. Login to staff interface
> 1. Set EasyAnalyticalRecords to "Display"
> 2. Create a biblio record without items
> 3. On the biblio record detail page, click in the menu Edit > Link
> to host item, and enter a valid barcode
> 4. Add the biblio record to your cart
> 5. Open your cart and verify that the linked item is displayed
> 6. Add the biblio record to a list
> 7. Open the list and verify that the linked item is displayed

Signed-off-by: Laura Escamilla <laura.escamilla@bywatersolutions.com>
Comment 7 ByWater Sandboxes 2023-03-08 19:00:11 UTC
Created attachment 147976 [details] [review]
Bug 24192: Show host record items in basket/shelves

If EasyAnalyticalRecords is enabled, and if record has no items, display
host record items in baskets and lists (staff interface only)

Test plan:
0. Login to staff interface
1. Set EasyAnalyticalRecords to "Display"
2. Create a biblio record without items
3. On the biblio record detail page, click in the menu Edit > Link
to host item, and enter a valid barcode
4. Add the biblio record to your cart
5. Open your cart and verify that the linked item is displayed
6. Add the biblio record to a list
7. Open the list and verify that the linked item is displayed

Signed-off-by: Laura Escamilla <laura.escamilla@bywatersolutions.com>
Comment 8 Katrin Fischer 2023-04-22 20:21:12 UTC
I am not sure about limiting this to records with no items. I had a look at other places in the code where host_items is called and we don't seem to use that condition there. (moredetail.pl,  opac-detail.pl, request.pl). 

I think it's quite possible that a record has real items and host items. That happens with bound-withs here quite often.

Maybe I am missing something?

EasyAnalytics is checked in host_items, so that is taken care of.
Comment 9 Katrin Fischer 2023-04-22 20:22:01 UTC
Also: what about the OPAC equivalents?
Comment 10 Fridolin Somers 2024-03-14 09:54:27 UTC
Looks like this could use the change from Bug 33496:
Add 'host_items' param to Koha::Biblio->items