Bug 10032 - Uncertain prices hide 'close basket' without explanation
Summary: Uncertain prices hide 'close basket' without explanation
Status: CLOSED FIXED
Alias: None
Product: Koha
Classification: Unclassified
Component: Acquisitions (show other bugs)
Version: Main
Hardware: All All
: P5 - low enhancement (vote)
Assignee: Bugs List
QA Contact:
URL:
Keywords: Academy
Depends on:
Blocks:
 
Reported: 2013-04-12 08:31 UTC by shalomchong
Modified: 2019-10-14 19:58 UTC (History)
4 users (show)

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


Attachments
the page supposed to have the close basket button and change basket group area (125.10 KB, application/vnd.openxmlformats-officedocument.wordprocessingml.document)
2013-04-12 08:31 UTC, shalomchong
Details
Added disabled "Close this basket" button when uncertain prices are present. Note that whilst this has a "title" attribute, there is no tooltip shown because JQueryUI disabled buttons don't get DOM events. (1.79 KB, patch)
2017-12-12 17:53 UTC, Jon Knight
Details | Diff | Splinter Review
Bug 10032: Uncertain prices hide 'close basket' without explanation (1.78 KB, patch)
2018-01-03 15:47 UTC, Jon Knight
Details | Diff | Splinter Review
Bug 10032: (Follow-up) Move title attribute to button container (2.07 KB, patch)
2018-01-04 14:30 UTC, Owen Leonard
Details | Diff | Splinter Review
Added disabled "Close this basket" button when uncertain prices are present. Note that whilst this has a "title" attribute, there is no tooltip shown because JQueryUI disabled buttons don't get DOM events. (1.85 KB, patch)
2018-01-16 00:42 UTC, Charlotte Cordwell
Details | Diff | Splinter Review
Bug 10032: (Follow-up) Move title attribute to button container (2.13 KB, patch)
2018-01-16 00:42 UTC, Charlotte Cordwell
Details | Diff | Splinter Review
Bug 10032: Improve GUI when uncertain price prevents closing the basket (1.98 KB, patch)
2018-02-06 07:14 UTC, Katrin Fischer
Details | Diff | Splinter Review
Bug 10032: (follow-up) Move title attribute to button container (2.19 KB, patch)
2018-02-06 07:14 UTC, Katrin Fischer
Details | Diff | Splinter Review

Note You need to log in before you can comment on or make changes to this bug.
Description shalomchong 2013-04-12 08:31:53 UTC
Created attachment 17375 [details]
the page supposed to have the close basket button and change basket group area

I used the demo site 3.10 to run some tests. when i created a basket and finished placing order, i can't find the close basket button on top and the change basket group area.
Comment 1 Katrin Fischer 2013-04-15 04:36:48 UTC
I looked at your screenshot and I think the problem here is uncertain prices. You are not allowed to close a basket with uncertain prices, so the button is hidden until that is resolved. Maybe it would it would be better to show the button greyed out with an explaining tooltip.
Thank you for the report :)
Comment 2 Jon Knight 2017-12-12 17:53:00 UTC Comment hidden (obsolete)
Comment 3 Katrin Fischer 2017-12-26 22:58:35 UTC
Hi Jon, could you add a step-by-step test plan to this? Then this might make a good 'Academy' bug.
Comment 4 Jon Knight 2017-12-27 20:01:49 UTC
OK, how about this for a test plan:

1) Before applying the patch, go to staff UI, and select Acquisitions, pick one of your existing vendors (or create a new one) and then open a new basket (call it anything you want).

2) Add a new (empty) record order to the basket.

3) Give the new record a made up title, add a single item (no need to fill in any details), set a price of 10.00 and check the "Uncertain price" checkbox before saving the record.

4) Confirm that the resulting summary page has a button bar that does NOT include any button for closing the basket.

5) Modify the record and remove the check mark from the "Uncertain price" checkbox before saving.

6) Confirm that the resulting basket summary page button bar now does have a "Close this basket" button (as the basket no longer has uncertain prices).

7) Apply the patch.

8) Modify the record again to check the "Uncertain price" checkbox again, then save it.

9) Confirm that the resulting summary page has a button bar that does include a "Close this basket" button but that this button is greyed out and inoperative.

10) Modify the record again to remove the check mark in the "Uncertain price" checkbox, then save the record.

11) Confirm that the resulting summary page has a button bar that does include a "Close this basket" button which is now active (as the order no longer has an uncertain price).
Comment 5 Katrin Fischer 2017-12-27 20:31:34 UTC
Thx, Jon!
Comment 6 Jon Knight 2018-01-03 15:47:11 UTC Comment hidden (obsolete)
Comment 7 Owen Leonard 2018-01-04 14:30:33 UTC Comment hidden (obsolete)
Comment 8 Charlotte Cordwell 2018-01-16 00:42:33 UTC
Created attachment 70526 [details] [review]
Added disabled "Close this basket" button when uncertain prices are present. Note that whilst this has a "title" attribute, there is no tooltip shown because JQueryUI disabled buttons don't get DOM events.

https://bugs.koha-community.org/show_bug.cgi?id=10032

Signed-off-by: Charlotte Cordwell <charlotte.cordwell123@gmail.com>
Comment 9 Charlotte Cordwell 2018-01-16 00:42:37 UTC
Created attachment 70527 [details] [review]
Bug 10032: (Follow-up) Move title attribute to button container

This patch modifies the "Close basket" button markup so that the title
attribute on a disabled button is added to the button wrapper <div>
instead of the <a> tag. This allows the title attribute tooltip to
appear when the cursor is hovered over the button.

To test, follow the original patch's test plan and confirm that when the
"Close basket" button is disabled, hovering the mouse over the button
triggers the title attribute tooltip.

Signed-off-by: Charlotte Cordwell <charlotte.cordwell123@gmail.com>
Comment 10 Katrin Fischer 2018-02-06 07:11:12 UTC
Owen, I think you had a fix somewhere for the missing tooltip, but couldn't find the bug. Can you have a look maybe?
Comment 11 Katrin Fischer 2018-02-06 07:13:14 UTC
The title is already helpful and a clear improvement over the 'vanishing' of the button. Moving to PQA with the option of a later follow-up.
Comment 12 Katrin Fischer 2018-02-06 07:14:03 UTC
Created attachment 71242 [details] [review]
Bug 10032: Improve GUI when uncertain price prevents closing the basket

Added disabled "Close this basket" button when uncertain
prices are present.
Note that whilst this has a "title" attribute, there is no tooltip
shown because JQueryUI disabled buttons don't get DOM events.

https://bugs.koha-community.org/show_bug.cgi?id=10032

Signed-off-by: Charlotte Cordwell <charlotte.cordwell123@gmail.com>

Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Comment 13 Katrin Fischer 2018-02-06 07:14:07 UTC
Created attachment 71243 [details] [review]
Bug 10032: (follow-up) Move title attribute to button container

This patch modifies the "Close basket" button markup so that the title
attribute on a disabled button is added to the button wrapper <div>
instead of the <a> tag. This allows the title attribute tooltip to
appear when the cursor is hovered over the button.

To test, follow the original patch's test plan and confirm that when the
"Close basket" button is disabled, hovering the mouse over the button
triggers the title attribute tooltip.

Signed-off-by: Charlotte Cordwell <charlotte.cordwell123@gmail.com>

Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Comment 14 Jonathan Druart 2018-02-09 17:08:48 UTC
Pushed to master for 18.05, thanks to everybody involved!