Koha/koha-tmpl/intranet-tmpl/prog/en/includes
Agustin Moyano a551cb47ea
Bug 8179: Receive multiple orders
This patch implements the code to allow a patron to receive multiple
orders at the same time in /cgi-bin/koha/acqui/orderreceive.pl page

To test:
1. apply all patches
2. updatedatabase
3. Go to system preferences and allow AcqReceiveMultipleOrderLines
4. In acquisitions module, create a vendor if you don't have one and add
   3 baskets.. one with create items on ordering, one with create items
   on receiving and finally one with create items when cataloguing
5. Fill baskets with orders (There should be at least 15 orders in total). There should be a mix of orders created by suggestions, others by subscriptions and others by neither of those methods.
6. Close all baskets and receive shipment.
CHECK => in /cgi-bin/koha/acqui/parcel.pl page, in top table there is a column with checkboxes, and a button that says "Receive selected"
7. If all orders from all baskets are shown in the table, set the rows per page to 10, so table has more than one page
8. Check some of the checkboxes
CHECK => "Receive selected" button shows how many rows are selected
9. Go to the next page and select some more rows
CHECK => Changing page does not modify how many rows where selected
10. Go back to previous page
CHECK => Previously selected rows are still selected
11. Reload the page to deselect all rows
12. Select only one row and click on "Receive selected" button
CHECK => the page /cgi-bin/koha/acqui/orderreceive.pl behaves just the same as if the "receive" link in the selected row would have been clicked.
13. Click on cancel to go back to parcel.pl page
14. Select all rows (even the ones from the next page of the table) and
    click on "Receive selected"
CHECH => In orderreceive.pl page there is a table with all selected rows
15. Ensure table has more than one page, as in step 7
16. Click on the "edit" link in the last row of the current page
CHECK => A modal window is displayed with 4 tabs within: Info,
Accounting, Receipt history and Items
CHECK => Modal has 4 buttons at the bottom, 'Previous' to go to previos
order, 'Cancel' to close the modal without keeping modifications, 'Save'
to close modal keeping modifications and 'Next' to go to the next order
CHECK => Even that we are at the end of the current page, 'Next' button
is still available
17. Click on 'Next' button
CHECK => The table behind the modal now displays the next page, and the modal was not closed
18. Click on 'Previous'
CHECK => The table behind the modal went back to the first page, and the modal was not closed
19. Click on 'Previous' button till you reach the first row of the first
    page
CHECK => Only when you reach the first row of the first page 'Previous'
button gets disabled
20. Click on 'Next' button till you reach the last row of the last page
CHECK => Only when you reach the last button of the last page 'Next'
button gets disabled
21. Check that behaviour for the different types of order are still the
    same
    a. For orders that where created through suggestion, check that the
suggestion info is present in Info tab. If when suggestion was accepted
you set a reason, a dropdown to change the reason shoul display also.
    b. For orders that where created through subscriptions, check that
the Items tab is disabled, and the Receipt history is enabled. On
accounting tab you should be able to change quantity ordered. If there
were less items received than ordered, the next time you receive this
order the child order generated from this one shoul appear in receipt
history.
    c. For orders that don't come from subscription and creates there items on ordering, Receipt history
should be disabled, and a table with prefilled items shold appear in the
Items tab. You can edit them and the changes should appear in the item's
row.
    d. For orders that don't come from subscription and creates there
items on receiving, Receipt history should be disabled, and a form to
create the items should appear in Items tab. When you add an item a
table should appear.
    e. For orders that don't come from subscription and creates there
ites on cataloguing, Receipt history and Items tabs should be disabled.
    f. Any changes made in quantity (received or ordered) or funds in the modal should be
reflected in the table if you click save from the modal.
22. Once you've done all you checking and verifications click save
23. While saving a progress bar should appear
24. If no error was detected, you should be redirected back to parcel.pl
    page
25. If an error or warning was detected (like there is an order with 0
    items to receive) the save button should be disabled and warnings
are dispayed.
26. prove t/db_dependent/Koha/Acquisition/Fund.t t/db_dependent/Koha/Acquisitoin/Order.t t/db_dependent/Koha/Item.t

Sponsored-by: Virginia Polytechnic Institute and State University
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Signed-off-by: Laura Escamilla <laura.escamilla@bywatersolutions.com>

Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
2023-05-15 08:53:47 -03:00
..
background_jobs Bug 33316: (QA follow-up) Add link to record, fix typo and heading 2023-04-13 11:47:53 -03:00
catalogue Bug 33070: Remove use of can_edit_items 2023-03-17 09:59:02 -03:00
csv_headers Bug 28327: Unify CSV delimiter special behavior for tabulation 2022-08-19 15:53:12 -03:00
mana Bug 30952: Undo change to Home breadcrumb for remaining templates 2022-10-12 16:00:50 -03:00
modals Bug 31028: (follow-up) Consistently style help-block 2023-03-06 11:23:17 -03:00
str Bug 30642: (follow-up) Change sql and adapt for translations 2023-02-10 11:07:58 -03:00
virtualshelves/merge Bug 32097: Consistent classes for primary buttons: Lists 2022-11-10 10:27:17 -03:00
about-team.inc
accounts.inc Bug 26403: (QA follow-up) Add missing debit and credit types to includes 2023-05-10 15:26:15 -03:00
acquisitions-add-to-basket.inc
acquisitions-menu.inc Bug 31115: (QA follow-up) Use more specific permission for sidebar link 2022-10-24 14:11:08 -03:00
acquisitions-search.inc Bug 32683: Convert header search tabs to Bootstrap 2023-03-10 12:04:08 -03:00
acquisitions-toolbar.inc
additional-fields-display.inc
additional-fields-entry.inc Bug 31254: Add additional fields for accountlines 2022-09-21 18:58:28 -03:00
admin-items-search-field-form.inc Bug 32213: Reindent item search fields templates 2022-11-29 09:05:15 -03:00
admin-menu.inc Bug 31378: Rename Auth Provider to Identity Provider and add Client.t tests 2022-11-08 14:39:51 -03:00
adv-search.inc Bug 32683: Convert header search tabs to Bootstrap 2023-03-10 12:04:08 -03:00
auth-finder-search.inc Bug 29434: add UNIMARC relationship codes for authorities 2022-08-09 07:42:21 -03:00
auth-two-factor.inc Bug 30588: Add missing include file 2022-10-21 11:36:58 -03:00
authorities-search-results.inc
authorities-search.inc Bug 32683: Convert header search tabs to Bootstrap 2023-03-10 12:04:08 -03:00
authorities-toolbar.inc
authorities.inc
authorities_js.inc Bug 32683: Convert header search tabs to Bootstrap 2023-03-10 12:04:08 -03:00
authority-detail-modal.inc
av-build-dropbox.inc
biblio-title-head.inc
biblio-title.inc Bug 31028: Update patron and biblio includes to remove whitespace 2023-03-06 11:23:17 -03:00
biblio-view-menu.inc Bug 32005: Cleanup indenting 2022-11-10 09:21:50 -03:00
blocked-fines.inc Bug 30487: Convert checkout and patron details page tabs to Bootstrap 2022-10-17 08:06:34 -03:00
blocking_errors.inc
branch-selector.inc
budget_planning.inc
budgets-active-currency.inc
budgets-admin-search.inc Bug 32683: Convert header search tabs to Bootstrap 2023-03-10 12:04:08 -03:00
budgets-admin-toolbar.inc
calendar.inc Bug 19249: Fix date inputs on patron quick add form 2023-05-05 09:13:25 -03:00
cat-menu.inc Bug 31028: Add ability to report concerns from the staff interface 2023-03-06 11:23:17 -03:00
cat-search.inc Bug 32683: Convert header search tabs to Bootstrap 2023-03-10 12:04:08 -03:00
cat-toolbar.inc Bug 31028: Add ability to report concerns from the staff interface 2023-03-06 11:23:17 -03:00
catalog-strings.inc
cataloging-search.inc Bug 32683: Convert header search tabs to Bootstrap 2023-03-10 12:04:08 -03:00
catalogue-search-box.inc Bug 32683: Convert header search tabs to Bootstrap 2023-03-10 12:04:08 -03:00
cateditor-ui.inc Bug 32253: Load all CodeMirror lines initially when using advanced editor 2023-05-05 09:13:38 -03:00
cateditor-widgets-marc21.inc Bug 32321: Pre-populate material type for 006 in advanced cataloging editor 2023-01-27 15:14:47 -03:00
category-out-of-age-limit.inc
chart.inc
checkin-search-box.inc Bug 32683: Convert header search tabs to Bootstrap 2023-03-10 12:04:08 -03:00
checkin-search.inc Bug 32683: Convert header search tabs to Bootstrap 2023-03-10 12:04:08 -03:00
checkouts-table-footer.inc Bug 30718: Fix time display 2022-08-19 08:26:38 -03:00
checkouts-table.inc Bug 25503: Add option to export items bundle contents in checkouts table 2023-05-10 15:26:20 -03:00
circ-menu.inc Bug 33038: Add classes to patroncategorycode for easier customization 2023-04-17 09:39:44 -03:00
circ-nav.inc Bug 30624: Add loggedinlibrary permission and DB update 2023-03-13 15:22:59 -03:00
circ-search.inc Bug 32683: Convert header search tabs to Bootstrap 2023-03-10 12:04:08 -03:00
cities-admin-search.inc Bug 32683: Convert header search tabs to Bootstrap 2023-03-10 12:04:08 -03:00
clubs-table.inc
columns_settings.inc Bug 31994: DataTable next button does not work when using data in the HTML 2023-04-06 10:03:15 -03:00
contracts-admin-search.inc Bug 32683: Convert header search tabs to Bootstrap 2023-03-10 12:04:08 -03:00
country-list.inc
currencies-admin-search.inc Bug 32683: Convert header search tabs to Bootstrap 2023-03-10 12:04:08 -03:00
datatables.inc Bug 8179: Receive multiple orders 2023-05-15 08:53:47 -03:00
date-format.inc
delimiter_text.inc
desks-admin-search.inc Bug 32683: Convert header search tabs to Bootstrap 2023-03-10 12:04:08 -03:00
doc-head-close-receipt.inc
doc-head-close.inc Bug 8179: Receive multiple orders 2023-05-15 08:53:47 -03:00
doc-head-open.inc Bug 30543: Decouple DumpSearchQueryTemplate from other tempalte dump preferences 2022-08-09 08:44:14 -03:00
empty_line.inc
erm-search.inc Bug 33064: Add a licenses option to the searchbar 2023-05-10 15:26:21 -03:00
facets.inc Bug 17170: (follow-up) Use x instead of X 2022-10-21 11:15:24 -03:00
filter-orders.inc Bug 31991: Restore style of sidebar forms 2022-10-27 09:41:39 -03:00
form-blocks.inc
format_price.inc
greybox.inc
guided-reports-view.inc
header.inc Bug 30624: Add loggedinlibrary permission and DB update 2023-03-13 15:22:59 -03:00
holds_table.inc Bug 25856: Add suspend class to tr's of suspended holds 2023-03-17 09:59:03 -03:00
home-search.inc Bug 32683: Convert header search tabs to Bootstrap 2023-03-10 12:04:08 -03:00
html_helpers.inc Bug 33154: Tab WRAPPER follow-up: label text must be translatable 2023-04-13 11:47:54 -03:00
i18n.inc
ill-availability-table.inc
ill-list-table-strings.inc Bug 22440: New ILL requests table 2023-05-05 09:13:41 -03:00
ill-list-table.inc Bug 22440: New ILL requests table 2023-05-05 09:13:41 -03:00
ill-toolbar.inc
installer-doc-head-close.inc
installer-intranet-bottom.inc
installer-strings.inc
intranet-bottom.inc
intranetstylesheet.inc
job_progress.inc Bug 31666: (QA follow-up) Add filters 2022-10-05 16:08:16 -03:00
js-biblio-format.inc Bug 22440: New ILL requests table 2023-05-05 09:13:41 -03:00
js-date-format.inc Bug 30310: Fix date_to_rfc3339 2023-01-31 10:19:46 -03:00
js-patron-format-address.inc Bug 26967: Correctly format patron address in autocomplete 2023-04-21 10:36:26 -03:00
js-patron-format.inc Bug 33504: Update patron_to_html to deal with null 2023-05-05 09:13:20 -03:00
js-patron-get-age.inc
js_includes.inc Bug 26967: Correctly format patron address in autocomplete 2023-04-21 10:36:26 -03:00
keyboard_shortcuts.inc
labels-toolbar.inc
langmenu-staff-top.inc
last-borrower.inc Bug 30952: Staff interface redesign (header) 2022-10-12 15:58:16 -03:00
letters-search.inc Bug 32683: Convert header search tabs to Bootstrap 2023-03-10 12:04:08 -03:00
member-alt-address-style.inc
member-alt-contact-style.inc
member-display-address-style.inc
member-display-alt-address-style.inc
member-main-address-style.inc
member-search-box.inc Bug 32683: Convert header search tabs to Bootstrap 2023-03-10 12:04:08 -03:00
members-toolbar.inc Bug 31713: (follow-up) Display print option for any outstanding 2022-11-03 10:05:10 -03:00
merge-record.inc Bug 33181: Use template wrapper for tabs on record merge pages 2023-04-14 15:39:40 -03:00
messaging-preference-form.inc Bug 32492: (follow-up) Add missing HTML filters 2023-03-06 14:45:23 -03:00
modal-claims.inc Bug 33613: Use prop() to evaluate checkbox 2023-05-09 10:58:05 -03:00
noadd-warnings.inc
onboarding_messages.inc
page-numbers.inc
password_check.inc
patron-age.inc
patron-article-requests.inc Bug 32679: Use different CSS classes for titles of article requests in staff interface 2023-03-06 14:45:24 -03:00
patron-restrictions-tab.inc Bug 33574: Correct pointer for restrict_type.code 2023-04-20 15:48:33 -03:00
patron-return-claims.inc Bug 30487: Convert checkout and patron details page tabs to Bootstrap 2022-10-17 08:06:34 -03:00
patron-search-box.inc Bug 32683: Convert header search tabs to Bootstrap 2023-03-10 12:04:08 -03:00
patron-search-header.inc Bug 32683: Convert header search tabs to Bootstrap 2023-03-10 12:04:08 -03:00
patron-search.inc Bug 26967: Correctly format patron address in autocomplete 2023-04-21 10:36:26 -03:00
patron-title.inc Bug 33266: Fix missing space in patron title 2023-03-20 09:39:52 -03:00
patron-toolbar.inc Bug 31421: Add a limited option to template plugin 2022-10-27 09:42:57 -03:00
patron_messages.inc Bug 21699: Allow circulation messages to be editable 2023-05-05 10:18:55 -03:00
patroncards-errors.inc
patroncards-toolbar.inc
patronfields.inc Bug 32770: Restore phone 2023-02-22 15:05:24 -03:00
patrons-admin-search.inc Bug 32683: Convert header search tabs to Bootstrap 2023-03-10 12:04:08 -03:00
permissions.inc Bug 33673: Change "global system preferences" to "system preferences" 2023-05-09 10:58:01 -03:00
popup-bottom.inc
pos-menu.inc
prefs-admin-search.inc Bug 32683: Convert header search tabs to Bootstrap 2023-03-10 12:04:08 -03:00
prefs-menu.inc Bug 33634: Correct anchors in system preference submenu 2023-05-05 09:13:26 -03:00
recalls.inc
relatives-issues-table.inc Bug 30487: Convert checkout and patron details page tabs to Bootstrap 2022-10-17 08:06:34 -03:00
renew-search-box.inc Bug 32683: Convert header search tabs to Bootstrap 2023-03-10 12:04:08 -03:00
renew_results.inc
renew_strings.inc Bug 31735: Avoid re-fetcing objects from database by passing them directly instead of ids to various subroutines 2023-05-12 12:40:21 -03:00
reports-menu.inc Bug 31401: (QA follow-up) Remove Koha.ArePluginsEnabled, it is no longer needed 2022-09-07 13:55:37 -07:00
reports-toolbar.inc
resort_form.inc
restriction-types.inc Bug 33551: (QA follow-up) Fix TT filters 2023-05-05 10:18:41 -03:00
rotating-collections-toolbar.inc
search_indexes.inc Bug 31841: Use location,wrdl when searching Shelving location 2023-04-06 09:47:22 -03:00
select2.inc
serials-advsearch.inc Bug 32771: Standardize structure around action fieldsets in serials 2023-03-31 12:30:37 +02:00
serials-menu.inc
serials-search.inc Bug 32683: Convert header search tabs to Bootstrap 2023-03-10 12:04:08 -03:00
serials-toolbar.inc
shortcut.inc Bug 30952: Staff interface redesign (header) 2022-10-12 15:58:16 -03:00
slip-print.inc
stockrotation-toolbar.inc
sub-header.inc Bug 30952: Staff interface redesign (header) 2022-10-12 15:58:16 -03:00
subscriptions-search.inc Bug 32771: Standardize structure around action fieldsets in serials 2023-03-31 12:30:37 +02:00
subtype_limits.inc
subtypes_unimarc.inc
suggestions-add-search.inc Bug 32683: Convert header search tabs to Bootstrap 2023-03-10 12:04:08 -03:00
tools-item-action.inc Bug 28290: Don't send subfields to 'as_string' if none to send 2022-09-07 13:50:21 -07:00
tools-menu.inc Bug 31417: Update and reference cat-menu.inc 2022-10-18 10:28:34 -03:00
tools-nomatch-action.inc
tools-overlay-action.inc
transaction_types.inc
transfer_reasons.inc
validator-strings.inc
vendor-menu.inc
virtualshelves-toolbar.inc
waiting_holds.inc Bug 32503: Use first cancellation for date ordering 2023-02-27 11:37:12 -03:00
wysiwyg-systempreferences.inc
xslt-handler.inc
z3950-admin-search.inc Bug 32683: Convert header search tabs to Bootstrap 2023-03-10 12:04:08 -03:00
z3950_search.inc