Lines 35-40
use Koha::UploadedFiles;
Link Here
|
35 |
use Koha::Account; |
35 |
use Koha::Account; |
36 |
use Koha::Checkouts; |
36 |
use Koha::Checkouts; |
37 |
use Koha::Patrons; |
37 |
use Koha::Patrons; |
|
|
38 |
use Koha::Plugins; |
38 |
|
39 |
|
39 |
use Date::Calc qw( Date_to_Days ); |
40 |
use Date::Calc qw( Date_to_Days ); |
40 |
|
41 |
|
Lines 243-248
sub kocIssueItem {
Link Here
|
243 |
my $circ = shift; |
244 |
my $circ = shift; |
244 |
|
245 |
|
245 |
$circ->{ 'barcode' } = barcodedecode($circ->{'barcode'}) if( $circ->{'barcode'} && C4::Context->preference('itemBarcodeInputFilter')); |
246 |
$circ->{ 'barcode' } = barcodedecode($circ->{'barcode'}) if( $circ->{'barcode'} && C4::Context->preference('itemBarcodeInputFilter')); |
|
|
247 |
|
248 |
my ( $new_barcode ) = Koha::Plugins->call( 'barcode_transform', 'item', $circ->{barcode} ) || $circ->{barcode}; |
249 |
$circ->{barcode} = $new_barcode; |
250 |
|
246 |
my $branchcode = C4::Context->userenv->{branch}; |
251 |
my $branchcode = C4::Context->userenv->{branch}; |
247 |
my $patron = Koha::Patrons->find( { cardnumber => $circ->{cardnumber} } ); |
252 |
my $patron = Koha::Patrons->find( { cardnumber => $circ->{cardnumber} } ); |
248 |
my $borrower = $patron->unblessed; |
253 |
my $borrower = $patron->unblessed; |
Lines 323-328
sub kocIssueItem {
Link Here
|
323 |
sub kocReturnItem { |
328 |
sub kocReturnItem { |
324 |
my ( $circ ) = @_; |
329 |
my ( $circ ) = @_; |
325 |
$circ->{'barcode'} = barcodedecode($circ->{'barcode'}) if( $circ->{'barcode'} && C4::Context->preference('itemBarcodeInputFilter')); |
330 |
$circ->{'barcode'} = barcodedecode($circ->{'barcode'}) if( $circ->{'barcode'} && C4::Context->preference('itemBarcodeInputFilter')); |
|
|
331 |
|
332 |
my ( $new_barcode ) = Koha::Plugins->call( 'barcode_transform', 'item', $circ->{barcode} ) || $circ->{barcode}; |
333 |
$circ->{barcode} = $new_barcode; |
334 |
|
326 |
my $item = Koha::Items->find({ barcode => $circ->{barcode} }); |
335 |
my $item = Koha::Items->find({ barcode => $circ->{barcode} }); |
327 |
my $biblio = $item->biblio; |
336 |
my $biblio = $item->biblio; |
328 |
my $borrowernumber = _get_borrowernumber_from_barcode( $circ->{'barcode'} ); |
337 |
my $borrowernumber = _get_borrowernumber_from_barcode( $circ->{'barcode'} ); |