- Copying over error handling for timeout(10007) and refused(10000)
- Copying over error handling for submission with no targets chosen
- Correcting "cancel" link in the template which was not modified
when it was copied from cataloging's popup window template.
Signed-off-by: Chris Cormack <chrisc@catalyst.net.nz>
Signed-off-by: Paul Poulain <paul.poulain@biblibre.com>
Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Tested. Comments have been incorporated. Marked as Passed QA.
http://bugs.koha-community.org/show_bug.cgi?id=7342
Signed-off-by: Paul Poulain <paul.poulain@biblibre.com>
Signed-off-by: Nicole C. Engard <nengard@bywatersolutions.com>
Tested by recieving multiple items with the AcqCreateItem
preference set to 'placing and order' and 'receiving an item'
In both cases the pricing and vendor is brought over to the
item record so I'm signing off.
Signed-off-by: Paul Poulain <paul.poulain@biblibre.com>
Signed-off-by: Katrin Fischer <Katrin.Fischer.83@web.de>
This bookseller has no email shows up correctly, when vendor has
no email address.
Small change made: Changed bookseller to vendor.
This patch fixes some minor problems found in late order management:
1) Silences 2 warns in Letters.p
After patch is applied no more warns should show up in the logs.
2) Fixes check/uncheck al
When limiting on one vendor the checkbox in the last header column
was doing nothing. I changed the checkbox to 2 links 'check all' and
'uncheck all' as it's done in other templates.
3) Email has been sent
The message was hardcoded into the lateorders.pl file and not
translatable.
I moved it to the template and changed the wording slightly.
Note: The error message 'The bookseller has no email' comes from
Letters.pm. I didn't change that, because I was not sure where it is
used. The error message as is can not be translated and should be
moved into the templates too.
Signed-off-by: Jonathan Druart <jonathan.druart@biblibre.com>
Signed-off-by: Paul Poulain <paul.poulain@biblibre.com>
This patch adds 2 columns in the aqorders table :
- claims_count : number of claims for an orders
- claimed_date : date of the lastest claim
In the lateorders.pl table, you can not select orders from different
supplier because there is just one letter sent after clicking the "Claim
order" button. So, it's logic that you want to select only orders from
this supplier.
Modification in C4/Letters.pm:
refactoring code for claimacquisition and claimissues letter type.
Now, fields for theses letters check the table name. It's not possible
to chooce aqorders.title, this field doesn't exist !
Furthermore, you can add a <order> tag around your item fields, like
this :
-- Begin example
<<LibrarianFirstname>>
<<LibrarianSurname>>
<<aqbooksellers.contact>>
<<aqbooksellers.address1>>
<<aqbooksellers.phone>>
<<aqbasket.basketno>>
<<aqbooksellers.phone>>
<order>Library : <<items.homebranch>>
In your possesssion : <<biblio.author>>. <<biblio.title>>.
<<biblioitems.publishercode>>, <<biblioitems.publicationyear>>.
Callnumber : <<items.itemcallnumber>>. doc type : <<items.itype>>
Barcode : <<items.barcode>>
Date for the return : <<items.onloan>>.</order>
<<LibrarianSurname>>
-- End example
Signed-off-by: Katrin Fischer <Katrin.Fischer.83@web.de>
This patch introduces a Filter (KohaDates) for use in templates
[% USE KohaDates %]
[% somevariable | $KohaDates %]
This will format the date in the format specified by the systempreference
Signed-off-by: Katrin Fischer <Katrin.Fischer.83@web.de>
Reimplementing 3.0.x patch from
Nahuel ANGELINETTI <nahuel.angelinetti@biblibre.com>
To test:
1) Create basket
2) Order something, note your fund
3) Receive title
> Verify your name and selected fund display correctly
Additional tests:
1) Set borrowernumber in aqbasket.authorisedby to a nonexistant borrowernumber (like something really big)
> Created by should show "No name"
2) Set borrowernumber to NULL / empty
> Created by should show "No name"
Signed-off-by: Duncan Tyler <duncan@catalyst.net.nz>
Signed-off-by: Paul Poulain <paul.poulain@biblibre.com>
A suggestion added through addorder.pl now changes
to the ORDERED status as initially intended (but so
far it stayed as ACCEPTED).
This fixes the list of potential suggestions to order,
the ORDERED ones don't appear anymore.
Bug 6893 : Follow-up: Disabled WHERE clause excluding ORDERED status
In SearchSuggestions, a WHERE clause was excluding the ORDERED
suggestions from the results. Now replaced with 1=1.
(before 6893 correction, the WHERE clause was excluding the
STATUS='CLAIMED' suggestions, but this status cannot be found anywhere
else in the code... so I changed to STATUS='ORDERED' which
seemed more accurate, but it had impacts on OPAC and some Admin tabs)
Signed-off-by: Katrin Fischer <Katrin.Fischer.83@web.de>
Both patches applied cleanly, sqashed them together after testing.
Tested:
1) Creating new suggestions
- from OPAC, shows up in patron account as 'requested', pending in staff
- from staff, shows up in list of pending suggestions
Status in database is ASKED
Note: suggestions made from staff for the same patron have suggestedby = 0
in the database, so are not showing up in the patron account. Is this by
intention? (if not, I think this is a separate bug)
2) Accepting suggestions
- from list
- from edit page
Status in database is ACCEPTED
Patron account shows 'Accepted by the library (Bestseller)'
Note: after changing the status from the list, bug 4068 kicks in and
some tabs and even suggestions are hidden. Going back to the acq start
page and going back to the suggestions page from there helps.
3) Rejecting suggestions
- from list
- from edit page
Status in database is REJECTED
Patron account in OPAC shows 'Suggestion declined'
Note: bug 4068 again.
4) Ordering from suggestions
- new basket
- ordered 2 accepted suggestions
SUCCESS! Great improvement:
- Status in database is now ORDERED
- Already ordered suggestions no longer show up on list of
suggestions to order from.
- Patron account shows 'Ordered by the library (Bestseller)'
- Suggestion management page shows a new tab 'Ordered'
- For the suggestion with a valid 'suggestedby' borrowernumber,
a mail was generated. (bug 7094)
5) Receive ordered suggestions
- received my ordered suggestions
This is is not in the scope of this bug, but for documentation:
- No message was generated to inform the patron
- Status stays ORDERED
- Patron account still shows item as ordered, no change to 4)
Looking at the suggestion.tt I think there should be another status
AVAILABLE.
216 [% ELSIF (suggestion.suggestiontypelabel == "Available") %]Available
Signing off, fixes bug reported. Danke!
Signed-off-by: Paul Poulain <paul.poulain@biblibre.com>
This patch makes it possible to add the account number to the
vendor information. The used field aqbookseller.accountnumber was
already existent in the database.
To test:
1) Add a new vendor with accountnumber
> Verify form has a field for accountnumber
> Verify accountnumber does show up on vendor summary page
2) Edit this vendor, change accountnumber
> Verify change was correctly saved and new number is displayed on
vendor summary page
3) Delete accountnumber
Signed-off-by: Liz Rea <lrea@nekls.org>
Tested 1-3, no troubles found.
Signed-off-by: Paul Poulain <paul.poulain@biblibre.com>
Currently when creating a new vendor in acquisitions the alphabetical first
currency will be preselected. For better usability and less mistakes the
active curency should be preselected.
To test:
Check your currency settings in administration.
Your active currency should not be the first in the list.
1) Create a new vendor
Verify the active currency is selected for list and invoice prices.
2) Check vendor summary page
Verify the correct currencies from the vendor record are shown here.
3) Edit vendor
Verify the correct currencies from the vendor record are shown here.
Signed-off-by: Liz Rea <lrea@nekls.org>
Verified with tests 1, 2, and 3.
Signed-off-by: Paul Poulain <paul.poulain@biblibre.com>
PDF print of basket groups is broken.
To test:
1) Make sure OrderPdfFormat is set to pdfformat::layout2pages or pdfformat::layout3pages
2) Create a basket with orders
3) Close the basket and create a basket group checking the checkbox
4) Print the basket group as PDF
Before patch the file is broken and when opened in an editor contains an error message.
After the patch the PDF should be generated correctly again.
Thx to Chris for helping me to fix the problem.
Signed-off-by: Chris Cormack <chrisc@catalyst.net.nz>
Signed-off-by: Paul Poulain <paul.poulain@biblibre.com>
aqbasket.authorisedby is not foreign key constrainted to borrowers.borrowernumber,
so if it's anything other than that, vendor search breaks by using an undefined value
(GetMember() on an invalid borrowernumber) as a HASH ref.
This patch sets the branchcode (the desired value from GetMember) to a blank value, then only
changes it if GetMember is defined. In the case where the authorisedby librarian has been deleted,
or the value is otherwise invalid, and AcqViewBaskets is set to 'branch', the basket will not appear
except to superlibrarians
Signed-off-by: Katrin Fischer <Katrin.Fischer.83@web.de>
Invalid borrowernumber in aqbasket.authorisedby no longer breaks search.
When ordering from an existing record the 'no budgets and funds defined' error
message was shown below the result list.
To test:
A) No budgets defined for this user and library
Basket summary page shows a warning instead of the link for creation
of orders.
B) Budgets and funds are properly defined for this user and library
Basket summary page shows links for order creation.
Before patch: A search for an existing record had the alert at the bottom
of the search result list.
After patch: The links for creation of orders are shown instead.
Signed-off-by: Liz Rea <lrea@nekls.org>
Verified A and B.
Signed-off-by: Paul Poulain <paul.poulain@biblibre.com>
Instead of using the 'p' subfield directly, use the subfield letter
associated with the items.barcode column.
http://bugs.koha-community.org/show_bug.cgi?id=6963
Signed-off-by: Katrin Fischer <Katrin.Fischer.83@web.de>
Test cases tested:
- 1 item, barcode empty
- 2 items, barcodes both empty
- 1 item, existing barcode
- 1 item, new barcode
- 2 items, one barcode empty, one existing
All test cases worked nicely and gave correct error messages.
Signed-off-by: Paul Poulain <paul.poulain@biblibre.com>
If the AcqCreateItem preference is set to "ordering" and the barcode for
the new item is already in use, no error is returned, but an invalid
itemnumber is saved in the aqorders_items table and the item is never
created.
This patch adds a duplicate barcode verification in neworderempty.pl
_koha_add_item is also modified so it won't return an invalid ID when
an item can't be added.
http://bugs.koha-community.org/show_bug.cgi?id=6963
Signed-off-by: Katrin Fischer <Katrin.Fischer.83@web.de>
Test plan on second patch.
http://bugs.koha-community.org/show_bug.cgi?id=6414
Signed-off-by: Nicole C. Engard <nengard@bywatersolutions.com>
Signed off with a note: this doesn't fix everything mentioned in the bug.
It also might clash with bug 4831 and should be tested with that patch.
Signed-off-by: Paul Poulain <paul.poulain@biblibre.com>
The same scope than in basket.pl
Signed-off-by: Katrin Fischer <Katrin.Fischer.83@web.de>
Detailed information about possible deletion of orders on parcel page.
1) Delete order for record with 1 other item and item level hold
OK. Record, item and hold remain, only on order item is deleted.
2) Delete order for ordered record with 1 item and title level hold
OK. Deletion is not possible, before hold is cancelled.
3) Delete order for new record with only items connected to this order
OK. Cancelling the order deletes record and item or only order,
depending on link used.
4) Delete order for record with subscription.
OK. Subscription remains untouched, item is deleted.
Also checked:
AcqCreateItem = on receive / in cataloging
Links show and it's possible to delete the order or only the record
using different links.
Comments:
There is a table sorter option for the last column with the delete links.
I am not sure it is useful here, but it does work.
Before patch is applied, the links use 'cancel' instead of 'delete'.
I am not sure which is better and if it should be different on
basket summary and order receive or the same on both.
QA Comment:
Made a small change to template language; blocking deletion because of items referred to
holds instead. Changed text to refer to items.
Signed-off-by: Ian Walls <ian.walls@bywatersolutions.com>
Signed-off-by: Chris Cormack <chrisc@catalyst.net.nz>
- all items attached to the order are deleted
- if there is no more items, and if the biblio is not in other orders and no subscriptions and no holds then the biblio is proposed to deletion
Now whe have 2 links : "delete order" and "delete order and catalog record", the second one appears only if the deletion is possible.
Note that if an hold is related to the item or if the item is unique for the biblio the link "Delete order" is canceled due to hold remaining.
On mouse over explanations are shown with count.
More lines of warnings with count are shown depending of the case.
Signed-off-by: Katrin Fischer <Katrin.Fischer.83@web.de>
Configuration:
AcqCreateItem = on order
Test cases and results:
1) Order new record with 2 items
a) From basket
- delete order: only deletes items, OK!
- delete order and catalog record: deletes record and items, OK
b) From shipment/receive
- delete order: only deletes items, OK!
2) Order 1 additional item for existing record with 1 item
a) From basket:
- delete order: works, existing item and record remain, OK
- Can't delete order and catalog record, 1 item left, OK!
3) Order new record with 1 item, title level hold on record
a) From basket:
- delete order: not possible, OK!
- delete orer and catalog record: not possible, OK!
b) From shipment/receive page
- Cancel: Deletes order, record and hold silently.
NO WARNING. NOT OK. See note below.
4) Order 1 additional item for existing record with 1 item,
item level hold on existing item
a) From basket:
- delete order: works, hold and existing item remain, OK!
- delete order and catalog record: not possible, OK!
b) From shipment/receive page
- Cancel: on order item is deleted, other item and hold remain.
5) Order new serial record, create subscription
a) From basket:
- delete order: works, record and subscription remain, OK!
- delete order and catalog record: not possible, OK!
b) From shipment/receive page:
- Cancel: Subscription and record are silently deleted. NOT OK.
6) Order additional item for existing record with other on order items
a) From basket:
- delete order: works, existing on order items remain, OK!
- delete order and catalog record: not possible, OK!
b) From shipment:
- Cancel: deletes order and ordered item. OK.
Changes made:
I changed the wording of the error messages a bit in the template.
I changed the message 'Can't delete order and catalog record' to not be
shown as a link, as the link does nothing. Tooltip still appears.
I attached a screenshot to the bug showing some of my changes.
Hope that's ok.
Necessary enhancements:
Cancelling orders when receiving items should work the same as from the
basket summary page. We need the same checks and messages there before
deleting records and items automatically.
I am signing off on this, but to go into Koha it needs a follow-up for the
order receive page.
Signed-off-by: Ian Walls <ian.walls@bywatersolutions.com>
Signed-off-by: Chris Cormack <chrisc@catalyst.net.nz>
Code written by Edgar Fuß <ef@math.uni-bonn.de>,
Mathematisches Institut der Uniersität Bonn
Signed-off-by: Katrin Fischer <Katrin.Fischer.83@web.de>
- rebased on current master, fixed a conflict in booksellers.pl
- reworked permission checks to account for general acq permissions and
superlibrarian permission
- rephrased text of system preference (Thx to Jared Camins-Esakov)
Signed-off-by: Nicole C. Engard <nengard@bywatersolutions.com>
Signed-off-by: Chris Cormack <chrisc@catalyst.net.nz>
Code written by Edgar Fuß <ef@math.uni-bonn.de>,
Mathematisches Institut der Uniersität Bonn
Signed-off-by: Katrin Fischer <Katrin.Fischer.83@web.de>
- rebased on current master, fixed a conflict in booksellers.pl
- reworked permission checks to account for general acq permissions and
superlibrarian permission
- rephrased text of system preference (Thx to Jared Camins-Esakov)
Signed-off-by: Nicole C. Engard <nengard@bywatersolutions.com>
Signed-off-by: Nicole C. Engard <nengard@bywatersolutions.com>
Signed-off-by: Ian Walls <ian.walls@bywatersolutions.com>
Signed-off-by: Chris Cormack <chrisc@catalyst.net.nz>
The total_est_gste or gsti is computed on the total_rrp_gste or gsti.
But in the budget this amount is the summ of discounts computed for each line.
Due to the rounding to 2 decimal places this produces a difference in Funds view with Total sublevels spent.
Signed-off-by: Paul Poulain <paul.poulain@biblibre.com>
Signed-off-by: Katrin Fischer <Katrin.Fischer.83@web.de>
Signed-off-by: Chris Cormack <chrisc@catalyst.net.nz>
when marcxml is wrong the PDF is not generated. There is a Perl error
because
the biblio can't be retrieved.
This can be workarounded with a eval when decoding the marc
Signed-off-by: Ian Walls <ian.walls@bywatersolutions.com>
Signed-off-by: Chris Cormack <chrisc@catalyst.net.nz>
Lines issued from a staged file have a flag that can be set when the order has
been added in a basket. It's set when a staged file is imported into the
catalogue, it should be set also when a record is inserted through aquisition.
Signed-off-by: Katrin Fischer <Katrin.Fischer.83@web.de>
- Add order from staged file to a new basket
- Add single order from one item
- Import rest using the bulk feature
- Staged file will no longer be shown after all titles
have been ordered and import_status in import_batches
is correctly set to 'imported'
Signed-off-by: Ian Walls <ian.walls@bywatersolutions.com>
Signed-off-by: Chris Cormack <chrisc@catalyst.net.nz>
Previously you couldn't view baskets that you hadn't created, unless you
were superlibrarian due to a bug. Now people with the right permissions
can see the baskets.
Applies to both 3.04.04 and master.
Signed-off-by: Brendan <info@bywatersolutions.com>
Signed-off-by: Melia Meggs <melia@bywatersolutions.com>
Signed-off-by: Chris Cormack <chrisc@catalyst.net.nz>
Scripts in admin & acqui subdirectores weren't passing t/00-testcritic.t. This
patch add admin & acqui scripts to test case and fix various errors related to
Perl::Critic compliancy.
- Fixing a style error to pass Perl::Critic, plus silencing a warn
- More style errors, plus fixing a security issue
- Explicitly using Carp
Contrary to common belief, subroutine prototypes do not enable
compile-time checks for proper arguments. Don't use them.
Defining a named sub within another sub, does not prevent that
subroutine being global
Signed-off-by: Frédéric Demians <frederic@tamil.fr>
Signed-off-by: Chris Cormack <chrisc@catalyst.net.nz>
This allows a basket to be searched for by name or invoice number from
anywhere in the acquisitions system. It is accessible by clicking on
"orders search", clicking the '[+]' and filling in the basket or invoice
no. fields.
Author: Srdjan Jankovic <srdjan@catalyst.net.nz>
Author: Robin Sheat <robin@catalyst.net.nz>
Signed-off-by: Nicole C. Engard <nengard@bywatersolutions.com>
Signed-off-by: Ian Walls <ian.walls@bywatersolutions.com>
Signed-off-by: Chris Cormack <chrisc@catalyst.net.nz>
As noted on bug 766 more cases of usage of
CGI::scrolling_list were imported into C4::Budgets
Even if we were not trying to remove usage of this
the C4 modules are not the place to generate markup
Most of these routines are noise as they are not used in
any current code but cause confusion and increase
maintenance overhead. They are removed
The sort dropboxes on order create are the only
references in current templates to these routines
they have been replaced by a select list generated
by the markup.
They can probably be removed too but their existence
although the option that causes them to be displayed
seems unlikely to be set. I've left them pending
resolution of some of the inconsistencies and
confusions surrounding Budgts
Signed-off-by: Chris Cormack <chris@bigballofwax.co.nz>
Signed-off-by: Paul Poulain <paul.poulain@biblibre.com>
Signed-off-by: Chris Cormack <chrisc@catalyst.net.nz>
On the basket editing screen, the links to add orders to a basket are
hidden unless a valid fund is available.
Signed-off-by: Katrin Fischer <Katrin.Fischer.83@web.de>
Signed-off-by: Paul Poulain <paul.poulain@biblibre.com>
Signed-off-by: Chris Cormack <chrisc@catalyst.net.nz>
This patch adds a new pref BasketConfirmations. This adds the option to skip
confirmations on closing and reopening a basket. If you skip the confirmation,
you do not create a new basket group.
The confusing line Create a purchase order (when closing a basket) is replaced
by Attach basket to a new basket group with the same name.
A warning for a null value on basketgroupid is fixed.
Rebased April 11.
Signed-off-by: Colin Campbell <colin.campbell@ptfs-europe.com>
Signed-off-by: Ian Walls <ian.walls@bywatersolutions.com>
Signed-off-by: Chris Cormack <chrisc@catalyst.net.nz>
For libraries with item-level_itype, the itemtype is in the item.
For others, it's in the biblio and should be added with the title/author when it's ordered
This patch adds the list when applicable,and build the biblio record accordingly
(BibLibre MT5189)
Signed-off-by: Chris Cormack <chrisc@catalyst.net.nz>
Signed-off-by: Ian Walls <ian.walls@bywatersolutions.com>
Replaces previous patch. Also fixes ordering from existing records.
While it was possible to go back to vendor and basket page when ordering
from a new suggestion the other odering options missed those 'crumbs'.
This patch makes the breadcrumbs for all orderings options consistent and
makes it possible to navigate back to the vendor or basket from all
pages.
- from existing record
- from staged record
- from external source
- from empty record
Signed-off-by: Nicole C. Engard <nengard@bywatersolutions.com>
Signed-off-by: Chris Cormack <chrisc@catalyst.net.nz>
creating a form order to import all records from a staged file at once.
All lines of the choosen staged file will be created with the same budget
and item (if applicable depending on AcqCreateItem syspref)
BibLibre bug #4007
Signed-off-by: Katrin Fischer <Katrin.Fischer.83@web.de>
Bug 5961: follow-up : use matchingrules selected in manage-stage-import instead of FindDuplicate
Now, bulk importing the iso2709 result in adding biblio or connecting to an existing one
Signed-off-by: Katrin Fischer <Katrin.Fischer.83@web.de>
BZ5961: follow-up, save currency
Cait noticed that currency was not saved properly in the aqorders table.
note a surprise, as the 3.2 had no currency feature and 5961 had been written against 3.2
anyway, this patch fixes the problem
Signed-off-by: Katrin Fischer <Katrin.Fischer.83@web.de>
Signed-off-by: Chris Cormack <chrisc@catalyst.net.nz>
Remove some unnecessary checks when check of error is
sufficient. Make the order in some cases more logical
Should remove some possibilities of runtime warning noise.
Although some calls belong to the 'Nothing could
ever go wrong' school have added some warnings
Signed-off-by: Christophe Croullebois <christophe.croullebois@biblibre.com>
Signed-off-by: Chris Cormack <chrisc@catalyst.net.nz>