Bug 29982 - Show itemtype in holds table on patron details
Summary: Show itemtype in holds table on patron details
Status: RESOLVED DUPLICATE of bug 30081
Alias: None
Product: Koha
Classification: Unclassified
Component: Hold requests (show other bugs)
Version: Main
Hardware: All All
: P5 - low enhancement
Assignee: Bugs List
QA Contact: Testopia
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2022-01-31 10:27 UTC by Magnus Enger
Modified: 2022-02-13 14:36 UTC (History)
2 users (show)

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


Attachments
Bug 29982 - Show itemtype in holds table on patron details (4.28 KB, patch)
2022-01-31 10:38 UTC, Magnus Enger
Details | Diff | Splinter Review
screenshot of columns after patch (44.67 KB, image/png)
2022-01-31 17:12 UTC, Lucas Gass (lukeg)
Details
Bug 29982: Show itemtype in holds table on patron details (4.28 KB, patch)
2022-02-03 13:37 UTC, Magnus Enger
Details | Diff | Splinter Review
Bug 29982: Show itemtype in holds table on patron details (4.33 KB, patch)
2022-02-03 14:58 UTC, Lucas Gass (lukeg)
Details | Diff | Splinter Review

Note You need to log in before you can comment on or make changes to this bug.
Description Magnus Enger 2022-01-31 10:27:19 UTC
If possible, display the name of the item type in the "holds" table on the following tabs in patron details:

- Check out
- Details

This will only be possible when holds are item level, or they are found/waiting. It might still be relevant to be able to see the item type at a glance in these tables. 

This should not be confused with the changes from "Bug 15533 - Allow patrons and librarians to select itemtype when placing hold", which makes it possible to select a preferred itemtype for a hold, if there are different item types attached to the same record.
Comment 1 Magnus Enger 2022-01-31 10:29:05 UTC
This feature has been requested by Swedish libraries, in order to make it easier to distinguish holds related to inter library loans in the holds tables.
Comment 2 Magnus Enger 2022-01-31 10:38:36 UTC Comment hidden (obsolete)
Comment 3 Lucas Gass (lukeg) 2022-01-31 17:11:23 UTC
When I apply this patch and look at the table on either Check out or Details subsequent columns do not look right.
Comment 4 Lucas Gass (lukeg) 2022-01-31 17:12:14 UTC
Created attachment 130020 [details]
screenshot of columns after patch
Comment 5 Magnus Enger 2022-01-31 17:31:49 UTC
(In reply to Lucas Gass from comment #4)
> Created attachment 130020 [details]
> screenshot of columns after patch

Yeah, that is not how it was supposed to look... What page is that on? I thought I fixed that.
Comment 6 Lucas Gass (lukeg) 2022-01-31 17:34:04 UTC
(In reply to Magnus Enger from comment #5)
> (In reply to Lucas Gass from comment #4)
> > Created attachment 130020 [details]
> > screenshot of columns after patch
> 
> Yeah, that is not how it was supposed to look... What page is that on? I
> thought I fixed that.

Magnus, it looks like that for me on both pages:

http://localhost:8081/cgi-bin/koha/members/moremember.pl?borrowernumber=5
http://localhost:8081/cgi-bin/koha/circ/circulation.pl?borrowernumber=5
Comment 7 Magnus Enger 2022-02-01 07:40:49 UTC
> Magnus, it looks like that for me on both pages:
> 
> http://localhost:8081/cgi-bin/koha/members/moremember.pl?borrowernumber=5
> http://localhost:8081/cgi-bin/koha/circ/circulation.pl?borrowernumber=5

Looks OK when I test... From your screenshot, it looks like the header row is created ok, but then the cells in the column below it are not created, resulting in cells not being under their proper headings. 

Those cells are created from JavaScript. Did you make a hard reload (Ctrl+Shift+R)? 

Could you verify you have this code in http://localhost:8081/intranet-tmpl/prog/js/holds_21.1200011.js:

                    {
                        "mDataProp": function( oObj ) {
                            return oObj.itemtype_descr && oObj.itemtype_descr.escapeHtml() || "";
                        }
                    },

Thanks for testing!
Comment 8 Lucas Gass (lukeg) 2022-02-01 16:52:33 UTC
OK, my apologies Magnus. As soon as I cleared my cache everything looks fine. It must have been the JS. 

The only thing now is the QA tool would git you to rename your commit message:

"Bug 29982 - Show itemtype in holds table on patron details"

* Commit title does not start with 'Bug XXXXX: ' - 55787708a3
Comment 9 Magnus Enger 2022-02-03 13:37:35 UTC
Created attachment 130144 [details] [review]
Bug 29982: Show itemtype in holds table on patron details

Show item type in the holds tables on "Check out" and "Details"
tabs in the intranet.

To test:
- Add an item level hold
- Go to patron details and look at the "Check out" tab
- Click on the "Holds" horizontal tab and verify the item
  type is shown in a column between "Title" and "Call
  number"
- Go to the "Details" tab
- Click on the "Holds" horizontal tab and verify the display
  is the same as above
- Make a record level hold and verify the item type is not
  shown in the tables described above
- Check in an item from the record level hold, so it is
  "waiting" for the patron
- Verify the item type is now shown in the same way as for
  the item level hold, as described above
Comment 10 Magnus Enger 2022-02-03 13:39:22 UTC
Sorry, bad habit of copying from Bugzilla.
Comment 11 Lucas Gass (lukeg) 2022-02-03 14:58:25 UTC
Created attachment 130147 [details] [review]
Bug 29982: Show itemtype in holds table on patron details

Show item type in the holds tables on "Check out" and "Details"
tabs in the intranet.

To test:
- Add an item level hold
- Go to patron details and look at the "Check out" tab
- Click on the "Holds" horizontal tab and verify the item
  type is shown in a column between "Title" and "Call
  number"
- Go to the "Details" tab
- Click on the "Holds" horizontal tab and verify the display
  is the same as above
- Make a record level hold and verify the item type is not
  shown in the tables described above
- Check in an item from the record level hold, so it is
  "waiting" for the patron
- Verify the item type is now shown in the same way as for
  the item level hold, as described above

Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>
Comment 12 Katrin Fischer 2022-02-13 14:36:38 UTC
This looks like a perfect duplicate of bug 30081 - can you please check?

*** This bug has been marked as a duplicate of bug 30081 ***