Renewal date-time in "issues.lastreneweddate"
Hello, We (at BITS, Pilani - Goa Campus, Goa INDIA) have a problem of reporting renewal date-times on koha 3.14.08.000. I suppose it is there with newer versions as well. 1. *The Problem:* For all renewals, the date-time recorded in "issues. *lastreneweddate*" is the "today" date and *midnight 00:00:00 time* *regardless of the actual time of transaction*. This makes hourly or forenoon-afternoon circulation reports confusing to our library staff when they try to tally the numbers. For fresh issues and clear returns, the issuedate and returndate respectively are the timestamp itself. For renewals, the timestamp is exact but the lastrenewddate is the midnight time of today. 2. *The Source:* I have located the exact source of the problem thus: * In Circulation.pm (in lib/C4): The function AddRenewal takes $lastreneweddate as a last optional parameter. When NULL, the default is (line 2534): DateTime->now(timezone => C4:Context->tz())->ymd(). Thus only the ymd part of now is taken, and the hh:mm:ss become all zero by default. * In renew.pl (in intranet/cgi-bin/circ): at line 79: my $date_due = AddRenewal( undef, $item->itemnumber() ); passes only two parameters, hence lastreneweddate is null and defaults to midnight as above. * A similar story goes with line 90 in renewscript.pl in intranet/cgi-bin/reserve. 3. *A Solution:* I suppose removing the "->ymd()" part in line 2534 in Circulation.pm in lib/C4 will not cause any problem to any other part in koha, in fact it will make it more consistent and more accurate. I hope this simple rectification is incorporated after due examination. Thanks, Ramprasad Joshi CS-IS Dept BITS, Pilani - K K Birla Goa Campus Zuarinagar, GOA INDIA 403726 Phone +91 832 2580 121 Fax +91 832 2557033
Hi, On Fri, Sep 5, 2014 at 11:37 AM, Ramprasad S. Joshi <rsj@goa.bits-pilani.ac.in> wrote:
We (at BITS, Pilani - Goa Campus, Goa INDIA) have a problem of reporting renewal date-times on koha 3.14.08.000. I suppose it is there with newer versions as well.
I tested on 3.14.09 instance, by renewing an issued (and overdue) item. I didn't encounter the error you mention. A screenshot for your reference http://pandora.burntomlette.in/screenshots/koha/3.14.09/koha-bits-goa1.jpg cheers -indra -- Indranil Das Gupta Phone : +91-98300-20971 Blog : http://indradg.randomink.org/blog IRC : indradg on irc://irc.freenode.net Twitter : indradg -=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-==-=-=-=-=-=-=-=-=- Please exchange editable Office documents only in ODF Format. No other format is acceptable. Support Open Standards. For a free editor supporting ODF, please visit LibreOffice - http://www.documentfoundation.org
Hi, Thanks, but I'm perplexed. Even the latest &AddRenewal in Circulation.pm looks the same. At our end, yes, about 10% renewals have a different lastreneweddate than midnight, but even then it does not match the timestamp, while the returndate is exactly matching the timestamp. Why is there that ymd() in &AddRenewal? Ramprasad Joshi CS-IS Dept BITS, Pilani - K K Birla Goa Campus Zuarinagar, GOA INDIA 403726 Phone +91 832 2580 121 Fax +91 832 2557033 On 6 September 2014 00:24, Indranil Das Gupta <indradg@gmail.com> wrote:
Hi,
On Fri, Sep 5, 2014 at 11:37 AM, Ramprasad S. Joshi <rsj@goa.bits-pilani.ac.in> wrote:
We (at BITS, Pilani - Goa Campus, Goa INDIA) have a problem of reporting renewal date-times on koha 3.14.08.000. I suppose it is there with newer versions as well.
I tested on 3.14.09 instance, by renewing an issued (and overdue) item. I didn't encounter the error you mention. A screenshot for your reference http://pandora.burntomlette.in/screenshots/koha/3.14.09/koha-bits-goa1.jpg
cheers -indra
-- Indranil Das Gupta
Phone : +91-98300-20971 Blog : http://indradg.randomink.org/blog IRC : indradg on irc://irc.freenode.net Twitter : indradg
-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-==-=-=-=-=-=-=-=-=- Please exchange editable Office documents only in ODF Format. No other format is acceptable. Support Open Standards.
For a free editor supporting ODF, please visit LibreOffice - http://www.documentfoundation.org
For analysis purposes, I attach a csv of all 22 renewals we did in the last week. Ramprasad Joshi CS-IS Dept BITS, Pilani - K K Birla Goa Campus Zuarinagar, GOA INDIA 403726 Phone +91 832 2580 121 Fax +91 832 2557033 On 6 September 2014 00:24, Indranil Das Gupta <indradg@gmail.com> wrote:
Hi,
On Fri, Sep 5, 2014 at 11:37 AM, Ramprasad S. Joshi <rsj@goa.bits-pilani.ac.in> wrote:
We (at BITS, Pilani - Goa Campus, Goa INDIA) have a problem of reporting renewal date-times on koha 3.14.08.000. I suppose it is there with newer versions as well.
I tested on 3.14.09 instance, by renewing an issued (and overdue) item. I didn't encounter the error you mention. A screenshot for your reference http://pandora.burntomlette.in/screenshots/koha/3.14.09/koha-bits-goa1.jpg
cheers -indra
-- Indranil Das Gupta
Phone : +91-98300-20971 Blog : http://indradg.randomink.org/blog IRC : indradg on irc://irc.freenode.net Twitter : indradg
-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-==-=-=-=-=-=-=-=-=- Please exchange editable Office documents only in ODF Format. No other format is acceptable. Support Open Standards.
For a free editor supporting ODF, please visit LibreOffice - http://www.documentfoundation.org
participants (2)
-
Indranil Das Gupta -
Ramprasad S. Joshi