View | Details | Raw Unified | Return to bug 5337
Collapse All | Expand All

(-)a/C4/Acquisition.pm (-9 / +17 lines)
Lines 1159-1165 C<@results> is an array of references-to-hash with the following keys: Link Here
1159
1159
1160
sub SearchOrder {
1160
sub SearchOrder {
1161
#### -------- SearchOrder-------------------------------
1161
#### -------- SearchOrder-------------------------------
1162
    my ($ordernumber, $search, $supplierid, $basket) = @_;
1162
    my ( $ordernumber, $search, $ean, $supplierid, $basket ) = @_;
1163
1163
1164
    my $dbh = C4::Context->dbh;
1164
    my $dbh = C4::Context->dbh;
1165
    my @args = ();
1165
    my @args = ();
Lines 1179-1185 sub SearchOrder { Link Here
1179
        $query .= " AND (biblio.title like ? OR biblio.author LIKE ? OR biblioitems.isbn like ?)";
1179
        $query .= " AND (biblio.title like ? OR biblio.author LIKE ? OR biblioitems.isbn like ?)";
1180
        push @args, ("%$search%","%$search%","%$search%");
1180
        push @args, ("%$search%","%$search%","%$search%");
1181
    }
1181
    }
1182
    if($supplierid){
1182
    if ($ean) {
1183
        $query .= " AND biblioitems.ean = ?";
1184
        push @args, $ean;
1185
    }
1186
    if ($supplierid) {
1183
        $query .= "AND aqbasket.booksellerid = ?";
1187
        $query .= "AND aqbasket.booksellerid = ?";
1184
        push @args, $supplierid;
1188
        push @args, $supplierid;
1185
    }
1189
    }
Lines 1533-1544 sub GetHistory { Link Here
1533
    my $title = $params{title};
1537
    my $title = $params{title};
1534
    my $author = $params{author};
1538
    my $author = $params{author};
1535
    my $isbn   = $params{isbn};
1539
    my $isbn   = $params{isbn};
1540
    my $ean    = $params{ean};
1536
    my $name = $params{name};
1541
    my $name = $params{name};
1537
    my $from_placed_on = $params{from_placed_on};
1542
    my $from_placed_on = $params{from_placed_on};
1538
    my $to_placed_on = $params{to_placed_on};
1543
    my $to_placed_on = $params{to_placed_on};
1539
    my $basket = $params{basket};
1544
    my $basket = $params{basket};
1540
    my $booksellerinvoicenumber = $params{booksellerinvoicenumber};
1545
    my $booksellerinvoicenumber = $params{booksellerinvoicenumber};
1541
1542
    my @order_loop;
1546
    my @order_loop;
1543
    my $total_qty         = 0;
1547
    my $total_qty         = 0;
1544
    my $total_qtyreceived = 0;
1548
    my $total_qtyreceived = 0;
Lines 1550-1561 sub GetHistory { Link Here
1550
            biblio.title,
1554
            biblio.title,
1551
            biblio.author,
1555
            biblio.author,
1552
	    biblioitems.isbn,
1556
	    biblioitems.isbn,
1557
	    biblioitems.ean,
1553
            aqorders.basketno,
1558
            aqorders.basketno,
1554
    aqbasket.basketname,
1559
            aqbasket.basketname,
1555
    aqbasket.basketgroupid,
1560
            aqbasket.basketgroupid,
1556
    aqbasketgroups.name as groupname,
1561
            aqbasketgroups.name as groupname,
1557
            aqbooksellers.name,
1562
            aqbooksellers.name,
1558
    aqbasket.creationdate,
1563
            aqbasket.creationdate,
1559
            aqorders.datereceived,
1564
            aqorders.datereceived,
1560
            aqorders.quantity,
1565
            aqorders.quantity,
1561
            aqorders.quantityreceived,
1566
            aqorders.quantityreceived,
Lines 1566-1572 sub GetHistory { Link Here
1566
            aqorders.biblionumber
1571
            aqorders.biblionumber
1567
        FROM aqorders
1572
        FROM aqorders
1568
        LEFT JOIN aqbasket ON aqorders.basketno=aqbasket.basketno
1573
        LEFT JOIN aqbasket ON aqorders.basketno=aqbasket.basketno
1569
    LEFT JOIN aqbasketgroups ON aqbasket.basketgroupid=aqbasketgroups.id
1574
        LEFT JOIN aqbasketgroups ON aqbasket.basketgroupid=aqbasketgroups.id
1570
        LEFT JOIN aqbooksellers ON aqbasket.booksellerid=aqbooksellers.id
1575
        LEFT JOIN aqbooksellers ON aqbasket.booksellerid=aqbooksellers.id
1571
	LEFT JOIN biblioitems ON biblioitems.biblionumber=aqorders.biblionumber
1576
	LEFT JOIN biblioitems ON biblioitems.biblionumber=aqorders.biblionumber
1572
        LEFT JOIN biblio ON biblio.biblionumber=aqorders.biblionumber";
1577
        LEFT JOIN biblio ON biblio.biblionumber=aqorders.biblionumber";
Lines 1593-1599 sub GetHistory { Link Here
1593
        $query .= " AND biblioitems.isbn LIKE ? ";
1598
        $query .= " AND biblioitems.isbn LIKE ? ";
1594
        push @query_params, "%$isbn%";
1599
        push @query_params, "%$isbn%";
1595
    }
1600
    }
1596
1601
    if ( defined $ean and $ean ) {
1602
        $query .= " AND biblioitems.ean = ? ";
1603
        push @query_params, "$ean";
1604
    }
1597
    if ( $name ) {
1605
    if ( $name ) {
1598
        $query .= " AND aqbooksellers.name LIKE ? ";
1606
        $query .= " AND aqbooksellers.name LIKE ? ";
1599
        push @query_params, "%$name%";
1607
        push @query_params, "%$name%";
(-)a/C4/Biblio.pm (-3 / +6 lines)
Lines 3394-3400 sub _koha_modify_biblioitem_nonmarc { Link Here
3394
        cn_item         = ?,
3394
        cn_item         = ?,
3395
        cn_suffix       = ?,
3395
        cn_suffix       = ?,
3396
        cn_sort         = ?,
3396
        cn_sort         = ?,
3397
        totalissues     = ?
3397
        totalissues     = ?,
3398
	ean             = ?
3398
        where biblioitemnumber = ?
3399
        where biblioitemnumber = ?
3399
        ";
3400
        ";
3400
    my $sth = $dbh->prepare($query);
3401
    my $sth = $dbh->prepare($query);
Lines 3406-3411 sub _koha_modify_biblioitem_nonmarc { Link Here
3406
        $biblioitem->{'pages'},            $biblioitem->{'bnotes'},           $biblioitem->{'size'},                  $biblioitem->{'place'},
3407
        $biblioitem->{'pages'},            $biblioitem->{'bnotes'},           $biblioitem->{'size'},                  $biblioitem->{'place'},
3407
        $biblioitem->{'lccn'},             $biblioitem->{'url'},              $biblioitem->{'biblioitems.cn_source'}, $biblioitem->{'cn_class'},
3408
        $biblioitem->{'lccn'},             $biblioitem->{'url'},              $biblioitem->{'biblioitems.cn_source'}, $biblioitem->{'cn_class'},
3408
        $biblioitem->{'cn_item'},          $biblioitem->{'cn_suffix'},        $cn_sort,                               $biblioitem->{'totalissues'},
3409
        $biblioitem->{'cn_item'},          $biblioitem->{'cn_suffix'},        $cn_sort,                               $biblioitem->{'totalissues'},
3410
	$biblioitem->{'ean'},
3409
        $biblioitem->{'biblioitemnumber'}
3411
        $biblioitem->{'biblioitemnumber'}
3410
    );
3412
    );
3411
    if ( $dbh->errstr ) {
3413
    if ( $dbh->errstr ) {
Lines 3457-3463 sub _koha_add_biblioitem { Link Here
3457
        cn_item         = ?,
3459
        cn_item         = ?,
3458
        cn_suffix       = ?,
3460
        cn_suffix       = ?,
3459
        cn_sort         = ?,
3461
        cn_sort         = ?,
3460
        totalissues     = ?
3462
        totalissues     = ?,
3463
	ean             = ?
3461
        ";
3464
        ";
3462
    my $sth = $dbh->prepare($query);
3465
    my $sth = $dbh->prepare($query);
3463
    $sth->execute(
3466
    $sth->execute(
Lines 3468-3474 sub _koha_add_biblioitem { Link Here
3468
        $biblioitem->{'pages'},            $biblioitem->{'bnotes'},           $biblioitem->{'size'},                  $biblioitem->{'place'},
3471
        $biblioitem->{'pages'},            $biblioitem->{'bnotes'},           $biblioitem->{'size'},                  $biblioitem->{'place'},
3469
        $biblioitem->{'lccn'},             $biblioitem->{'marc'},             $biblioitem->{'url'},                   $biblioitem->{'biblioitems.cn_source'},
3472
        $biblioitem->{'lccn'},             $biblioitem->{'marc'},             $biblioitem->{'url'},                   $biblioitem->{'biblioitems.cn_source'},
3470
        $biblioitem->{'cn_class'},         $biblioitem->{'cn_item'},          $biblioitem->{'cn_suffix'},             $cn_sort,
3473
        $biblioitem->{'cn_class'},         $biblioitem->{'cn_item'},          $biblioitem->{'cn_suffix'},             $cn_sort,
3471
        $biblioitem->{'totalissues'}
3474
        $biblioitem->{'totalissues'},      $biblioitem->{'ean'}
3472
    );
3475
    );
3473
    my $bibitemnum = $dbh->{'mysql_insertid'};
3476
    my $bibitemnum = $dbh->{'mysql_insertid'};
3474
3477
(-)a/C4/Serials.pm (-3 / +18 lines)
Lines 551-565 sub GetFullSubscriptionsFromBiblionumber { Link Here
551
551
552
=head2 GetSubscriptions
552
=head2 GetSubscriptions
553
553
554
@results = GetSubscriptions($title,$ISSN,$biblionumber);
554
@results = GetSubscriptions($title,$ISSN,$ean,$biblionumber);
555
this function gets all subscriptions which have title like $title,ISSN like $ISSN and biblionumber like $biblionumber.
555
this function gets all subscriptions which have title like $title,ISSN like $ISSN,EAN like $ean and biblionumber like $biblionumber.
556
return:
556
return:
557
a table of hashref. Each hash containt the subscription.
557
a table of hashref. Each hash containt the subscription.
558
558
559
=cut
559
=cut
560
560
561
sub GetSubscriptions {
561
sub GetSubscriptions {
562
    my ( $string, $issn, $biblionumber ) = @_;
562
    my ( $string, $issn, $ean, $biblionumber ) = @_;
563
563
564
    #return unless $title or $ISSN or $biblionumber;
564
    #return unless $title or $ISSN or $biblionumber;
565
    my $dbh = C4::Context->dbh;
565
    my $dbh = C4::Context->dbh;
Lines 603-612 sub GetSubscriptions { Link Here
603
        }
603
        }
604
        $sqlwhere .= ( $sqlwhere ? " AND " : " WHERE " ) . "((" . join( ") OR (", @sqlstrings ) . "))";
604
        $sqlwhere .= ( $sqlwhere ? " AND " : " WHERE " ) . "((" . join( ") OR (", @sqlstrings ) . "))";
605
    }
605
    }
606
    if ($ean) {
607
        my @sqlstrings;
608
        my @strings_to_search;
609
        @strings_to_search = map { "$_" } split( / /, $ean );
610
        foreach my $index qw(biblioitems.ean) {
611
            push @bind_params, @strings_to_search;
612
            my $tmpstring = "OR $index = ? " x scalar(@strings_to_search);
613
            $debug && warn "$tmpstring";
614
            $tmpstring =~ s/^OR //;
615
            push @sqlstrings, $tmpstring;
616
        }
617
        $sqlwhere .= ( $sqlwhere ? " AND " : " WHERE " ) . "(" . join( ") OR (", @sqlstrings ) . ")";
618
    }
619
606
    $sql .= "$sqlwhere ORDER BY title";
620
    $sql .= "$sqlwhere ORDER BY title";
607
    $debug and warn "GetSubscriptions query: $sql params : ", join( " ", @bind_params );
621
    $debug and warn "GetSubscriptions query: $sql params : ", join( " ", @bind_params );
608
    $sth = $dbh->prepare($sql);
622
    $sth = $dbh->prepare($sql);
609
    $sth->execute(@bind_params);
623
    $sth->execute(@bind_params);
624
    warn Data::Dumper::Dumper(@bind_params);
610
    my @results;
625
    my @results;
611
    my $previousbiblio = "";
626
    my $previousbiblio = "";
612
    my $odd           = 1;
627
    my $odd           = 1;
(-)a/acqui/addorder.pl (+1 lines)
Lines 202-207 if ( $orderinfo->{quantity} ne '0' ) { Link Here
202
                "biblio.author"               => $$orderinfo{author}          ? $$orderinfo{author}        : "",
202
                "biblio.author"               => $$orderinfo{author}          ? $$orderinfo{author}        : "",
203
                "biblio.seriestitle"          => $$orderinfo{series}          ? $$orderinfo{series}        : "",
203
                "biblio.seriestitle"          => $$orderinfo{series}          ? $$orderinfo{series}        : "",
204
                "biblioitems.isbn"            => $$orderinfo{isbn}            ? $$orderinfo{isbn}          : "",
204
                "biblioitems.isbn"            => $$orderinfo{isbn}            ? $$orderinfo{isbn}          : "",
205
                "biblioitems.ean"             => $$orderinfo{ean}             ? $$orderinfo{ean}           : "",
205
                "biblioitems.publishercode"   => $$orderinfo{publishercode}   ? $$orderinfo{publishercode} : "",
206
                "biblioitems.publishercode"   => $$orderinfo{publishercode}   ? $$orderinfo{publishercode} : "",
206
                "biblioitems.publicationyear" => $$orderinfo{publicationyear} ? $$orderinfo{publicationyear}: "",
207
                "biblioitems.publicationyear" => $$orderinfo{publicationyear} ? $$orderinfo{publicationyear}: "",
207
                "biblio.copyrightdate"        => $$orderinfo{publicationyear} ? $$orderinfo{publicationyear}: "",
208
                "biblio.copyrightdate"        => $$orderinfo{publicationyear} ? $$orderinfo{publicationyear}: "",
(-)a/acqui/histsearch.pl (+2 lines)
Lines 63-68 my $title = $input->param( 'title'); Link Here
63
my $author                  = $input->param('author');
63
my $author                  = $input->param('author');
64
my $isbn          	    = $input->param('isbn');
64
my $isbn          	    = $input->param('isbn');
65
my $name                    = $input->param( 'name' );
65
my $name                    = $input->param( 'name' );
66
my $ean                     = $input->param('ean');
66
my $basket                  = $input->param( 'basket' );
67
my $basket                  = $input->param( 'basket' );
67
my $booksellerinvoicenumber = $input->param( 'booksellerinvoicenumber' );
68
my $booksellerinvoicenumber = $input->param( 'booksellerinvoicenumber' );
68
my $from_placed_on          = $input->param('from');
69
my $from_placed_on          = $input->param('from');
Lines 119-124 $template->param( Link Here
119
    title                   => $title,
120
    title                   => $title,
120
    author                  => $author,
121
    author                  => $author,
121
    isbn		    => $isbn,
122
    isbn		    => $isbn,
123
    ean                     => $ean,
122
    name                    => $name,
124
    name                    => $name,
123
    basket                  => $basket,
125
    basket                  => $basket,
124
    booksellerinvoicenumber => $booksellerinvoicenumber,
126
    booksellerinvoicenumber => $booksellerinvoicenumber,
(-)a/acqui/neworderempty.pl (+1 lines)
Lines 378-383 $template->param( Link Here
378
    publicationyear  => $data->{'publicationyear'} ? $data->{'publicationyear'} : $data->{'copyrightdate'},
378
    publicationyear  => $data->{'publicationyear'} ? $data->{'publicationyear'} : $data->{'copyrightdate'},
379
    budget_loop      => $budget_loop,
379
    budget_loop      => $budget_loop,
380
    isbn             => $data->{'isbn'},
380
    isbn             => $data->{'isbn'},
381
    ean              => $data->{'ean'},
381
    seriestitle      => $data->{'seriestitle'},
382
    seriestitle      => $data->{'seriestitle'},
382
    itemtypeloop     => \@itemtypes,
383
    itemtypeloop     => \@itemtypes,
383
    quantity         => $data->{'quantity'},
384
    quantity         => $data->{'quantity'},
(-)a/acqui/parcel.pl (-4 / +5 lines)
Lines 100-113 if($input->param('format') eq "json"){ Link Here
100
    });
100
    });
101
       
101
       
102
    my @datas;
102
    my @datas;
103
    my $search   = $input->param('search') || '';
103
    my $search   = $input->param('search')     || '';
104
    my $ean      = $input->param('ean')        || '';
104
    my $supplier = $input->param('supplierid') || '';
105
    my $supplier = $input->param('supplierid') || '';
105
    my $basketno = $input->param('basketno') || '';
106
    my $basketno = $input->param('basketno') || '';
106
    my $orderno  = $input->param('orderno') || '';
107
    my $orderno  = $input->param('orderno') || '';
107
108
108
    my $orders = SearchOrder($orderno, $search, $supplier, $basketno);
109
    my $orders = SearchOrder($orderno, $search, $ean, $supplier, $basketno);
109
    foreach my $order (@$orders){
110
    foreach my $order (@$orders) {
110
        if($order->{quantityreceived} < $order->{quantity}){
111
        if ( $order->{quantityreceived} < $order->{quantity} ) {
111
            my $data = {};
112
            my $data = {};
112
            
113
            
113
            $data->{basketno} = $order->{basketno};
114
            $data->{basketno} = $order->{basketno};
(-)a/catalogue/detail.pl (-1 / +1 lines)
Lines 139-145 my ( $holdcount, $holds ) = GetReservesFromBiblionumber($biblionumber,1); Link Here
139
139
140
#coping with subscriptions
140
#coping with subscriptions
141
my $subscriptionsnumber = CountSubscriptionFromBiblionumber($biblionumber);
141
my $subscriptionsnumber = CountSubscriptionFromBiblionumber($biblionumber);
142
my @subscriptions       = GetSubscriptions( $dat->{title}, $dat->{issn}, $biblionumber );
142
my @subscriptions       = GetSubscriptions( $dat->{title}, $dat->{issn}, undef, $biblionumber );
143
my @subs;
143
my @subs;
144
144
145
foreach my $subscription (@subscriptions) {
145
foreach my $subscription (@subscriptions) {
(-)a/installer/data/mysql/atomicupdate/02.00.060-adding-ean.pl (+7 lines)
Line 0 Link Here
1
#!/usr/bin/perl
2
use C4::Context;
3
my $dbh= C4::Context->dbh;
4
$dbh->do("ALTER TABLE `biblioitems` ADD `ean` VARCHAR( 13 ) NULL AFTER issn");
5
$dbh->do("CREATE INDEX `ean` ON biblioitems (`ean`) ");
6
$dbh->do("ALTER TABLE `deletedbiblioitems` ADD `ean` VARCHAR( 13 ) NULL AFTER issn");
7
$dbh->do("CREATE INDEX `ean` ON deletedbiblioitems (`ean`) ");
(-)a/installer/data/mysql/en/marcflavour/unimarc/mandatory/unimarc_framework_DEFAULT.sql (+2 lines)
Lines 166-171 INSERT INTO `marc_tag_structure` (`tagfield`, `liblibrarian`, `libopac`, `repeat Link Here
166
		('022', 'Government Publication Number', 'Government Publication Number', 0, 0, '', ''),
166
		('022', 'Government Publication Number', 'Government Publication Number', 0, 0, '', ''),
167
		('040', 'CODEN (Serials)', 'CODEN (Serials)', 0, 0, '', ''),
167
		('040', 'CODEN (Serials)', 'CODEN (Serials)', 0, 0, '', ''),
168
		('071', 'Publisher\'s Number (Sound Recordings and Music)', '', 0, 0, '', ''),
168
		('071', 'Publisher\'s Number (Sound Recordings and Music)', '', 0, 0, '', ''),
169
		('073', 'EAN', 'EAN', 1, 0, '', ''),
169
		('100', 'General Processing Data', 'General Processing Data', 1, 0, '', ''),
170
		('100', 'General Processing Data', 'General Processing Data', 1, 0, '', ''),
170
		('101', 'Language of the Item', 'Language of the Item', 1, 0, '', ''),
171
		('101', 'Language of the Item', 'Language of the Item', 1, 0, '', ''),
171
		('102', 'Country of Publication or Production', 'Country of Publication or Production', 0, 0, '', ''),
172
		('102', 'Country of Publication or Production', 'Country of Publication or Production', 0, 0, '', ''),
Lines 356-361 INSERT INTO `marc_subfield_structure` (`tagfield`, `tagsubfield`, `liblibrarian` Link Here
356
		('040', 'z', 'Erroneous CODEN', 'Erroneous CODEN', 1, 0, '', 0, '', '', '', 0, -5, '', '', '', NULL),
357
		('040', 'z', 'Erroneous CODEN', 'Erroneous CODEN', 1, 0, '', 0, '', '', '', 0, -5, '', '', '', NULL),
357
		('071', 'a', 'Publisher\'s Number (Sound Recordings and Music)', 'Publisher\'s Number (Sound Recordings and Music)', 0, 0, '', 0, '', '', '', 0, -5, '', '', '', NULL),
358
		('071', 'a', 'Publisher\'s Number (Sound Recordings and Music)', 'Publisher\'s Number (Sound Recordings and Music)', 0, 0, '', 0, '', '', '', 0, -5, '', '', '', NULL),
358
		('071', 'b', 'Source', 'Source', 0, 0, '', 0, '', '', '', 0, -5, '', '', '', NULL),
359
		('071', 'b', 'Source', 'Source', 0, 0, '', 0, '', '', '', 0, -5, '', '', '', NULL),
360
		('073', 'a', 'EAN', 'EAN', 0, 0, 'biblioitems.ean', 0, '', '', '', 0, 0, '', '', '', NULL),
359
		('100', 'a', 'General Processing Data', 'General Processing Data', 0, 0, '', 1, '', '', 'unimarc_field_100.pl', 0, 0, '', '', '', NULL),
361
		('100', 'a', 'General Processing Data', 'General Processing Data', 0, 0, '', 1, '', '', 'unimarc_field_100.pl', 0, 0, '', '', '', NULL),
360
		('101', 'a', 'Language of the Text, Soundtrack, etc.', 'Language of the Text, Soundtrack, etc.', 1, 0, '', 1, 'LAN', '', '', 0, 0, '', '', '', NULL),
362
		('101', 'a', 'Language of the Text, Soundtrack, etc.', 'Language of the Text, Soundtrack, etc.', 1, 0, '', 1, 'LAN', '', '', 0, 0, '', '', '', NULL),
361
		('101', 'b', 'Language of Intermediate Text when Item is Not Translated from Original', 'Language of Intermediate Text when Item is Not Translated from Original', 0, 0, '', 1, '', '', '', 0, -5, '', '', '', NULL),
363
		('101', 'b', 'Language of Intermediate Text when Item is Not Translated from Original', 'Language of Intermediate Text when Item is Not Translated from Original', 0, 0, '', 1, '', '', '', 0, -5, '', '', '', NULL),
(-)a/installer/data/mysql/fr-FR/marcflavour/unimarc_complet/Obligatoire/framework_DEFAULT.sql (-1 / +1 lines)
Lines 318-324 INSERT INTO `marc_subfield_structure` (`tagfield`, `tagsubfield`, `liblibrarian` Link Here
318
('072', 'c', 'Numéro additionnels suivant le code normalisé', '', 0, 0, '', 0, '', '', '', 0, 0, '', NULL, '', ''),
318
('072', 'c', 'Numéro additionnels suivant le code normalisé', '', 0, 0, '', 0, '', '', '', 0, 0, '', NULL, '', ''),
319
('072', 'd', 'Mention de disponibilité et/ou de prix', '', 0, 0, '', 0, '', '', '', 0, 0, '', NULL, '', ''),
319
('072', 'd', 'Mention de disponibilité et/ou de prix', '', 0, 0, '', 0, '', '', '', 0, 0, '', NULL, '', ''),
320
('072', 'z', 'Numéro ou code erroné', '', 0, 0, '', 0, '', '', '', 0, 0, '', NULL, '', ''),
320
('072', 'z', 'Numéro ou code erroné', '', 0, 0, '', 0, '', '', '', 0, 0, '', NULL, '', ''),
321
('073', 'a', 'Numéro', '', 0, 0, '', 0, '', '', '', NULL, 0, '', '', NULL, ''),
321
('073', 'a', 'Numéro', '', 0, 0, 'biblioitems.ean', 0, '', '', '', NULL, 0, '', '', NULL, ''),
322
('073', 'b', 'Qualificatif', '', 0, 0, '', 0, '', '', '', NULL, 0, '', '', NULL, ''),
322
('073', 'b', 'Qualificatif', '', 0, 0, '', 0, '', '', '', NULL, 0, '', '', NULL, ''),
323
('073', 'c', 'Numéros additionnels', '', 0, 0, '', 0, '', '', '', NULL, 0, '', '', NULL, ''),
323
('073', 'c', 'Numéros additionnels', '', 0, 0, '', 0, '', '', '', NULL, 0, '', '', NULL, ''),
324
('073', 'd', 'Prix et disponibilité', '', 0, 0, '', 0, '', '', '', NULL, 0, '', '', NULL, ''),
324
('073', 'd', 'Prix et disponibilité', '', 0, 0, '', 0, '', '', '', NULL, 0, '', '', NULL, ''),
(-)a/installer/data/mysql/kohastructure.sql (+2 lines)
Lines 154-159 CREATE TABLE `biblioitems` ( -- information related to bibliographic records in Link Here
154
  `itemtype` varchar(10) default NULL, -- biblio level item type (MARC21 942$c)
154
  `itemtype` varchar(10) default NULL, -- biblio level item type (MARC21 942$c)
155
  `isbn` varchar(30) default NULL, -- ISBN (MARC21 020$a)
155
  `isbn` varchar(30) default NULL, -- ISBN (MARC21 020$a)
156
  `issn` varchar(9) default NULL, -- ISSN (MARC21 022$a)
156
  `issn` varchar(9) default NULL, -- ISSN (MARC21 022$a)
157
  `ean` varchar(13) default NULL,
157
  `publicationyear` text,
158
  `publicationyear` text,
158
  `publishercode` varchar(255) default NULL, -- publisher (MARC21 260$b)
159
  `publishercode` varchar(255) default NULL, -- publisher (MARC21 260$b)
159
  `volumedate` date default NULL,
160
  `volumedate` date default NULL,
Lines 618-623 CREATE TABLE `deletedbiblioitems` ( -- information about bibliographic records t Link Here
618
  `itemtype` varchar(10) default NULL, -- biblio level item type (MARC21 942$c)
619
  `itemtype` varchar(10) default NULL, -- biblio level item type (MARC21 942$c)
619
  `isbn` varchar(30) default NULL, -- ISBN (MARC21 020$a)
620
  `isbn` varchar(30) default NULL, -- ISBN (MARC21 020$a)
620
  `issn` varchar(9) default NULL, -- ISSN (MARC21 022$a)
621
  `issn` varchar(9) default NULL, -- ISSN (MARC21 022$a)
622
  `ean` varchar(13) default NULL,
621
  `publicationyear` text,
623
  `publicationyear` text,
622
  `publishercode` varchar(255) default NULL, -- publisher (MARC21 260$b)
624
  `publishercode` varchar(255) default NULL, -- publisher (MARC21 260$b)
623
  `volumedate` date default NULL,
625
  `volumedate` date default NULL,
(-)a/installer/data/mysql/updatedatabase.pl (+9 lines)
Lines 4605-4610 if (C4::Context->preference("Version") < TransformToNum($DBversion)) { Link Here
4605
    SetVersion ($DBversion);
4605
    SetVersion ($DBversion);
4606
}
4606
}
4607
4607
4608
$DBversion = "3.07.00.008";
4609
if ( C4::Context->preference("Version") < TransformToNum($DBversion) ) {
4610
    $dbh->do("ALTER TABLE `biblioitems` ADD `ean` VARCHAR( 13 ) NULL AFTER issn");
4611
    $dbh->do("CREATE INDEX `ean` ON biblioitems (`ean`) ");
4612
    $dbh->do("ALTER TABLE `deletedbiblioitems` ADD `ean` VARCHAR( 13 ) NULL AFTER issn");
4613
    $dbh->do("CREATE INDEX `ean` ON deletedbiblioitems (`ean`) ");
4614
    print "Upgrade to $DBversion done (Adding ean in biblioitems and deletedbiblioitems)\n";
4615
    SetVersion($DBversion);
4616
}
4608
4617
4609
=head1 FUNCTIONS
4618
=head1 FUNCTIONS
4610
4619
(-)a/koha-tmpl/intranet-tmpl/prog/en/includes/serials-search.inc (-1 / +8 lines)
Lines 3-9 Link Here
3
<div id="header_search">
3
<div id="header_search">
4
	<div id="subscription_search" class="residentsearch">
4
	<div id="subscription_search" class="residentsearch">
5
	<p class="tip">Search Subscriptions:</p>
5
	<p class="tip">Search Subscriptions:</p>
6
 <form action="/cgi-bin/koha/serials/serials-home.pl" method="get">[% IF ( routing ) %]<input type="hidden" name="routing" value="[% routing %]" />[% END %]<input type="hidden" name="searched" value="1" /> <label for="ISSN_filter">ISSN:</label> <input type="text" size="10" maxlength="11" name="ISSN_filter" id="ISSN_filter" value="[% ISSN_filter %]" /> <label for="title_filter">Title:</label> <input type="text" size="20" maxlength="40" name="title_filter" id="title_filter" value="[% title_filter %]" /><input type="submit" value="Search" class="submit" />
6
 <form action="/cgi-bin/koha/serials/serials-home.pl" method="get">
7
 [% IF ( routing ) %]<input type="hidden" name="routing" value="[% routing %]" />[% END %]
8
 <input type="hidden" name="searched" value="1" /> 
9
 <label for="ISSN_filter">ISSN:</label> <input type="text" size="10" maxlength="11" name="ISSN_filter" id="ISSN_filter" value="[% ISSN_filter %]" /> 
10
 <label for="EAN_filter">EAN:</label> <input type="text" size="20" maxlength="40" name="EAN_filter" id="EAN_filter" value="[% EAN_filter %]" />
11
 <label for="title_filter">Title:</label> <input type="text" size="20" maxlength="40" name="title_filter" id="title_filter" value="[% title_filter %]" />
12
 <input type="submit" value="Search" class="submit" />
13
7
</form>
14
</form>
8
	</div>
15
	</div>
9
    [% INCLUDE 'patron-search-box.inc' %]
16
    [% INCLUDE 'patron-search-box.inc' %]
(-)a/koha-tmpl/intranet-tmpl/prog/en/modules/acqui/histsearch.tt (+1 lines)
Lines 22-27 Link Here
22
		<li><label for="title">Title: </label> <input type="text" name="title" id="title" value="[% title %]" /></li>
22
		<li><label for="title">Title: </label> <input type="text" name="title" id="title" value="[% title %]" /></li>
23
		<li><label for="author">Author: </label> <input type="text" name="author" id="author" value="[% author %]" /></li>
23
		<li><label for="author">Author: </label> <input type="text" name="author" id="author" value="[% author %]" /></li>
24
		<li><label for="isbn">ISBN: </label> <input type="isbn" name="isbn" id="isbn" value="[% isbn %]" /></li>
24
		<li><label for="isbn">ISBN: </label> <input type="isbn" name="isbn" id="isbn" value="[% isbn %]" /></li>
25
		<li><label for="ean">EAN: </label> <input type="text" name="ean" id="ean" value="[% ean %]" /></li>
25
		<li><label for="name">Vendor: </label> <input type="text" name="name" id="name" value="[% name %]" /></li>
26
		<li><label for="name">Vendor: </label> <input type="text" name="name" id="name" value="[% name %]" /></li>
26
		<li><label for="basket">Basket: </label> <input type="text" name="basket" id="basket" value="[% basket %]" /></li>
27
		<li><label for="basket">Basket: </label> <input type="text" name="basket" id="basket" value="[% basket %]" /></li>
27
		<li><label for="booksellerinvoicenumber ">Bookseller Invoice No: </label> <input type="text" name="booksellerinvoicenumber" id="booksellerinvoicenumber" value="[% booksellerinvoicenumber %]" /></li>
28
		<li><label for="booksellerinvoicenumber ">Bookseller Invoice No: </label> <input type="text" name="booksellerinvoicenumber" id="booksellerinvoicenumber" value="[% booksellerinvoicenumber %]" /></li>
(-)a/koha-tmpl/intranet-tmpl/prog/en/modules/acqui/neworderempty.tt (+9 lines)
Lines 284-289 $(document).ready(function() Link Here
284
        </li>
284
        </li>
285
        <li>
285
        <li>
286
            [% IF ( biblionumber ) %]
286
            [% IF ( biblionumber ) %]
287
            <span class="label">EAN: </span>
288
                <input type="hidden" size="20" name="ean" id="EAN" value="[% ean %]" />[% ean %]
289
            [% ELSE %]
290
            <label for="EAN">EAN: </label>
291
                <input type="text" size="20" name="ean" id="EAN" value="[% ean %]" />
292
            [% END %]
293
        </li>
294
        <li>
295
            [% IF ( biblionumber ) %]
287
            <span class="label">Series: </span>
296
            <span class="label">Series: </span>
288
                <input type="hidden" size="50" name="series" id="series" value="[% seriestitle %]" />[% seriestitle %]
297
                <input type="hidden" size="50" name="series" id="series" value="[% seriestitle %]" />[% seriestitle %]
289
            [% ELSE %]
298
            [% ELSE %]
(-)a/koha-tmpl/intranet-tmpl/prog/en/modules/acqui/parcel.tt (-2 / +9 lines)
Lines 76-83 Link Here
76
    var summaryStatus = jQuery.trim($("#summaryfilter").val());
76
    var summaryStatus = jQuery.trim($("#summaryfilter").val());
77
	var basketStatus  = $("#basketfilter").val();
77
	var basketStatus  = $("#basketfilter").val();
78
	var orderStatus   = $("#orderfilter").val();
78
	var orderStatus   = $("#orderfilter").val();
79
	var eanStatus     = $("#eanfilter").val();
79
80
80
	if (summaryStatus == '' && basketStatus == '' && orderStatus == '') { clearFilters(); return false; }
81
	if (summaryStatus == '' && basketStatus == '' && orderStatus == '' && eanStatus == '') { clearFilters(); return false; }
81
82
82
	var filtered = "table#pendingt tbody.filterclass tr";
83
	var filtered = "table#pendingt tbody.filterclass tr";
83
84
Lines 118-124 Link Here
118
			}catch(e){alert(e);}
119
			}catch(e){alert(e);}
119
		}
120
		}
120
	}
121
	}
121
	var transaction = YAHOO.util.Connect.asyncRequest('GET', '/cgi-bin/koha/acqui/parcel.pl?supplierid=[% supplierid %]&search='+summaryStatus+'&basketno='+basketStatus+'&orderno='+orderStatus+'&format=json', callback, null);
122
	var transaction = YAHOO.util.Connect.asyncRequest('GET', '/cgi-bin/koha/acqui/parcel.pl?supplierid=[% supplierid %]&search='+summaryStatus+'&basketno='+basketStatus+'&orderno='+orderStatus+'&ean='+eanStatus+'&format=json', callback, null);
122
123
123
	return false;
124
	return false;
124
    }
125
    }
Lines 407-412 Link Here
407
		    <label for="orderfilter">Order Line :</label>
408
		    <label for="orderfilter">Order Line :</label>
408
		    <input type="text" name="orderfilter" id="orderfilter" />
409
		    <input type="text" name="orderfilter" id="orderfilter" />
409
		</li>
410
		</li>
411
412
		<li>
413
		    <label for="eanfilter">EAN :</label>
414
		    <input type="text" name="eanfilter" id="eanfilter" />
415
		</li>
416
410
	    </ol>
417
	    </ol>
411
		<fieldset class="action">
418
		<fieldset class="action">
412
		    <input type="submit" value="Filter" />
419
		    <input type="submit" value="Filter" />
(-)a/kohaversion.pl (-14 / +8 lines)
Lines 1-22 Link Here
1
# the next koha public release version number;
1
# the next koha public release version number;
2
2
# the kohaversion is divided in 4 parts :
3
=head1 FUNCTIONS
3
# - #1 : the major number. 3 atm
4
4
# - #2 : the functionnal release. 00 atm
5
=head2 kohaversion
5
# - #3 : the subnumber, moves only on a public release
6
6
# - #4 : the developer version. The 4th number is the database subversion.
7
the kohaversion is divided in 4 parts :
7
#        used by developers when the database changes. updatedatabase take care of the changes itself
8
 - #1 : the major number. 3 atm
8
#        and is automatically called by Auth.pm when needed.
9
 - #2 : the functionnal release. 00 atm
10
 - #3 : the subnumber, moves only on a public release
11
 - #4 : the developer version. The 4th number is the database subversion.
12
        used by developers when the database changes. updatedatabase take care of the changes itself
13
        and is automatically called by Auth.pm when needed.
14
=cut
15
9
16
use strict;
10
use strict;
17
11
18
sub kohaversion {
12
sub kohaversion {
19
    our $VERSION = '3.07.00.007';
13
    our $VERSION = '3.02.00.059';
20
    # version needs to be set this way
14
    # version needs to be set this way
21
    # so that it can be picked up by Makefile.PL
15
    # so that it can be picked up by Makefile.PL
22
    # during install
16
    # during install
(-)a/opac/opac-ISBDdetail.pl (-1 / +1 lines)
Lines 101-108 $template->param( Link Here
101
my $subscriptionsnumber = CountSubscriptionFromBiblionumber($biblionumber);
101
my $subscriptionsnumber = CountSubscriptionFromBiblionumber($biblionumber);
102
my $dbh = C4::Context->dbh;
102
my $dbh = C4::Context->dbh;
103
my $dat                 = TransformMarcToKoha( $dbh, $record );
103
my $dat                 = TransformMarcToKoha( $dbh, $record );
104
my @subscriptions       = GetSubscriptions( undef, undef, $biblionumber );
105
104
105
my @subscriptions       = GetSubscriptions( $dat->{title}, $dat->{issn}, undef, $biblionumber );
106
my @subs;
106
my @subs;
107
foreach my $subscription (@subscriptions) {
107
foreach my $subscription (@subscriptions) {
108
    my %cell;
108
    my %cell;
(-)a/opac/opac-detail.pl (-2 / +3 lines)
Lines 75-80 $template->param( biblionumber => $biblionumber ); Link Here
75
75
76
76
77
SetUTF8Flag($record);
77
SetUTF8Flag($record);
78
my $marcflavour      = C4::Context->preference("marcflavour");
79
my $ean = GetNormalizedEAN( $record, $marcflavour );
78
80
79
# XSLT processing of some stuff
81
# XSLT processing of some stuff
80
if (C4::Context->preference("OPACXSLTDetailsDisplay") ) {
82
if (C4::Context->preference("OPACXSLTDetailsDisplay") ) {
Lines 429-435 my $collections = GetKohaAuthorisedValues('items.ccode',$dat->{'frameworkcode'} Link Here
429
431
430
#coping with subscriptions
432
#coping with subscriptions
431
my $subscriptionsnumber = CountSubscriptionFromBiblionumber($biblionumber);
433
my $subscriptionsnumber = CountSubscriptionFromBiblionumber($biblionumber);
432
my @subscriptions       = GetSubscriptions( undef, undef, $biblionumber );
434
my @subscriptions       = GetSubscriptions($dat->{'title'}, $dat->{'issn'}, $ean, $biblionumber );
433
435
434
my @subs;
436
my @subs;
435
$dat->{'serial'}=1 if $subscriptionsnumber;
437
$dat->{'serial'}=1 if $subscriptionsnumber;
Lines 586-592 foreach ( keys %{$dat} ) { Link Here
586
# in each case, we're grabbing the first value we find in
588
# in each case, we're grabbing the first value we find in
587
# the record and normalizing it
589
# the record and normalizing it
588
my $upc = GetNormalizedUPC($record,$marcflavour);
590
my $upc = GetNormalizedUPC($record,$marcflavour);
589
my $ean = GetNormalizedEAN($record,$marcflavour);
590
my $oclc = GetNormalizedOCLCNumber($record,$marcflavour);
591
my $oclc = GetNormalizedOCLCNumber($record,$marcflavour);
591
my $isbn = GetNormalizedISBN(undef,$record,$marcflavour);
592
my $isbn = GetNormalizedISBN(undef,$record,$marcflavour);
592
my $content_identifier_exists;
593
my $content_identifier_exists;
(-)a/serials/serials-home.pl (-9 / +9 lines)
Lines 48-59 use C4::Serials; Link Here
48
use C4::Output;
48
use C4::Output;
49
use C4::Context;
49
use C4::Context;
50
50
51
my $query         = new CGI;
51
my $query        = new CGI;
52
my $title         = $query->param('title_filter');
52
my $title        = $query->param('title_filter');
53
my $ISSN          = $query->param('ISSN_filter');
53
my $ISSN         = $query->param('ISSN_filter');
54
my $routing       = $query->param('routing')||C4::Context->preference("RoutingSerials");
54
my $EAN          = $query->param('EAN_filter');
55
my $searched      = $query->param('searched');
55
my $routing      = $query->param('routing') || C4::Context->preference("RoutingSerials");
56
my $biblionumber  = $query->param('biblionumber');
56
my $searched     = $query->param('searched');
57
my $biblionumber = $query->param('biblionumber');
57
58
58
my @serialseqs = $query->param('serialseq');
59
my @serialseqs = $query->param('serialseq');
59
my @planneddates = $query->param('planneddate');
60
my @planneddates = $query->param('planneddate');
Lines 91-98 if (@serialseqs){ Link Here
91
  $template->param('information'=>\@information);
92
  $template->param('information'=>\@information);
92
}
93
}
93
my @subscriptions;
94
my @subscriptions;
94
if ($searched){
95
if ($searched) {
95
    @subscriptions = GetSubscriptions( $title, $ISSN, $biblionumber );
96
    @subscriptions = GetSubscriptions( $title, $ISSN, $EAN, $biblionumber );
96
}
97
}
97
98
98
# to toggle between create or edit routing list options
99
# to toggle between create or edit routing list options
99
- 

Return to bug 5337