Koha/koha-tmpl/intranet-tmpl/prog/en/includes
Owen Leonard 0b9a7e3546
Bug 24347: Add a 'search to order' option similar to 'search to hold'
This patch modifes the process of searching for an existing record
to add to a basket. Now the search is performed as a keyword search in
the regular catalog rather than via a custom search script. Options are
added to the search results and detail pages to add results to an order.

This process follows the same pattern as the "Search to hold" feature:
When the search is initiated, a cookie is set with the requisite
information--in this case vendor id and basket number.

If the search results or bibliographic detail pages detect that a
"searchToOrder" cookie is present, the correct "Add order" link will be
shown. Like with the "search to hold" feature, the cookie expires in 10
minutes.

To test, apply the patch and log into the staff client as a user who has
permission to add to a basket in acquisitions.

 - Go to Acquisitions -> Vendor -> Basket -> Add to basket.
 - Using the "From an existing record" option, perform a search.
 - On the search results page, test the "Add order" link which appears
   with each result. Clicking the link should take you to the "New
   order" page for the correct vendor and basket. The catalog
   details section of the form should include the correct information.
 - From the search results page view the bibliographic details page for
   any record. There should be a new toolbar button, "Add order." Verify
   that it works correctly.
   - Test the same thing from all bibliographic detail pages: Normal,
     MARC, Labeled MARC, ISBD, as well as the items page
     (moredetail.pl).
 - Test this process for both the locations in acquisitions where one
   can add to an existing basket: Vendor search results and the basket
   detail page
 - Test the cookie timeout: Wait 10 minutes and perform another catalog
   search. The "Add order" link should no longer be present.

Signed-off-by: David Nind <david@davidnind.com>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
2020-01-30 10:58:03 +00:00
..
catalogue Bug 24104: Item search - Prevent "Edit" dropdown button to overflow 2020-01-08 14:12:16 +00:00
csv_headers Bug 12502: Add vendor note, internal note, ordernumber and isbn to late orders page 2020-01-20 16:37:21 +00:00
mana Bug 23013: Upgrade DataTables in the staff client 2019-08-22 15:23:19 +01:00
modals Bug 13618: Add html filters to all the variables 2018-08-17 15:55:05 +00:00
str Bug 22661: TinyMCE/WYSIWYG editor doesn't translate 2019-11-03 07:39:54 +00:00
virtualshelves/merge Bug 13618: Add html filters to all the variables 2018-08-17 15:55:05 +00:00
about-team.inc Koha 19.12 - Dobbie is a free elf... 2019-12-02 17:13:15 +00:00
accounts.inc Bug 24080: (RM follow-up) Add payout to 'accounts.inc' 2020-01-23 16:14:12 +00:00
acquisitions-add-to-basket.inc Bug 24347: Add a 'search to order' option similar to 'search to hold' 2020-01-30 10:58:03 +00:00
acquisitions-menu.inc Bug 22868: Move suggestions_manage subperm out of acquisition perm 2020-01-30 08:27:00 +00:00
acquisitions-search.inc Bug 18584: Our legacy code contains trailing-spaces 2018-11-15 12:47:34 +00:00
acquisitions-toolbar.inc Bug 22957: Remove type attribute from script tags: Staff client includes 1/2 2019-07-15 11:27:58 +01:00
additem.js.inc Bug 22957: Remove type attribute from script tags: Staff client includes 1/2 2019-07-15 11:27:58 +01:00
additional-fields-display.inc Bug 15774: (follow-up) Add html filters 2019-03-07 20:37:05 +00:00
additional-fields-entry.inc Bug 15774: (follow-up) Add html filters 2019-03-07 20:37:05 +00:00
admin-items-search-field-form.inc Bug 13618: remove wrong html filter in 'Item search fields' admin 2018-10-26 15:54:54 +00:00
admin-menu.inc Bug 24481: Permission corrections for admin menu templates 2020-01-23 08:48:50 +00:00
adv-search.inc Bug 13272: (follow-up) add missing type="text" 2018-10-01 11:18:32 +00:00
auth-finder-search.inc Bug 13618: Add html filters to all the variables 2018-08-17 15:55:05 +00:00
authorities-search-results.inc Bug 21526: Use the 'url' filter when needed 2018-11-12 16:35:43 -03:00
authorities-search.inc Bug 13618: Add html filters to all the variables 2018-08-17 15:55:05 +00:00
authorities-toolbar.inc Bug 22023: Further improve responsive layout handling of staff client menu bar 2019-03-13 05:31:28 +00:00
authorities.inc Bug 21526: uri escape TT variables when used in 'a href' 2018-10-26 17:09:57 +00:00
authorities_js.inc Bug 23947: Phase out jquery.cookie.js: Authority merge 2020-01-29 09:09:33 +00:00
av-build-dropbox.inc Bug 13618: Add html filters to all the variables 2018-08-17 15:55:05 +00:00
biblio-default-view.inc Bug 13618: Add html filters to all the variables 2018-08-17 15:55:05 +00:00
biblio-title-head.inc Bug 11529: Prevent too many spaces/break lines in the title tag 2019-08-05 18:43:26 +01:00
biblio-title.inc Bug 11529: (follow-up) Fix QA issues 2019-08-05 15:03:19 +01:00
biblio-view-menu.inc Bug 10352: Use a new object_type parameter instead of the module's name 2020-01-10 08:36:37 +00:00
blocked-fines.inc Bug 21757: Clenup of moremember.pl and its templates 2019-04-29 12:12:40 +00:00
blocking_errors.inc Bug 22786: Prevent fund creation for locked budgets 2019-09-06 13:17:47 +01:00
borrower_debarments.inc Bug 13272: (follow-up) fix concerns from comment #5 2018-10-01 11:18:31 +00:00
branch-selector.inc Bug 23184: Don't select branches for export by default 2019-11-21 11:32:31 +00:00
budgets-active-currency.inc Bug 13618: Add html filters to all the variables 2018-08-17 15:55:05 +00:00
budgets-admin-search.inc Bug 13618: Add html filters to all the variables 2018-08-17 15:55:05 +00:00
budgets-admin-toolbar.inc Bug 22786: Prevent fund creation for locked budgets 2019-09-06 13:17:47 +01:00
calendar.inc Bug 24181: Make our datepicker inputs sexy 2020-01-03 15:52:34 +00:00
cat-menu.inc
cat-search.inc Bug 19046: Make seach pulldown to retain index selection 2019-03-11 10:28:09 +00:00
cat-toolbar.inc Bug 24347: Add a 'search to order' option similar to 'search to hold' 2020-01-30 10:58:03 +00:00
catalog-strings.inc Bug 22957: Remove type attribute from script tags: Staff client includes 1/2 2019-07-15 11:27:58 +01:00
cataloging-search.inc Bug 13272: (follow-up) add missing type="text" 2018-10-01 11:18:32 +00:00
cateditor-ui.inc Bug 24323: Advanced editor - Display an error message if the record did not save 2020-01-10 10:48:05 +00:00
cateditor-widgets-marc21.inc Bug 23045: TextMarc errors on blank lines 2019-07-01 14:52:37 +01:00
category-out-of-age-limit.inc Bug 17492: (QA follow-up) Correct template variable 2019-07-01 15:20:31 +01:00
chart.inc Bug 23626: [alternate] Default to including all rows 2019-10-09 14:31:59 +01:00
checkin-search.inc Bug 13272: (follow-up) add missing type="text" 2018-10-01 11:18:32 +00:00
checkouts-table-footer.inc Bug 20194: Display both biblioitems.itemtype and items.itype in circulation screens 2019-11-03 07:50:19 +00:00
checkouts-table.inc Bug 20194: Display both biblioitems.itemtype and items.itype in circulation screens 2019-11-03 07:50:19 +00:00
circ-menu.inc Bug 22868: Move suggestions_manage subperm out of acquisition perm 2020-01-30 08:27:00 +00:00
circ-nav.inc Bug 10300: (follow-up) add controls on transfers page 2019-04-26 11:49:08 +00:00
circ-patron-search-results.inc Bug 17353: Add phone number column to checkout search 2019-01-28 13:06:35 +00:00
circ-search.inc Bug 13272: Adds type="text" to inputs missing it 2018-10-01 11:18:30 +00:00
cities-admin-search.inc Bug 13618: Add html filters to all the variables 2018-08-17 15:55:05 +00:00
clubs-table.inc Bug 24393: Remove event attributes from patron clubs list template 2020-01-20 14:03:51 +00:00
columns_settings.inc Bug 12502: (follow-up) Adds formatting for datatables export 2020-01-20 16:37:21 +00:00
contracts-admin-search.inc Bug 13618: Add html filters to all the variables 2018-08-17 15:55:05 +00:00
country-list.inc
currencies-admin-search.inc Bug 13618: Add html filters to all the variables 2018-08-17 15:55:05 +00:00
datatables.inc Bug 24046: Untranslatable 'Activate filters' 2019-12-23 11:25:13 +00:00
date-format.inc
delimiter_text.inc Bug 19910: Use span to make translators happy 2018-04-04 16:06:56 -03:00
doc-head-close-receipt.inc Bug 13618: Add html filters to all the variables 2018-08-17 15:55:05 +00:00
doc-head-close.inc Bug 23013: Upgrade DataTables in the staff client 2019-08-22 15:23:19 +01:00
doc-head-open.inc Bug 13618: Add html filters to all the variables 2018-08-17 15:55:05 +00:00
empty_line.inc Bug 13618: Add html filters to all the variables 2018-08-17 15:55:05 +00:00
facets.inc Bug 24371: Fix "Show all items" avaibility link (use $raw filter) - intra 2020-01-10 10:47:32 +00:00
filter-orders.inc Bug 14669: (RM follow-up) Ensure updated include compiles 2019-10-09 07:30:51 +01:00
form-blocks.inc Bug 13618: Add html filters to all the variables 2018-08-17 15:55:05 +00:00
format_price.inc Bug 22957: Remove type attribute from script tags: Staff client includes 1/2 2019-07-15 11:27:58 +01:00
greybox.inc Bug 22957: Remove type attribute from script tags: Staff client includes 1/2 2019-07-15 11:27:58 +01:00
guided-reports-view.inc Bug 19856: Improve styling of reports sidebar 2018-03-23 11:45:38 -03:00
header.inc Bug 23803: Add Font Awesome icon to cart in staff interface 2019-10-11 14:34:58 +01:00
holds_table.inc Bug 24350: (follow-up) Clear Koha::Libraries->pickup_locations() and move logic to Koha::Template::Plugin::Branches->pickup_locations(). 2020-01-13 10:03:35 +00:00
home-search.inc Bug 12283: Disable autocomplete for patron search inputs 2019-01-30 11:53:17 +00:00
html_helpers.inc Bug 13618: Add html filters to all the variables 2018-08-17 15:55:05 +00:00
i18n.inc Bug 15395: Make QA test script happy 2018-11-08 15:55:52 +00:00
ill-list-table-strings.inc Bug 18589: (follow-up) Fix QA tool failures 2019-03-22 20:21:47 +00:00
ill-list-table.inc Bug 18589: (follow-up) Fix QA tool failures 2019-03-22 20:21:47 +00:00
ill-toolbar.inc Bug 22099: Fixed ILL toolbar to say Refresh when displaying requests 2019-06-03 18:56:29 +01:00
installer-doc-head-close.inc Bug 22451: Use Asset everywhere 2019-04-16 13:17:32 +00:00
installer-intranet-bottom.inc Bug 22451: Use Asset everywhere 2019-04-16 13:17:32 +00:00
installer-strings.inc Bug 22973: Remove type attribute from script tags: Staff client includes 2/2 2019-05-30 10:25:21 +00:00
intranet-bottom.inc Bug 24230: fix intranet_js plugin hook before body end tag 2019-12-13 15:28:33 +00:00
intranetstylesheet.inc Bug 13618: Add html filters to all the variables 2018-08-17 15:55:05 +00:00
js_includes.inc Bug 23944: Phase out use of jquery.cookie.js in favor of js.cookie.js 2020-01-29 09:08:30 +00:00
keyboard_shortcuts.inc Bug 17179: Add keyboard shortcuts to repeat (duplicate) a field, and cut text 2019-10-09 14:36:09 +01:00
labels-toolbar.inc Bug 7468: Print barcodes by range 2020-01-21 11:28:19 +00:00
langmenu-staff-top.inc Bug 21526: uri escape TT variables when used in 'a href' 2018-10-26 17:09:57 +00:00
last-borrower.inc Bug 20312: Add a link to last consulted patron 2018-11-08 15:38:20 +00:00
letters-search.inc Bug 13618: Add html filters to all the variables 2018-08-17 15:55:05 +00:00
member-alt-address-style-de.inc Bug 3766: Cities/Towns only on one address 2019-04-17 12:25:25 +00:00
member-alt-address-style-fr.inc Bug 3766: Cities/Towns only on one address 2019-04-17 12:25:25 +00:00
member-alt-address-style-us.inc Bug 3766: Cities/Towns only on one address 2019-04-17 12:25:25 +00:00
member-alt-contact-style-de.inc Bug 3766: Cities/Towns only on one address 2019-04-17 12:25:25 +00:00
member-alt-contact-style-fr.inc Bug 3766: Cities/Towns only on one address 2019-04-17 12:25:25 +00:00
member-alt-contact-style-us.inc Bug 3766: Cities/Towns only on one address 2019-04-17 12:25:25 +00:00
member-display-address-style-de.inc Bug 13618: Add html filters to all the variables 2018-08-17 15:55:05 +00:00
member-display-address-style-fr.inc Bug 13618: Add html filters to all the variables 2018-08-17 15:55:05 +00:00
member-display-address-style-us.inc Bug 13618: Add html filters to all the variables 2018-08-17 15:55:05 +00:00
member-display-alt-address-style-de.inc Bug 13618: Add html filters to all the variables 2018-08-17 15:55:05 +00:00
member-display-alt-address-style-fr.inc Bug 13618: Add html filters to all the variables 2018-08-17 15:55:05 +00:00
member-display-alt-address-style-us.inc Bug 13618: Add html filters to all the variables 2018-08-17 15:55:05 +00:00
member-main-address-style-de.inc Bug 3766: Cities/Towns only on one address 2019-04-17 12:25:25 +00:00
member-main-address-style-fr.inc Bug 3766: Cities/Towns only on one address 2019-04-17 12:25:25 +00:00
member-main-address-style-us.inc Bug 3766: Cities/Towns only on one address 2019-04-17 12:25:25 +00:00
members-toolbar.inc Bug 14570: (QA follow-up) Fix issues in Guarantor context 2019-08-20 16:05:46 +01:00
merge-record-strings.inc Bug 21672: Switch templates to Bootstrap grid: Various 2019-01-25 17:41:37 +00:00
merge-record.inc Bug 21526: uri escape TT variables when used in 'a href' 2018-10-26 17:09:57 +00:00
messaging-preference-form.inc Bug 22744: Remove the 'do not notify' buttons 2019-09-23 11:57:40 +01:00
noadd-warnings.inc
onboarding_messages.inc Bug 13618: Add html filters to all the variables 2018-08-17 15:55:05 +00:00
page-numbers.inc Bug 22935: Improve style of Bootstrap pagination 2019-06-24 15:41:07 +01:00
password_check.inc Bug 22973: Remove type attribute from script tags: Staff client includes 2/2 2019-05-30 10:25:21 +00:00
patron-article-requests.inc Bug 13618: Add html filters to all the variables 2018-08-17 15:55:05 +00:00
patron-return-claims.inc Bug 14697: Enhance the return claims feature 2019-10-31 12:04:21 +00:00
patron-search-box.inc Bug 23697: (QA follow-up) Rename PatronAutocompletion to PatronAutoComplete 2019-10-08 14:51:12 +01:00
patron-search.inc Bug 23697: Add autocompletion search in patron module 2019-10-08 14:50:51 +01:00
patron-title.inc Bug 21526: Remove duplicated USE raw statement 2018-10-26 17:09:58 +00:00
patron-toolbar.inc Bug 22023: Further improve responsive layout handling of staff client menu bar 2019-03-13 05:31:28 +00:00
patroncards-errors.inc Bug 13618: Add html filters to all the variables 2018-08-17 15:55:05 +00:00
patroncards-toolbar.inc Bug 22698: Fix incorrect button classes 2019-04-16 13:17:33 +00:00
patrons-admin-search.inc Bug 13618: Add html filters to all the variables 2018-08-17 15:55:05 +00:00
permissions.inc Bug 22868: Move suggestions_manage subperm out of acquisition perm 2020-01-30 08:27:00 +00:00
popup-bottom.inc Bug 13618: Manually replace missing .raw 2018-08-17 15:55:10 +00:00
pos-menu.inc Bug 24481: Permissions update for POS menu include 2020-01-23 08:48:54 +00:00
prefs-admin-search.inc Bug 13618: Add html filters to all the variables 2018-08-17 15:55:05 +00:00
prefs-menu.inc Bug 23321: (RM follow-up) Accounts vs. Accounting 2019-09-27 10:37:19 +01:00
quotes-toolbar.inc Bug 22023: Further improve responsive layout handling of staff client menu bar 2019-03-13 05:31:28 +00:00
quotes-upload-toolbar.inc Bug 22698: Fix incorrect button classes 2019-04-16 13:17:33 +00:00
relatives-issues-table.inc Bug 20194: Display both biblioitems.itemtype and items.itype in circulation screens 2019-11-03 07:50:19 +00:00
reports-menu.inc Bug 19856: (follow-up) Improve styling of reports sidebar 2018-03-23 11:45:38 -03:00
reports-toolbar.inc Bug 23812: Download icon is an upload icon 2019-10-17 14:53:43 +01:00
resort_form.inc
rotating-collections-toolbar.inc Bug 22698: Fix incorrect button classes 2019-04-16 13:17:33 +00:00
search_indexes.inc Bug 19046: (QA follow-up) Remove doubled up 'Title as phrase' 2019-03-11 10:28:09 +00:00
select2.inc Bug 22451: Use Asset everywhere 2019-04-16 13:17:32 +00:00
serials-menu.inc Bug 23446: Fix display issue in serials navigation 2019-08-16 11:41:55 +01:00
serials-search.inc Bug 13618: Add html filters to all the variables 2018-08-17 15:55:05 +00:00
serials-toolbar.inc Bug 23065: Rename "New subscription" button when default to current serial 2019-06-13 12:28:00 +01:00
slip-print.inc Bug 22973: Remove type attribute from script tags: Staff client includes 2/2 2019-05-30 10:25:21 +00:00
stockrotation-toolbar.inc Bug 22209: Move stock rotation stage and item forms into modals 2019-08-08 16:05:50 +01:00
strings.inc Bug 23885: Move staff client search results JavaScript into separate file 2020-01-29 09:05:01 +00:00
subscriptions-search.inc
subtypes_unimarc.inc
suggestions-add-search.inc Bug 13618: Add html filters to all the variables 2018-08-17 15:55:05 +00:00
timepicker.inc Bug 22973: Remove type attribute from script tags: Staff client includes 2/2 2019-05-30 10:25:21 +00:00
tools-item-action.inc
tools-menu.inc Bug 11642: (follow-up) Improve Batch patron deletion and anonymization GUI to make consequences clearer 2019-07-15 12:43:03 +01:00
tools-nomatch-action.inc
tools-overlay-action.inc
validator-strings.inc Bug 22973: Remove type attribute from script tags: Staff client includes 2/2 2019-05-30 10:25:21 +00:00
vendor-menu.inc Bug 21526: uri escape TT variables when used in 'a href' 2018-10-26 17:09:57 +00:00
virtualshelves-toolbar.inc Bug 22698: Fix incorrect button classes 2019-04-16 13:17:33 +00:00
waiting_holds.inc Bug 24024: Invert names on halds waiting report 2019-11-21 11:30:44 +00:00
wysiwyg-systempreferences.inc Bug 22661: TinyMCE/WYSIWYG editor doesn't translate 2019-11-03 07:39:54 +00:00
xslt-handler.inc Bug 20272: Changes for Breeding.pm and Record.pm 2018-07-02 12:12:49 +00:00
z3950-admin-search.inc Bug 13618: Add html filters to all the variables 2018-08-17 15:55:05 +00:00
z3950_search.inc Bug 22973: Remove type attribute from script tags: Staff client includes 2/2 2019-05-30 10:25:21 +00:00