Bug 10737 - Add "Add to basket" link on vendor search results page
Summary: Add "Add to basket" link on vendor search results page
Status: CLOSED FIXED
Alias: None
Product: Koha
Classification: Unclassified
Component: Acquisitions (show other bugs)
Version: Main
Hardware: All All
: P5 - low enhancement (vote)
Assignee: Owen Leonard
QA Contact: Jonathan Druart
URL:
Keywords:
: 9547 (view as bug list)
Depends on:
Blocks:
 
Reported: 2013-08-15 16:06 UTC by Owen Leonard
Modified: 2014-05-26 21:04 UTC (History)
5 users (show)

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


Attachments
Bug 10737 - Add "Add to basket" link on vendor search results page (10.85 KB, patch)
2013-08-15 16:30 UTC, Owen Leonard
Details | Diff | Splinter Review
Bug 10737 - Add "Add to basket" link on vendor search results page (10.87 KB, patch)
2013-08-22 14:31 UTC, Jared Camins-Esakov
Details | Diff | Splinter Review
Bug 10737 [Revised] Add "Add to basket" link on vendor search results page (12.91 KB, patch)
2013-08-26 16:37 UTC, Owen Leonard
Details | Diff | Splinter Review
Signed Off: 20634: Bug 10737 [Revised] Add "Add to basket" link on vendor search results page (12.93 KB, patch)
2013-08-28 05:04 UTC, Campbell Reid-Tait
Details | Diff | Splinter Review
Bug 10737 [Revised] Add "Add to basket" link on vendor search results page (12.99 KB, patch)
2013-09-05 07:49 UTC, Jonathan Druart
Details | Diff | Splinter Review
Bug 10737: The new column 'Closed' should be sortable. (1.08 KB, patch)
2013-09-05 07:49 UTC, Jonathan Druart
Details | Diff | Splinter Review

Note You need to log in before you can comment on or make changes to this bug.
Description Owen Leonard 2013-08-15 16:06:54 UTC
I think it would be convenient to have a shortcut to the "add to basket" options on the vendor search results page. With that you wouldn't have to click to view the basket before adding something to it.
Comment 1 Owen Leonard 2013-08-15 16:30:08 UTC Comment hidden (obsolete)
Comment 2 Jared Camins-Esakov 2013-08-22 14:31:39 UTC Comment hidden (obsolete)
Comment 3 Jonathan Druart 2013-08-23 09:02:34 UTC
QA comment:

All works as expected.

1/ 1 remark: The "Add to basket" link is only added for closed basket (normal!) so an empty column appears on bookseller with only closed basket. Maybe should we group the 2 action links into 1 column?

2/ 1 question: Isn't it possible to add the fieldset "Add order to " into an include (in order to be shared between the acqui/basket.pl page and this page?

Marked as Failed QA for 1
Comment 4 Owen Leonard 2013-08-23 16:36:20 UTC
> 2/ 1 question: Isn't it possible to add the fieldset "Add order to " into an
> include

In fact there already is one I should be using.
Comment 5 Owen Leonard 2013-08-26 16:37:01 UTC Comment hidden (obsolete)
Comment 6 Campbell Reid-Tait 2013-08-28 05:04:36 UTC Comment hidden (obsolete)
Comment 7 Jonathan Druart 2013-09-05 07:48:36 UTC
QA comment:

Thanks for this second patch: all works as expected and there is not duplicated code.
Note that the Closed column is not sortable, I will provide a followup.

Marked as Passed QA.
Comment 8 Jonathan Druart 2013-09-05 07:49:05 UTC
Created attachment 20797 [details] [review]
Bug 10737 [Revised] Add "Add to basket" link on vendor search results page

This patch adds an "add to basket" link to the vendor search results
page for each open basket associated with each vendor. Clicking it
triggers a modal window with the "add to basket" choices for that vendor
and basket.

Other changes in this patch:

- The add-to-basket include has been modified in order to make it more
  useful in this context.
- booksellers.pl has been modified to check for an existing budget so
  that the add-to-basket include can properly display a warning if there
  are none.
- "New basket" and "Receive shipment" buttons associated with each
  vendor search result have been converted to Bootstrap-styled buttons.
- Basket closed date has been moved into its own column so that the
  table can be sorted by that value.
- Table columns containing dates now use the "title-string" sort option,
  eliminating the need for a special date sorting algorithm.
- Converted some &'s to &'s

To test, apply the patch and search for a vendor. For each vendor in
your search results baskets which are open should include an "add to
basket" link. Clicking it should open a modal dialog with the same "add
to basket" options offered on the basket page. The correct vendor ID and
basket number should be associated with each link.

The newly-styled "new basket" and "receive shipment" buttons should work
correctly. Table sorting should work correctly, including the new
"closed" column.

Since the add-to-basket include file was modified, the "add to basket"
button on the basket view page should also be tested (acqui/basket.pl).

Signed-off-by: Campbell Reid-Tait <campbellreidtait@gmail.com>
Signed-off-by: Jonathan Druart <jonathan.druart@biblibre.com>
Comment 9 Jonathan Druart 2013-09-05 07:49:10 UTC
Created attachment 20798 [details] [review]
Bug 10737: The new column 'Closed' should be sortable.

Signed-off-by: Jonathan Druart <jonathan.druart@biblibre.com>
Comment 10 Galen Charlton 2013-09-05 15:34:55 UTC
Pushed to master.  Thanks, Owen!
Comment 11 Mathieu Saby 2013-10-22 07:29:01 UTC
*** Bug 9547 has been marked as a duplicate of this bug. ***