[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Koha-cvs] CVS: koha/C4 Bull.pm,1.12,1.13 Context.pm,1.24,1.25 Input.pm,
From: |
Paul POULAIN |
Subject: |
[Koha-cvs] CVS: koha/C4 Bull.pm,1.12,1.13 Context.pm,1.24,1.25 Input.pm,1.17,1.18 Output.pm,1.52,1.53 SearchMarc.pm,1.47,1.48 |
Date: |
Thu, 04 Aug 2005 06:31:25 -0700 |
Update of /cvsroot/koha/koha/C4
In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv10983/C4
Modified Files:
Bull.pm Context.pm Input.pm Output.pm SearchMarc.pm
Log Message:
synch'ing 2.2 and head
Index: Bull.pm
===================================================================
RCS file: /cvsroot/koha/koha/C4/Bull.pm,v
retrieving revision 1.12
retrieving revision 1.13
diff -C2 -r1.12 -r1.13
*** Bull.pm 20 Jun 2005 14:10:01 -0000 1.12
--- Bull.pm 4 Aug 2005 13:31:22 -0000 1.13
***************
*** 49,53 ****
&get_full_subscription_list_from_biblionumber
&modsubscriptionhistory &newissue
! &getserials &serialchangestatus
&Find_Next_Date, &Get_Next_Seq
&hassubscriptionexpired &subscriptionexpirationdate
&subscriptionrenew
--- 49,53 ----
&get_full_subscription_list_from_biblionumber
&modsubscriptionhistory &newissue
! &getserials &getlatestserials &serialchangestatus
&Find_Next_Date, &Get_Next_Seq
&hassubscriptionexpired &subscriptionexpirationdate
&subscriptionrenew
***************
*** 109,113 ****
$add2,$every2,$whenmorethan2,$setto2,$lastvalue2,
$add3,$every3,$whenmorethan3,$setto3,$lastvalue3,
! $numberingmethod, $status, $notes) = @_;
my $dbh = C4::Context->dbh;
#save subscription
--- 109,113 ----
$add2,$every2,$whenmorethan2,$setto2,$lastvalue2,
$add3,$every3,$whenmorethan3,$setto3,$lastvalue3,
! $numberingmethod, $status, $notes,$letter) = @_;
my $dbh = C4::Context->dbh;
#save subscription
***************
*** 117,124 ****
add2,every2,whenmorethan2,setto2,lastvalue2,
add3,every3,whenmorethan3,setto3,lastvalue3,
! numberingmethod,
status, notes) values
(?,?,?,?,?,?,?,?,?,
?,?,?,?,?,?,?,?,?,?,
! ?,?,?,?,?,?,?,?,?,?)");
$sth->execute($auser,$aqbooksellerid,$cost,$aqbudgetid,$biblionumber,
format_date_in_iso($startdate),$periodicity,$dow,$numberlength,$weeklength,$monthlength,
--- 117,124 ----
add2,every2,whenmorethan2,setto2,lastvalue2,
add3,every3,whenmorethan3,setto3,lastvalue3,
! numberingmethod,
status, notes, letter) values
(?,?,?,?,?,?,?,?,?,
?,?,?,?,?,?,?,?,?,?,
!
?,?,?,?,?,?,?,?,?,?,?)");
$sth->execute($auser,$aqbooksellerid,$cost,$aqbudgetid,$biblionumber,
format_date_in_iso($startdate),$periodicity,$dow,$numberlength,$weeklength,$monthlength,
***************
*** 126,130 ****
$add2,$every2,$whenmorethan2,$setto2,$lastvalue2,
$add3,$every3,$whenmorethan3,$setto3,$lastvalue3,
! $numberingmethod, $status, $notes);
#then create the 1st waited number
my $subscriptionid = $dbh->{'mysql_insertid'};
--- 126,130 ----
$add2,$every2,$whenmorethan2,$setto2,$lastvalue2,
$add3,$every3,$whenmorethan3,$setto3,$lastvalue3,
! $numberingmethod, $status,
$notes,$letter);
#then create the 1st waited number
my $subscriptionid = $dbh->{'mysql_insertid'};
***************
*** 204,208 ****
left join aqbooksellers
on subscription.aqbooksellerid=aqbooksellers.id
left join biblio on
biblio.biblionumber=subscription.biblionumber
! where
subscription.biblionumber = ? order by year,serial.planneddate');
$sth->execute($biblionumber);
my @res;
--- 204,208 ----
left join aqbooksellers
on subscription.aqbooksellerid=aqbooksellers.id
left join biblio on
biblio.biblionumber=subscription.biblionumber
! where
subscription.biblionumber = ? order by
year,serial.subscriptionid,serial.planneddate');
$sth->execute($biblionumber);
my @res;
***************
*** 213,216 ****
--- 213,217 ----
my @loopissues;
my $first;
+ my $previousnote="";
while (my $subs = $sth->fetchrow_hashref) {
# my $sth2 = $dbh->prepare('select * from serial where
serial.biblionumber = ? and serial.subscriptionid=? order by
serial.planneddate');
***************
*** 230,233 ****
--- 231,235 ----
'status3' => $subs->{'status'}==3,
'status4' => $subs->{'status'}==4,
+ 'notes' => $subs->{'notes'} eq
$previousnote?"":$subs->{notes},
};
}else {
***************
*** 245,248 ****
--- 247,251 ----
'status3' => $subs->{'status'}==3,
'status4' => $subs->{'status'}==4,
+ 'notes' => $subs->{'notes'} eq
$previousnote?"":$subs->{notes},
};
***************
*** 256,259 ****
--- 259,263 ----
};
}
+ $previousnote=$subs->{notes};
}
return address@hidden;
***************
*** 267,271 ****
$add2,$every2,$whenmorethan2,$setto2,$lastvalue2,$innerloop2,
$add3,$every3,$whenmorethan3,$setto3,$lastvalue3,$innerloop3,
! $numberingmethod, $status,
$biblionumber, $notes, $subscriptionid)= @_;
my $dbh = C4::Context->dbh;
my $sth=$dbh->prepare("update subscription set librarian=?,
aqbooksellerid=?,cost=?,aqbudgetid=?,startdate=?,
--- 271,275 ----
$add2,$every2,$whenmorethan2,$setto2,$lastvalue2,$innerloop2,
$add3,$every3,$whenmorethan3,$setto3,$lastvalue3,$innerloop3,
! $numberingmethod, $status,
$biblionumber, $notes, $letter, $subscriptionid)= @_;
my $dbh = C4::Context->dbh;
my $sth=$dbh->prepare("update subscription set librarian=?,
aqbooksellerid=?,cost=?,aqbudgetid=?,startdate=?,
***************
*** 274,278 ****
add2=?,every2=?,whenmorethan2=?,setto2=?,lastvalue2=?,innerloop2=?,
add3=?,every3=?,whenmorethan3=?,setto3=?,lastvalue3=?,innerloop3=?,
! numberingmethod=?, status=?,
biblionumber=?, notes=? where subscriptionid = ?");
$sth->execute($auser,$aqbooksellerid,$cost,$aqbudgetid,$startdate,
$periodicity,$dow,$numberlength,$weeklength,$monthlength,
--- 278,282 ----
add2=?,every2=?,whenmorethan2=?,setto2=?,lastvalue2=?,innerloop2=?,
add3=?,every3=?,whenmorethan3=?,setto3=?,lastvalue3=?,innerloop3=?,
! numberingmethod=?, status=?,
biblionumber=?, notes=?, letter=? where subscriptionid = ?");
$sth->execute($auser,$aqbooksellerid,$cost,$aqbudgetid,$startdate,
$periodicity,$dow,$numberlength,$weeklength,$monthlength,
***************
*** 280,284 ****
$add2,$every2,$whenmorethan2,$setto2,$lastvalue2,$innerloop2,
$add3,$every3,$whenmorethan3,$setto3,$lastvalue3,$innerloop3,
! $numberingmethod, $status,
$biblionumber, $notes, $subscriptionid);
$sth->finish;
--- 284,288 ----
$add2,$every2,$whenmorethan2,$setto2,$lastvalue2,$innerloop2,
$add3,$every3,$whenmorethan3,$setto3,$lastvalue3,$innerloop3,
! $numberingmethod, $status,
$biblionumber, $notes, $letter, $subscriptionid);
$sth->finish;
***************
*** 303,312 ****
my $sth;
if ($biblionumber) {
! $sth = $dbh->prepare("select
subscription.subscriptionid,biblio.title,biblioitems.issn,subscription.notes
from subscription,biblio,biblioitems where biblio.biblionumber =
biblioitems.biblionumber and biblio.biblionumber=subscription.biblionumber and
biblio.biblionumber=?");
$sth->execute($biblionumber);
} else {
if ($ISSN and $title)
{
! $sth = $dbh->prepare("select
subscription.subscriptionid,biblio.title,biblioitems.issn,subscription.notes
from subscription,biblio,biblioitems where biblio.biblionumber =
biblioitems.biblionumber and biblio.biblionumber=subscription.biblionumber and
(biblio.title like ? or biblioitems.issn = ? )");
$sth->execute("%$title%",$ISSN);
}
--- 307,316 ----
my $sth;
if ($biblionumber) {
! $sth = $dbh->prepare("select
subscription.subscriptionid,biblio.title,biblioitems.issn,subscription.notes,biblio.biblionumber
from subscription,biblio,biblioitems where biblio.biblionumber =
biblioitems.biblionumber and biblio.biblionumber=subscription.biblionumber and
biblio.biblionumber=?");
$sth->execute($biblionumber);
} else {
if ($ISSN and $title)
{
! $sth = $dbh->prepare("select
subscription.subscriptionid,biblio.title,biblioitems.issn,subscription.notes,biblio.biblionumber
from subscription,biblio,biblioitems where biblio.biblionumber =
biblioitems.biblionumber and biblio.biblionumber=subscription.biblionumber and
(biblio.title like ? or biblioitems.issn = ? )");
$sth->execute("%$title%",$ISSN);
}
***************
*** 315,324 ****
if ($ISSN)
{
! $sth = $dbh->prepare("select
subscription.subscriptionid,biblio.title,biblioitems.issn,subscription.notes
from subscription,biblio,biblioitems where biblio.biblionumber =
biblioitems.biblionumber and biblio.biblionumber=subscription.biblionumber and
biblioitems.issn = ?");
$sth->execute($ISSN);
}
else
{
! $sth = $dbh->prepare("select
subscription.subscriptionid,biblio.title,biblioitems.issn,subscription.notes
from subscription,biblio,biblioitems where biblio.biblionumber =
biblioitems.biblionumber and
biblio.biblionumber=subscription.biblionumber and biblio.title like ? ");
$sth->execute("%$title%");
--- 319,328 ----
if ($ISSN)
{
! $sth = $dbh->prepare("select
subscription.subscriptionid,biblio.title,biblioitems.issn,subscription.notes,biblio.biblionumber
from subscription,biblio,biblioitems where biblio.biblionumber =
biblioitems.biblionumber and biblio.biblionumber=subscription.biblionumber and
biblioitems.issn = ?");
$sth->execute($ISSN);
}
else
{
! $sth = $dbh->prepare("select
subscription.subscriptionid,biblio.title,biblioitems.issn,subscription.notes,biblio.biblionumber
from subscription,biblio,biblioitems where biblio.biblionumber =
biblioitems.biblionumber and
biblio.biblionumber=subscription.biblionumber and biblio.title like ? ");
$sth->execute("%$title%");
***************
*** 326,331 ****
}
}
! my @results;
while (my $line = $sth->fetchrow_hashref) {
push @results, $line;
}
--- 330,342 ----
}
}
! my @results;
! my $previoustitle="";
while (my $line = $sth->fetchrow_hashref) {
+ if ($previoustitle eq $line->{title}) {
+ $line->{title}="";
+ $line->{issn}="";
+ } else {
+ $previoustitle=$line->{title};
+ }
push @results, $line;
}
***************
*** 362,365 ****
--- 373,378 ----
return ($totalissues,@serials);
}
+
+ # get the $limit's latest serials arrived or missing for a given subscription
sub getlatestserials{
my ($subscriptionid,$limit) address@hidden;
***************
*** 378,382 ****
$sth->execute($subscriptionid);
my ($totalissues) = $sth->fetchrow;
! return ($totalissues,@serials);
}
--- 391,395 ----
$sth->execute($subscriptionid);
my ($totalissues) = $sth->fetchrow;
! return address@hidden;
}
***************
*** 391,395 ****
# change status & update subscriptionhistory
if ($status eq 6){
! delissue($serialseq, $subscriptionid);
}else{
$sth = $dbh->prepare("update serial set
serialseq=?,planneddate=?,status=? where serialid = ?");
--- 404,408 ----
# change status & update subscriptionhistory
if ($status eq 6){
! delissue($serialseq, $subscriptionid)
}else{
$sth = $dbh->prepare("update serial set
serialseq=?,planneddate=?,status=? where serialid = ?");
***************
*** 406,410 ****
$sth->execute($recievedlist,$missinglist,$subscriptionid);
}
-
# create new waited entry if needed (ie : was a "waited" and has
changed)
if ($oldstatus eq 1 && $status ne 1) {
--- 419,422 ----
***************
*** 442,445 ****
--- 454,464 ----
}
+ sub delissue {
+ my ($serialseq,$subscriptionid) = @_;
+ my $dbh = C4::Context->dbh;
+ my $sth = $dbh->prepare("delete from serial where serialseq= ? and
subscriptionid= ? ");
+ $sth->execute($serialseq,$subscriptionid);
+ }
+
sub Get_Next_Date(@) {
my ($planneddate,$subscription) = @_;
Index: Context.pm
===================================================================
RCS file: /cvsroot/koha/koha/C4/Context.pm,v
retrieving revision 1.24
retrieving revision 1.25
diff -C2 -r1.24 -r1.25
*** Context.pm 26 Jul 2005 15:58:47 -0000 1.24
--- Context.pm 4 Aug 2005 13:31:22 -0000 1.25
***************
*** 597,600 ****
--- 597,601 ----
$stopwordlist->{$stopword} = uc($stopword);
}
+ $stopwordlist->{A} = "A" unless $stopwordlist;
return $stopwordlist;
}
Index: Input.pm
===================================================================
RCS file: /cvsroot/koha/koha/C4/Input.pm,v
retrieving revision 1.17
retrieving revision 1.18
diff -C2 -r1.17 -r1.18
*** Input.pm 22 Jun 2005 09:36:24 -0000 1.17
--- Input.pm 4 Aug 2005 13:31:22 -0000 1.18
***************
*** 180,188 ****
Returns NULL if no authorised values found
=cut
- #'
- #--------------------------------------
- # Determine if a number is a valid ISBN number, according to length
- # of 10 digits and valid checksum
sub buildCGIsort {
use strict;
--- 180,191 ----
Returns NULL if no authorised values found
+ =item buildCGISort
+
+ $CGIScrollingList = &BuildCGISort($name string, $input_name string);
+
+ Returns the scrolling list with name $input_name, built on authorised Values
named $name.
+ Returns NULL if no authorised values found
+
=cut
sub buildCGIsort {
use strict;
***************
*** 208,212 ****
-size => 1,
-multiple => 0);
! }
return $CGISort;
}
--- 211,216 ----
-size => 1,
-multiple => 0);
! }
! $sth->finish;
return $CGISort;
}
Index: SearchMarc.pm
===================================================================
RCS file: /cvsroot/koha/koha/C4/SearchMarc.pm,v
retrieving revision 1.47
retrieving revision 1.48
diff -C2 -r1.47 -r1.48
*** SearchMarc.pm 25 Jun 2005 05:35:29 -0000 1.47
--- SearchMarc.pm 4 Aug 2005 13:31:22 -0000 1.48
***************
*** 173,177 ****
--- 173,182 ----
=cut
+ =head2 my $marcurlsarray = &getMARCurls($dbh,$bibid,$marcflavour);
+ Returns a reference to an array containing all the URLS stored in the MARC
database for the given bibid.
+ $marcflavour ("MARC21" or "UNIMARC") isn't used in this version because both
flavours of MARC use the same subfield for URLS (but eventually when we get the
lables working we'll need to change this.
+
+ =cut
sub catalogsearch {
my ($dbh, $tags, $and_or, $excluding, $operator, $value,
$offset,$length,$orderby,$desc_or_asc,$sqlstring, $extratables) = @_;
***************
*** 579,583 ****
$sth->finish;
- $dbh->disconnect;
my address@hidden;
--- 584,587 ----
***************
*** 616,620 ****
$sth->finish;
- $dbh->disconnect;
my address@hidden;
--- 620,623 ----
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [Koha-cvs] CVS: koha/C4 Bull.pm,1.12,1.13 Context.pm,1.24,1.25 Input.pm,1.17,1.18 Output.pm,1.52,1.53 SearchMarc.pm,1.47,1.48,
Paul POULAIN <=
- Prev by Date:
[Koha-cvs] CVS: koha/C4 Acquisition.pm,1.17,1.18 AuthoritiesMarc.pm,1.19,1.20 Auth.pm,1.44,1.45 Biblio.pm,1.121,1.122
- Next by Date:
[Koha-cvs] CVS: koha/koha-tmpl/intranet-tmpl/default/en/authorities authorities-home.tmpl,1.4,1.5 searchresultlist-auth.tmpl,1.8,1.9
- Previous by thread:
[Koha-cvs] CVS: koha/C4 Acquisition.pm,1.17,1.18 AuthoritiesMarc.pm,1.19,1.20 Auth.pm,1.44,1.45 Biblio.pm,1.121,1.122
- Next by thread:
[Koha-cvs] CVS: koha/koha-tmpl/intranet-tmpl/default/en/authorities authorities-home.tmpl,1.4,1.5 searchresultlist-auth.tmpl,1.8,1.9
- Index(es):