working/NCIPServer.git
5 years agoFix an oops in NCIP::ILS::Evergreen.
Jason Stephenson [Tue, 6 Jan 2015 23:28:07 +0000 (18:28 -0500)]
Fix an oops in NCIP::ILS::Evergreen.

Forgot the service name on a simplereq call around line 800.

Signed-off-by: Jason Stephenson <jason@sigio.com>
5 years agoChanges to NCIP::ILS::Evergreen as a result of testing.
Jason Stephenson [Sat, 20 Dec 2014 20:59:38 +0000 (15:59 -0500)]
Changes to NCIP::ILS::Evergreen as a result of testing.

These modifications are based on testing with Auto-Graphics and
reflect how they say they will be sending data in production. They
will return the ItemId that we are now returning in the response
to RequestItem so we can use that to find the appropriate hold to
cancel.

The above necessitated some internal changes to the code that
amounted to a simplification of placing holds (in some cases) as
well as a simplification in canceling holds. There is still some
cruft hanging around that should probably go away, but I think
we're safe for now.

We've also update some templates to fix issues while testing the
above mentioned changes, specifically RequestItemResponse.inc and
CancelRequestItemResponse.inc.

Signed-off-by: Jason Stephenson <jason@sigio.com>
5 years agoModify NCIP::ILS::Evergreen->requestitem.
Jason Stephenson [Thu, 18 Dec 2014 19:58:16 +0000 (14:58 -0500)]
Modify NCIP::ILS::Evergreen->requestitem.

We now return AgencyId in the ItemId response field when returning a
database id and not barcode. If we can't figure out the AgencyId to
return, we set the ItemId/ItemIdentifierType to SYSNUMBER.

There's room for improvement here, but no time right now.

Signed-off-by: Jason Stephenson <jason@sigio.com>
5 years agoReceive or abort transit in NCIP::ILS::Evergreen->checkoutitem.
Jason Stephenson [Sat, 13 Dec 2014 21:57:31 +0000 (16:57 -0500)]
Receive or abort transit in NCIP::ILS::Evergreen->checkoutitem.

If the copy is in transit to or from the working organizational
unit of the NCIP staff user, then we have to either receive or
abort the transit before the check out can proceed.

Signed-off-by: Jason Stephenson <jason@sigio.com>
5 years agoChange CheckOutItemResponse.inc for whitespace.
Jason Stephenson [Fri, 12 Dec 2014 00:10:13 +0000 (19:10 -0500)]
Change CheckOutItemResponse.inc for whitespace.

Signed-off-by: Jason Stephenson <jason@sigio.com>
5 years agoFix another template typo.
Jason Stephenson [Thu, 11 Dec 2014 23:48:19 +0000 (18:48 -0500)]
Fix another template typo.

That's what happens when you make big changes in testing.

Signed-off-by: Jason Stephenson <jason@sigio.com>
5 years agoFix typo in UserId.in template include.
Jason Stephenson [Thu, 11 Dec 2014 20:43:57 +0000 (15:43 -0500)]
Fix typo in UserId.in template include.

Signed-off-by: Jason Stephenson <jason@sigio.com>
5 years agoAdd ItemId to RequestItem output in NCIP::ILS::Evergreen.
Jason Stephenson [Thu, 11 Dec 2014 02:39:36 +0000 (21:39 -0500)]
Add ItemId to RequestItem output in NCIP::ILS::Evergreen.

Signed-off-by: Jason Stephenson <jason@sigio.com>
5 years agoFixup RequestItemResponse template include file.
Jason Stephenson [Thu, 11 Dec 2014 02:13:59 +0000 (21:13 -0500)]
Fixup RequestItemResponse template include file.

Signed-off-by: Jason Stephenson <jason@sigio.com>
5 years agoReturn only 1 barcode for UserId in NCIP::ILS::Evergreen->lookupuser.
Jason Stephenson [Thu, 11 Dec 2014 00:14:13 +0000 (19:14 -0500)]
Return only 1 barcode for UserId in NCIP::ILS::Evergreen->lookupuser.

Signed-off-by: Jason Stephenson <jason@sigio.com>
5 years agoAlter the template includes so that fields are in xsd order.
Jason Stephenson [Thu, 11 Dec 2014 00:09:47 +0000 (19:09 -0500)]
Alter the template includes so that fields are in xsd order.

Signed-off-by: Jason Stephenson <jason@sigio.com>
5 years agoReturn the RequestId in the RequestItem message.
Jason Stephenson [Tue, 9 Dec 2014 23:33:39 +0000 (18:33 -0500)]
Return the RequestId in the RequestItem message.

Signed-off-by: Jason Stephenson <jason@sigio.com>
5 years ago"Fix" ItemOptionalFields.inc.
Jason Stephenson [Tue, 9 Dec 2014 01:20:27 +0000 (20:20 -0500)]
"Fix" ItemOptionalFields.inc.

Because Auto-Graphics has problems with "carriage returns."

Signed-off-by: Jason Stephenson <jason@sigio.com>
5 years agoFix another "typo/thinko" in NCIP::ILS::Evergreen.
Jason Stephenson [Tue, 9 Dec 2014 00:55:24 +0000 (19:55 -0500)]
Fix another "typo/thinko" in NCIP::ILS::Evergreen.

Missed the 't' on an aout retrieve and ended pulling out an ou,
instead.

Signed-off-by: Jason Stephenson <jason@sigio.com>
5 years agoFix a mistake in NCIP::ILS:Evergreen->find_target_via_bibliographic_id
Jason Stephenson [Tue, 9 Dec 2014 00:28:31 +0000 (19:28 -0500)]
Fix a mistake in NCIP::ILS:Evergreen->find_target_via_bibliographic_id

Signed-off-by: Jason Stephenson <jason@sigio.com>
5 years agoFix a typo on line 2790 of NCIP::ILS::Evergreen.
Jason Stephenson [Mon, 8 Dec 2014 23:28:33 +0000 (18:28 -0500)]
Fix a typo on line 2790 of NCIP::ILS::Evergreen.

Signed-off-by: Jason Stephenson <jason@sigio.com>
5 years agoModify NCIP::ILS::Evergreen based on communication and testing.
Jason Stephenson [Sat, 6 Dec 2014 18:14:07 +0000 (13:14 -0500)]
Modify NCIP::ILS::Evergreen based on communication and testing.

Auto-Graphics is sending our target branch code in the ToAgencyId
field of the InitiationHeader.  They are not sending some of the
optional fields that we are looking for.  Most of the changes in
this commit revolve around using the ToAgencyId as a fallback
when the other fields are not available.  The focus of these
changes are the AcceptItem and RequestItem messages since the
local location is most important there.

Signed-off-by: Jason Stephenson <jason@sigio.com>
5 years agoFix an inversion of author and title in NCIP::ILS::Evergreen->acceptitem.
Jason Stephenson [Fri, 5 Dec 2014 00:26:09 +0000 (19:26 -0500)]
Fix an inversion of author and title in NCIP::ILS::Evergreen->acceptitem.

Signed-off-by: Jason Stephenson <jason@sigio.com>
5 years agoAnother template change that was missed in the previous commit.
Jason Stephenson [Sun, 26 Oct 2014 20:20:30 +0000 (16:20 -0400)]
Another template change that was missed in the previous commit.

Signed-off-by: Jason Stephenson <jason@sigio.com>
5 years agoTemplates changes for Auto-graphics.
Jason Stephenson [Sun, 26 Oct 2014 19:27:14 +0000 (15:27 -0400)]
Templates changes for Auto-graphics.

They requested that we remove "carriage returns" from the output. I'm not
100% certain if he meant all carriage returns or if he just wanted the
weird spacing that some elements had where the open tag is on one line
followed by the value and the close tag on the next line. I don't really
know exactly why that was happening, but it seemed to have something to
do with trying to make the value come out on a line by its own between
the open and close tags. This change puts those elements on one line.

Signed-off-by: Jason Stephenson <jason@sigio.com>
5 years agoTry setting the configuration directory from environment again.
Jason Stephenson [Sun, 26 Oct 2014 17:27:59 +0000 (13:27 -0400)]
Try setting the configuration directory from environment again.

Signed-off-by: Jason Stephenson <jason@sigio.com>
5 years agoGet NCIP configuration directory from the environment.
Jason Stephenson [Sun, 26 Oct 2014 17:21:06 +0000 (13:21 -0400)]
Get NCIP configuration directory from the environment.

Signed-off-by: Jason Stephenson <jason@sigio.com>
5 years agoSet application/xml content type in NCIP::Dancing.
Jason Stephenson [Sun, 26 Oct 2014 17:14:26 +0000 (13:14 -0400)]
Set application/xml content type in NCIP::Dancing.

I tried setting the default in config.yml, and it did not work.

Signed-off-by: Jason Stephenson <jason@sigio.com>
6 years agoFix typo in previous commit.
Jason Stephenson [Sat, 25 Oct 2014 16:53:16 +0000 (12:53 -0400)]
Fix typo in previous commit.

Signed-off-by: Jason Stephenson <jason@sigio.com>
6 years agoAdd output of phone numbers in NCIP::ILS::Evergreen->lookupuser.
Jason Stephenson [Sat, 25 Oct 2014 16:48:33 +0000 (12:48 -0400)]
Add output of phone numbers in NCIP::ILS::Evergreen->lookupuser.

Signed-off-by: Jason Stephenson <jason@sigio.com>
6 years agoAdd NCIP::PhysicalAddress object.
Jason Stephenson [Fri, 24 Oct 2014 12:29:00 +0000 (08:29 -0400)]
Add NCIP::PhysicalAddress object.

I started to add this to the code last night to make addresses even
more abstract and extensible. Instead, I took a short cut. In the
light of the new day, I decided to go back and add this class as the
right thing to do.

We modify NCIP::ILS::Evergreen, NCIP::User::AddressInformation, and
the include for UserOptionalFields to make use of the new object.

Signed-off-by: Jason Stephenson <jason@sigio.com>
6 years agoGet rid of the namespace prefix in templates and includes.
Jason Stephenson [Fri, 24 Oct 2014 02:05:40 +0000 (22:05 -0400)]
Get rid of the namespace prefix in templates and includes.

Signed-off-by: Jason Stephenson <jason@sigio.com>
6 years agoMore fixes for includes/LookupUserResponse.inc.
Jason Stephenson [Fri, 24 Oct 2014 01:43:52 +0000 (21:43 -0400)]
More fixes for includes/LookupUserResponse.inc.

Signed-off-by: Jason Stephenson <jason@sigio.com>
6 years agoFixup a lot of stuff based on a first round of real testing.
Jason Stephenson [Fri, 24 Oct 2014 01:36:48 +0000 (21:36 -0400)]
Fixup a lot of stuff based on a first round of real testing.

Add ncip: namespace qualifier in templates and includes.

Reorder some fields because apparently the field order matters,
at least to xmllint when using the schema.

Make some code changes in NCIP::ILS::Evergreen to make sure that
date fields have the proper format. (This still needs testing, so
we'll see.)

Signed-off-by: Jason Stephenson <jason@sigio.com>
6 years agoFix response.tt and includes/data.inc issue.
Jason Stephenson [Thu, 23 Oct 2014 23:56:45 +0000 (19:56 -0400)]
Fix response.tt and includes/data.inc issue.

Signed-off-by: Jason Stephenson <jason@sigio.com>
6 years agoFix a case issue in NCIP::Const::AUTHENTICATIONINPUT_MESSAGES.
Jason Stephenson [Thu, 23 Oct 2014 23:13:15 +0000 (19:13 -0400)]
Fix a case issue in NCIP::Const::AUTHENTICATIONINPUT_MESSAGES.

We had LookUpUser and it should have been LookupUser.

Signed-off-by: Jason Stephenson <jason@sigio.com>
6 years agoFix a problem with acceptitem in NCIP::ILS::Evergreen.
Jason Stephenson [Tue, 14 Oct 2014 00:05:54 +0000 (20:05 -0400)]
Fix a problem with acceptitem in NCIP::ILS::Evergreen.

There was a logical error when checking RequestedActionType for
the "Hold For Pickup" action.

Signed-off-by: Jason Stephenson <jason@sigio.com>
6 years agoDo for renewitem what was done for checkoutitem in previous commit.
Jason Stephenson [Sat, 11 Oct 2014 20:32:37 +0000 (16:32 -0400)]
Do for renewitem what was done for checkoutitem in previous commit.

Signed-off-by: Jason Stephenson <jason@sigio.com>
6 years agoFix checkoutitem in NCIP::ILS::Evergreen.
Jason Stephenson [Sat, 11 Oct 2014 20:20:07 +0000 (16:20 -0400)]
Fix checkoutitem in NCIP::ILS::Evergreen.

Even though, the function documentation for checkout(.full) says
a copy object works, it apparently doesn't, so I switched to using
the copy_id parameter with $copy->id().

Signed-off-by: Jason Stephenson <jason@sigio.com>
6 years agoFix another typo in NCIP::ILS::Evergreen.
Jason Stephenson [Sat, 11 Oct 2014 18:32:53 +0000 (14:32 -0400)]
Fix another typo in NCIP::ILS::Evergreen.

Signed-off-by: Jason Stephenson <jason@sigio.com>
6 years agoFix something found by perl -c from the previous commit.
Jason Stephenson [Sat, 11 Oct 2014 18:30:25 +0000 (14:30 -0400)]
Fix something found by perl -c from the previous commit.

Signed-off-by: Jason Stephenson <jason@sigio.com>
6 years agoAdd find_copy_details_by_item to NCIP::ILS::Evergreen.
Jason Stephenson [Sat, 11 Oct 2014 18:28:53 +0000 (14:28 -0400)]
Add find_copy_details_by_item to NCIP::ILS::Evergreen.

Signed-off-by: Jason Stephenson <jason@sigio.com>
6 years agoMore Doh! type things in NCIP::ILS::Evergreen.
Jason Stephenson [Sat, 11 Oct 2014 17:45:09 +0000 (13:45 -0400)]
More Doh! type things in NCIP::ILS::Evergreen.

Signed-off-by: Jason Stephenson <jason@sigio.com>
6 years agoGet the pcrud method name correct.
Jason Stephenson [Sat, 11 Oct 2014 17:41:21 +0000 (13:41 -0400)]
Get the pcrud method name correct.

Signed-off-by: Jason Stephenson <jason@sigio.com>
6 years agoFix NCIP::ILS::Evergreen->place_hold.
Jason Stephenson [Sat, 11 Oct 2014 17:38:23 +0000 (13:38 -0400)]
Fix NCIP::ILS::Evergreen->place_hold.

We better take into account what open-ils.circ.holds.create returns.

We check for an array of errors and use the first one.

We also look up the hold for the id returned. I forgot that it only
returns the id and not the whole hold object created.

Signed-off-by: Jason Stephenson <jason@sigio.com>
6 years agoFix some warnings in NCIP::ILS::Evergreen.
Jason Stephenson [Sat, 11 Oct 2014 16:46:41 +0000 (12:46 -0400)]
Fix some warnings in NCIP::ILS::Evergreen.

Try to fix thes:

Use of uninitialized value in string eq at
/home/opensrf/NCIPServer/lib/NCIP/ILS/Evergreen.pm line 2553.
Use of uninitialized value in string eq at
/home/opensrf/NCIPServer/lib/NCIP/ILS/Evergreen.pm line 2589.

Signed-off-by: Jason Stephenson <jason@sigio.com>
6 years agoFix typo on line 2748 of NCIP::ILS::Evergreen.
Jason Stephenson [Sat, 11 Oct 2014 16:38:44 +0000 (12:38 -0400)]
Fix typo on line 2748 of NCIP::ILS::Evergreen.

Signed-off-by: Jason Stephenson <jason@sigio.com>
6 years agoFix some more stuff in NCIP::ILS::Evergreen.
Jason Stephenson [Sat, 11 Oct 2014 15:54:25 +0000 (11:54 -0400)]
Fix some more stuff in NCIP::ILS::Evergreen.

Running with perl -c caught another syntax error, and I saw that
I need hashrefs in a few places where I missed the {}.

Signed-off-by: Jason Stephenson <jason@sigio.com>
6 years agoFix some things caught by perl -c in NCIP::ILS::Evergreen.
Jason Stephenson [Sat, 11 Oct 2014 15:50:52 +0000 (11:50 -0400)]
Fix some things caught by perl -c in NCIP::ILS::Evergreen.

Signed-off-by: Jason Stephenson <jason@sigio.com>
6 years agoAdd handling of ItemElementType in NIP::ILS::Evergreen.
Jason Stephenson [Sat, 11 Oct 2014 15:45:52 +0000 (11:45 -0400)]
Add handling of ItemElementType in NIP::ILS::Evergreen.

This includes some template changes to output the ItemOptionalFields
element data.

Signed-off-by: Jason Stephenson <jason@sigio.com>
6 years agoFix typo on line 2380 of NCIP::ILS::Evergreen.
Jason Stephenson [Sun, 5 Oct 2014 16:18:34 +0000 (12:18 -0400)]
Fix typo on line 2380 of NCIP::ILS::Evergreen.

Signed-off-by: Jason Stephenson <jason@sigio.com>
6 years agoLast fix just gave us a different warning.
Jason Stephenson [Sun, 5 Oct 2014 16:14:25 +0000 (12:14 -0400)]
Last fix just gave us a different warning.

Try to fix it for real this time.

Signed-off-by: Jason Stephenson <jason@sigio.com>
6 years agoTry to fix a warning when checking penalties.
Jason Stephenson [Sun, 5 Oct 2014 16:10:55 +0000 (12:10 -0400)]
Try to fix a warning when checking penalties.

Use of uninitialized value in pattern match (m//) at
/home/opensrf/NCIPServer/lib/NCIP/ILS/Evergreen.pm line 1595.

Signed-off-by: Jason Stephenson <jason@sigio.com>
6 years agoFix typo in function name in NCIP::ILS::Evergreen.
Jason Stephenson [Sun, 5 Oct 2014 15:58:14 +0000 (11:58 -0400)]
Fix typo in function name in NCIP::ILS::Evergreen.

Signed-off-by: Jason Stephenson <jason@sigio.com>
6 years agoFix copy and paste problem with previous commit.
Jason Stephenson [Sun, 5 Oct 2014 14:59:31 +0000 (10:59 -0400)]
Fix copy and paste problem with previous commit.

Signed-off-by: Jason Stephenson <jason@sigio.com>
6 years agoAdd UserOptionalFields to more templates.
Jason Stephenson [Sun, 5 Oct 2014 14:56:38 +0000 (10:56 -0400)]
Add UserOptionalFields to more templates.

Also add checks for it in more messages for NCIP::ILS::Evergreen.

Signed-off-by: Jason Stephenson <jason@sigio.com>
6 years agoAdd NCIP::ILS::Evergreen->handle_user_elements for flexibility.
Jason Stephenson [Sun, 5 Oct 2014 14:26:32 +0000 (10:26 -0400)]
Add NCIP::ILS::Evergreen->handle_user_elements for flexibility.

Signed-off-by: Jason Stephenson <jason@sigio.com>
6 years agoAdd handling of NeedBeforeDate to NCIP::ILS::Evergreen->requestitem.
Jason Stephenson [Sun, 5 Oct 2014 14:02:35 +0000 (10:02 -0400)]
Add handling of NeedBeforeDate to NCIP::ILS::Evergreen->requestitem.

Signed-off-by: Jason Stephenson <jason@sigio.com>
6 years agoFix problems with _problem_from_event in NCIP::ILS::Evergreen.
Jason Stephenson [Thu, 2 Oct 2014 00:40:15 +0000 (20:40 -0400)]
Fix problems with _problem_from_event in NCIP::ILS::Evergreen.

Signed-off-by: Jason Stephenson <jason@sigio.com>
6 years agoFix mistake in NCIP::ILS::Evergreen on line 924.
Jason Stephenson [Thu, 2 Oct 2014 00:32:43 +0000 (20:32 -0400)]
Fix mistake in NCIP::ILS::Evergreen on line 924.

Signed-off-by: Jason Stephenson <jason@sigio.com>
6 years agoAlter NCIP::ILS::Evergreen->_hold_search() to do just one thing.
Jason Stephenson [Sun, 28 Sep 2014 14:29:39 +0000 (10:29 -0400)]
Alter NCIP::ILS::Evergreen->_hold_search() to do just one thing.

Remove the code that had it return a problem if no holds were
found and make it the caller's responsibility to check if a hold
was returned or nothing.

Signed-off-by: Jason Stephenson <jason@sigio.com>
6 years agoFix typos in NCIP::ILS::Evergreen caught by perl -c.
Jason Stephenson [Sun, 28 Sep 2014 14:22:28 +0000 (10:22 -0400)]
Fix typos in NCIP::ILS::Evergreen caught by perl -c.

Signed-off-by: Jason Stephenson <jason@sigio.com>
6 years agoAdd cancelrequestitem handler to NCIP::ILS::Evergreen.
Jason Stephenson [Sun, 28 Sep 2014 14:19:45 +0000 (10:19 -0400)]
Add cancelrequestitem handler to NCIP::ILS::Evergreen.

Also add the CancelRequestItemResponse.inc to the templates.

Signed-off-by: Jason Stephenson <jason@sigio.com>
6 years agoMore NCIP::ILS::Evergreen->requestitem() improvements.
Jason Stephenson [Sat, 27 Sep 2014 16:51:18 +0000 (12:51 -0400)]
More NCIP::ILS::Evergreen->requestitem() improvements.

We check if item is a NCIP::Problem and return it if it is.

Signed-off-by: Jason Stephenson <jason@sigio.com>
6 years agoFix a comment typo in NCIP::ILS::Evergreen.
Jason Stephenson [Sat, 27 Sep 2014 16:11:47 +0000 (12:11 -0400)]
Fix a comment typo in NCIP::ILS::Evergreen.

Signed-off-by: Jason Stephenson <jason@sigio.com>
6 years agoModify NCIP::ILS::Evergreen->requestitem to try a little harder.
Jason Stephenson [Sat, 27 Sep 2014 15:07:03 +0000 (11:07 -0400)]
Modify NCIP::ILS::Evergreen->requestitem to try a little harder.

Signed-off-by: Jason Stephenson <jason@sigio.com>
6 years agoSimplify NCIP::ILS::Evergreen->retrieve_org_unit_by_shortname().
Jason Stephenson [Sat, 27 Sep 2014 13:58:08 +0000 (09:58 -0400)]
Simplify NCIP::ILS::Evergreen->retrieve_org_unit_by_shortname().

Use open-ils.actor.org_unit.retrieve_by_shortname instead of a
pcrud search.

Signed-off-by: Jason Stephenson <jason@sigio.com>
6 years agoFix a little something caught by perl -c.
Jason Stephenson [Sat, 27 Sep 2014 12:37:29 +0000 (08:37 -0400)]
Fix a little something caught by perl -c.

Signed-off-by: Jason Stephenson <jason@sigio.com>
6 years agoAlter find_bibliograpic_id to find_biblioraphic_ids in NCIP::ILS.
Jason Stephenson [Sat, 27 Sep 2014 12:35:26 +0000 (08:35 -0400)]
Alter find_bibliograpic_id to find_biblioraphic_ids in NCIP::ILS.

Signed-off-by: Jason Stephenson <jason@sigio.com>
6 years agoAdd duplicate request check to NCIP::ILS::Evergreen->requestitem
Jason Stephenson [Tue, 23 Sep 2014 01:51:29 +0000 (21:51 -0400)]
Add duplicate request check to NCIP::ILS::Evergreen->requestitem

Signed-off-by: Jason Stephenson <jason@sigio.com>
6 years agoFix a typo in previous commit.
Jason Stephenson [Mon, 22 Sep 2014 19:44:30 +0000 (15:44 -0400)]
Fix a typo in previous commit.

Signed-off-by: Jason Stephenson <jason@sigio.com>
6 years agoAdd RequestItem support to NCIP::ILS::Evergreen.
Jason Stephenson [Mon, 22 Sep 2014 19:43:15 +0000 (15:43 -0400)]
Add RequestItem support to NCIP::ILS::Evergreen.

Signed-off-by: Jason Stephenson <jason@sigio.com>
6 years agoFix typo in previous commit: $enty for $entry.
Jason Stephenson [Mon, 22 Sep 2014 18:35:16 +0000 (14:35 -0400)]
Fix typo in previous commit: $enty for $entry.

Signed-off-by: Jason Stephenson <jason@sigio.com>
6 years agoAdd $code option to NCIP::ILS->find_bibliographic_id.
Jason Stephenson [Mon, 22 Sep 2014 18:32:34 +0000 (14:32 -0400)]
Add $code option to NCIP::ILS->find_bibliographic_id.

I wonder now, if I should not have overriden the method in the
Evergreen driver, but I thought this would be generically useful.

We will probably want a method that can return all of the IDs at
some point, but for now, any subclasses that need that, can
implement it, themselves.

Signed-off-by: Jason Stephenson <jason@sigio.com>
6 years agoFix typo in NCIP::ILS::Evergreen.
Jason Stephenson [Mon, 22 Sep 2014 17:24:51 +0000 (13:24 -0400)]
Fix typo in NCIP::ILS::Evergreen.

Signed-off-by: Jason Stephenson <jason@sigio.com>
6 years agoCheck for repeated BibliographId in NCIP::ILS->find_bibliographic_id.
Jason Stephenson [Mon, 22 Sep 2014 17:20:57 +0000 (13:20 -0400)]
Check for repeated BibliographId in NCIP::ILS->find_bibliographic_id.

Signed-off-by: Jason Stephenson <jason@sigio.com>
6 years agoFix typo in find_bibliographic_id in NCIP::ILS.
Jason Stephenson [Mon, 22 Sep 2014 15:01:36 +0000 (11:01 -0400)]
Fix typo in find_bibliographic_id in NCIP::ILS.

Signed-off-by: Jason Stephenson <jason@sigio.com>
6 years agoImprove find_bibliographic_id in NCIP::ILS.
Jason Stephenson [Mon, 22 Sep 2014 14:45:27 +0000 (10:45 -0400)]
Improve find_bibliographic_id in NCIP::ILS.

Add a check for BibligraphicDescription under ItemOptionalFields.

Signed-off-by: Jason Stephenson <jason@sigio.com>
6 years agoAdd find_bibliographic_id to NCIP::ILS.
Jason Stephenson [Mon, 22 Sep 2014 14:28:29 +0000 (10:28 -0400)]
Add find_bibliographic_id to NCIP::ILS.

Signed-off-by: Jason Stephenson <jason@sigio.com>
6 years agoImprove comments in NCIP::ILS.
Jason Stephenson [Mon, 22 Sep 2014 13:58:32 +0000 (09:58 -0400)]
Improve comments in NCIP::ILS.

Add an array example to find_user_barcode and find_item_barcode.

Signed-off-by: Jason Stephenson <jason@sigio.com>
6 years agoUpdate the CheckOutItemResponse.inc template file.
Jason Stephenson [Sun, 21 Sep 2014 19:39:53 +0000 (15:39 -0400)]
Update the CheckOutItemResponse.inc template file.

Signed-off-by: Jason Stephenson <jason@sigio.com>
6 years agoAdd checkoutitem to NCIP::ILS::Evergreen.
Jason Stephenson [Sun, 21 Sep 2014 19:26:10 +0000 (15:26 -0400)]
Add checkoutitem to NCIP::ILS::Evergreen.

Also add a couple of utility methods to check if a copy is allowed
to circulate and fill holds, as well as one to retrieve a copy
location object by id.

Signed-off-by: Jason Stephenson <jason@sigio.com>
6 years agoSimplify delete_copy in NCIP::ILS::Evergreen.
Jason Stephenson [Fri, 19 Sep 2014 12:46:07 +0000 (08:46 -0400)]
Simplify delete_copy in NCIP::ILS::Evergreen.

Signed-off-by: Jason Stephenson <jason@sigio.com>
6 years agoBump _problem_from_event's IQ by a couple of points.
Jason Stephenson [Sun, 14 Sep 2014 22:22:47 +0000 (18:22 -0400)]
Bump _problem_from_event's IQ by a couple of points.

Signed-off-by: Jason Stephenson <jason@sigio.com>
6 years agoAdd some "smarts" to _problem_from_event in NCIP::ILS::Evergreen.
Jason Stephenson [Sun, 14 Sep 2014 21:49:41 +0000 (17:49 -0400)]
Add some "smarts" to _problem_from_event in NCIP::ILS::Evergreen.

Signed-off-by: Jason Stephenson <jason@sigio.com>
6 years agoFix text_code for textcode typo in NCIP::ILS::Evergreen.
Jason Stephenson [Sun, 14 Sep 2014 20:51:34 +0000 (16:51 -0400)]
Fix text_code for textcode typo in NCIP::ILS::Evergreen.

Signed-off-by: Jason Stephenson <jason@sigio.com>
6 years agoFix set_timezone to set_time_zone in NCIP::ILS::Evergreen->renewitem.
Jason Stephenson [Sun, 14 Sep 2014 19:57:29 +0000 (15:57 -0400)]
Fix set_timezone to set_time_zone in NCIP::ILS::Evergreen->renewitem.

Signed-off-by: Jason Stephenson <jason@sigio.com>
6 years agoAdd AuthenticationInput checks for more messages in NCIP::ILS.
Jason Stephenson [Sun, 14 Sep 2014 17:45:35 +0000 (13:45 -0400)]
Add AuthenticationInput checks for more messages in NCIP::ILS.

We add the AUTHENTICATIONINPUT_MESSAGES constant to hold a list of
messages that may have AuthenticationInput set, and then we check
if our message is in the list when trying to find a user barcode
and the UserId field was not present.

Signed-off-by: Jason Stephenson <jason@sigio.com>
6 years agoUserId does not repeat if present in a message.
Jason Stephenson [Sun, 14 Sep 2014 17:30:59 +0000 (13:30 -0400)]
UserId does not repeat if present in a message.

Alter NCIP::ILS->find_user_barcode() to not make an array ref out
of UserId inputs. It is not supposed to repeat.

Signed-off-by: Jason Stephenson <jason@sigio.com>
6 years agoAdd error checking to NCIP::ILS::Evergreen->checkinitem().
Jason Stephenson [Sun, 14 Sep 2014 17:14:02 +0000 (13:14 -0400)]
Add error checking to NCIP::ILS::Evergreen->checkinitem().

Signed-off-by: Jason Stephenson <jason@sigio.com>
6 years agoAdd RenewItem support for NCIP::ILS::Evergreen.
Jason Stephenson [Sun, 14 Sep 2014 17:07:54 +0000 (13:07 -0400)]
Add RenewItem support for NCIP::ILS::Evergreen.

Signed-off-by: Jason Stephenson <jason@sigio.com>
6 years agoFix typo in NCIP::ILS::Evergreen->checkinitem().
Jason Stephenson [Sun, 14 Sep 2014 15:39:05 +0000 (11:39 -0400)]
Fix typo in NCIP::ILS::Evergreen->checkinitem().

Signed-off-by: Jason Stephenson <jason@sigio.com>
6 years agoFix some things in NCIP::ILS::Evergreen picked up by perl -c.
Jason Stephenson [Sun, 14 Sep 2014 14:44:55 +0000 (10:44 -0400)]
Fix some things in NCIP::ILS::Evergreen picked up by perl -c.

Signed-off-by: Jason Stephenson <jason@sigio.com>
6 years agoMove circulation, copy and user checks to check_circ_details method.
Jason Stephenson [Sun, 14 Sep 2014 14:19:54 +0000 (10:19 -0400)]
Move circulation, copy and user checks to check_circ_details method.

Before implementing renewitem in NCIP::ILS::Evergreen, it became
apparent that we'd want to make the same checks for the copy being
checked out, owned by or checked out at our working ou, and being
checked out to the provided user, if any, before proceeding with
renewal. It makes sense therefore to move the checks from being
inside checkinitem to being its own function that returns a
NCIP::Problem or undef.

Signed-off-by: Jason Stephenson <jason@sigio.com>
6 years agoAdd check for more copies in NCIP::ILS::Evergreen->delete_copy.
Jason Stephenson [Sun, 14 Sep 2014 03:54:50 +0000 (23:54 -0400)]
Add check for more copies in NCIP::ILS::Evergreen->delete_copy.

We now check if there are other copies on the call number before
we delete it.

We also fix a thinko when we were checking for additional call
numbers on the bib. We had map where we needed grep.

Signed-off-by: Jason Stephenson <jason@sigio.com>
6 years agoDeflesh copy->call_number in NCIP::ILS::Evergreen->delete_copy.
Jason Stephenson [Sat, 13 Sep 2014 18:49:43 +0000 (14:49 -0400)]
Deflesh copy->call_number in NCIP::ILS::Evergreen->delete_copy.

To keep things simple, we deflesh the call number of the copy to
be deleted, if it was fleshed earlier, which it was likely to be.

Signed-off-by: Jason Stephenson <jason@sigio.com>
6 years agoAdd check for other volumes before delete a bib.
Jason Stephenson [Sat, 13 Sep 2014 17:47:02 +0000 (13:47 -0400)]
Add check for other volumes before delete a bib.

Modify NCIP::ILS::Evergreen->delete_copy() to check for call numbers
other than the one already being deleted on a bib prior to deleting
that bib. If there are other call numbers that are not themselves
deleted, then we do not delete the bib.

Signed-off-by: Jason Stephenson <jason@sigio.com>
6 years agoAdd use_force_holds config option for NCIP::ILS::Evergreen.
Jason Stephenson [Sat, 13 Sep 2014 15:40:41 +0000 (11:40 -0400)]
Add use_force_holds config option for NCIP::ILS::Evergreen.

Signed-off-by: Jason Stephenson <jason@sigio.com>
6 years agoFix a problem detected by perl -c....
Jason Stephenson [Sat, 13 Sep 2014 15:11:25 +0000 (11:11 -0400)]
Fix a problem detected by perl -c....

Signed-off-by: Jason Stephenson <jason@sigio.com>
6 years agoAdd NCIP::ILS::Evergreen->delete_copy().
Jason Stephenson [Sat, 13 Sep 2014 15:08:33 +0000 (11:08 -0400)]
Add NCIP::ILS::Evergreen->delete_copy().

Call it from the checkinitem handler.

Also adjust some variable names in checkinitem handler so that they
make more sense.

Signed-off-by: Jason Stephenson <jason@sigio.com>
6 years agoAdd the UserId check in checkinitem in NCIP::ILS::Evergreen.
Jason Stephenson [Fri, 12 Sep 2014 12:59:50 +0000 (08:59 -0400)]
Add the UserId check in checkinitem in NCIP::ILS::Evergreen.

We check if the UserId is supplied in the request that it matches
the user who has the copy checked out. If not, we return a problem.

Also fix a copy/paste-o with item barcodes in a couple of Problem
constructors.

Signed-off-by: Jason Stephenson <jason@sigio.com>
6 years agoAdd additional ownership check in NCIP::ILS::Evergreen->checkinitem.
Jason Stephenson [Fri, 12 Sep 2014 12:42:15 +0000 (08:42 -0400)]
Add additional ownership check in NCIP::ILS::Evergreen->checkinitem.

We make sure the NCIP staff user's work org. unit either owns the
copy to be checked in or it was checked out there.

Signed-off-by: Jason Stephenson <jason@sigio.com>
6 years agoAdd CheckInItem support to NCIP::ILS::Evergreen.
Jason Stephenson [Fri, 12 Sep 2014 02:00:04 +0000 (22:00 -0400)]
Add CheckInItem support to NCIP::ILS::Evergreen.

Add the basic checkinitem handler method.

Also add a retrieve_user_by_id method, and change the name of
retrieve_copy_by_barcode to retrieve_copy_details_by_barcode to
better reflect what it actually does.

Signed-off-by: Jason Stephenson <jason@sigio.com>
6 years agoFix a mistake in AcceptItemResponse.inc.
Jason Stephenson [Fri, 12 Sep 2014 01:49:55 +0000 (21:49 -0400)]
Fix a mistake in AcceptItemResponse.inc.

Signed-off-by: Jason Stephenson <jason@sigio.com>
6 years agoFix ProblemDescription for ProblemDetail in NCIP::ILS::Evergreen.
Jason Stephenson [Wed, 10 Sep 2014 12:37:22 +0000 (08:37 -0400)]
Fix ProblemDescription for ProblemDetail in NCIP::ILS::Evergreen.

This fixes a mistake in acceptitem when returning a Duplicate Item
problem. The ProblemDetail didn't show up in the response because
the constructor erroneously set ProblemDescription instead of
ProblemDetail.

Signed-off-by: Jason Stephenson <jason@sigio.com>