Bug 14150 - Field issues.date_due does not display in ISSUESLIP or ISSUEQSLIP
Summary: Field issues.date_due does not display in ISSUESLIP or ISSUEQSLIP
Status: CLOSED FIXED
Alias: None
Product: Koha
Classification: Unclassified
Component: Patrons (show other bugs)
Version: unspecified
Hardware: All All
: P5 - low normal (vote)
Assignee: Bugs List
QA Contact: Testopia
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2015-05-05 17:58 UTC by Barton Chittenden
Modified: 2017-03-14 11:14 UTC (History)
8 users (show)

See Also:
Change sponsored?: ---
Patch complexity: ---
Who signed the patch off:
Text to go in the release notes:
Version(s) released in:


Attachments
SAMPLE ISSUESLIP (may be used for testing). (782 bytes, text/plain)
2015-05-05 17:58 UTC, Barton Chittenden
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Barton Chittenden 2015-05-05 17:58:05 UTC
Created attachment 38871 [details]
SAMPLE ISSUESLIP (may be used for testing).

The field <<issues.date_due>> will not display in the ISSUESLIP or ISSUEQSLIP notices, when printed inside <checkedout> or <overdue> tags.

Steps to replicate:

1) Go to tools->notices and slips, edit ISSUESLIP for all branches.
2) Put the following text in the EMAIL template:

<checkedout>
Checked out: Date Due: <<issues.date_due>>
</checkedout>

<overdue>
Overdue: Date Due: <<issues.date_due>>
</overdue>

3) Set the following fields in ISSUESLIP (I don't know that any of these matter)
   Name: Issue Slip
   HTML Message: [checked]
   Message Subject: Issue Slip
4) Check out an item
5) Click Print Issue Slip

You will see that the issue slip does not print issues.date_due

the same problem affects ISSUEQSLIP.
Comment 1 Barton Chittenden 2015-05-05 17:59:23 UTC
Note that items.onloan *will* print correctly; this is an acceptable work-around.
Comment 2 Christopher Brannon 2015-05-14 18:01:16 UTC
Barton,
Does this affect only those two slips, or does it affect any notices as well?

Christopher
Comment 3 Mason James 2015-05-18 22:05:19 UTC
a bit more info about the bug here, too :)

http://bywatersolutions.com/2015/05/18/koha-slips/
Comment 4 Christopher Brannon 2015-05-18 22:06:28 UTC
(In reply to Barton Chittenden from comment #1)
> Note that items.onloan *will* print correctly; this is an acceptable
> work-around.

This is acceptable if you are not using hourly loans.  items.onloan does not display the time.
Comment 5 Katrin Fischer 2015-05-24 22:53:42 UTC
I can't reproduce this issue on current master. The due date prints fine for me including the due time. 

Can you please specify the exact version this occurs and if you still see it happen?

These are my templates:

ISSUESLIP
<h3><<branches.branchname>></h3>
Checked out to <<borrowers.title>> <<borrowers.firstname>> <<borrowers.initials>> <<borrowers.surname>> <br />
(<<borrowers.cardnumber>>) <br />

<<today>><br />

<h4>Checked Out</h4>
<checkedout>
<p>
<<biblio.title>> <br />
Barcode: <<items.barcode>><br />
Date due: <<issues.date_due>><br />
</p>
</checkedout>

<h4>Overdues</h4>
<overdue>
<p>
<<biblio.title>> <br />
Barcode: <<items.barcode>><br />
Date due: <<issues.date_due>><br />
</p>
</overdue>

<hr>

<h4 style="text-align: center; font-style:italic;">News</h4>
<news>
<div class="newsitem">
<h5 style="margin-bottom: 1px; margin-top: 1px"><b><<opac_news.title>></b></h5>
<p style="margin-bottom: 1px; margin-top: 1px"><<opac_news.new>></p>
<p class="newsfooter" style="font-size: 8pt; font-style:italic; margin-bottom: 1px; margin-top: 1px">Posted on <<opac_news.timestamp>></p>
<hr />
</div>
</news>

ISSUEQSLIP
<h3><<branches.branchname>></h3>
Checked out to <<borrowers.title>> <<borrowers.firstname>> <<borrowers.initials>> <<borrowers.surname>> <br />
(<<borrowers.cardnumber>>) <br />

<<today>><br />

<h4>Checked Out Today</h4>
<checkedout>
<p>
<<biblio.title>> <br />
Barcode: <<items.barcode>><br />
Date due: <<issues.date_due>><br />
</p>
</checkedout>
Comment 6 Katrin Fischer 2015-05-24 22:58:50 UTC
I did some more tests - this problem appears in 3.18.6, but is fixed on the current 3.18.x branch, that will be 3.18.7.
Comment 7 Christopher Brannon 2017-03-13 14:35:21 UTC
(In reply to Katrin Fischer from comment #6)
> I did some more tests - this problem appears in 3.18.6, but is fixed on the
> current 3.18.x branch, that will be 3.18.7.

Katrin,
Please confirm with master.  I am in 3.22, and I see that issues.date_due is producing a date, but I do not see a time stamp.  Shouldn't this value produce a timestamp for hourly loans, or do hourly loans have to be turned on in order for it to produce a time stamp?

Christopher
Comment 8 Christopher Brannon 2017-03-13 14:45:56 UTC
On further inspection, it appears that in 3.22.8, issues.date_due shows the date but not the time.  In master, I see that issues.date_due includes the time as well.  Can't find the bug that changed this.
Comment 9 Katrin Fischer 2017-03-14 11:14:25 UTC
Maybe something to check: check if the time shows if you do an hourly loan with the time not bing 23:59 - we might just not show the time in this case.