From: Chris Cormack Date: Sun, 13 Jul 2014 22:19:10 +0000 (+1200) Subject: Working on the CheckOutIthem handler X-Git-Url: https://old-git.evergreen-ils.org/?a=commitdiff_plain;h=cdc57de944aabf2bf3a83380134f786d1991947f;p=NCIPServer.git Working on the CheckOutIthem handler --- diff --git a/lib/NCIP/Handler/CheckOutItem.pm b/lib/NCIP/Handler/CheckOutItem.pm index 9e141b9..e6e9e34 100644 --- a/lib/NCIP/Handler/CheckOutItem.pm +++ b/lib/NCIP/Handler/CheckOutItem.pm @@ -24,14 +24,13 @@ sub handle { my $xmldoc = shift; if ($xmldoc) { my $root = $xmldoc->documentElement(); - my $xpc = XML::LibXML::XPathContext->new; - $xpc->registerNs( 'ns', $self->namespace() ); + my $xpc = $self->xpc(); my $userid = - $xpc->findnodes( 'ns:CheckOutItem/UniqueUserId/UserIdentifierValue', + $xpc->findnodes( '//ns:UserIdentifierValue', $root ); my $itemid = - $xpc->findnodes( 'ns:CheckOutItem/UniqueItemId/ItemIdentifierValue', + $xpc->findnodes( '//ns:ItemIdentifierValue', $root ); # checkout the item