Bug 24995: Add issuedate to table_account_fines and finest
authorLucas Gass <lucas@bywatersolutions.com>
Thu, 26 Mar 2020 21:17:42 +0000 (21:17 +0000)
committerMartin Renvoize <martin.renvoize@ptfs-europe.com>
Mon, 4 May 2020 08:44:43 +0000 (09:44 +0100)
TO TEST:
1. Have a patron with some fines on an item. Try accruing fines.
2. Go to the accounting tab and look at both the Tranaction tab and Make a payment Tab
3. No Issue Date
4. Apply patch
5. Check those tabs again and see the issue date displays.
6. Go to column configuration and try to hide the issuedate, make sure it hides properly. Try this for both tables. Also make sure other columns hide properly.
7. Sign off!

Signed-off-by: Andrew Fuerste-Henry <andrew@bywatersolutions.com>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>

admin/columns_settings.yml
koha-tmpl/intranet-tmpl/prog/en/modules/members/boraccount.tt
koha-tmpl/intranet-tmpl/prog/en/modules/members/pay.tt

index a0eabb7..54191ef 100644 (file)
@@ -634,6 +634,8 @@ modules:
         -
           columnname: returndate
         -
+          columnname: issuedate
+        -
           columnname: note
         -
           columnname: amount
@@ -671,6 +673,8 @@ modules:
         -
           columnname: returndate
         -
+          columnname: issuedate
+        -
           columnname: note
         -
           columnname: amount
index 8cabd86..3519812 100644 (file)
@@ -50,6 +50,7 @@
           <th>Barcode</th>
           <th>Due date</th>
           <th>Return date</th>
+          <th>Issue date</th>
           <th>Home library</th>
           <th>Note</th>
           <th>Amount</th>
@@ -71,6 +72,7 @@
       <td>[% IF ( account.itemnumber ) %]<a href="/cgi-bin/koha/catalogue/moredetail.pl?itemnumber=[% account.itemnumber | uri %]&amp;biblionumber=[% account.item.biblionumber | uri %]#item[% account.itemnumber | uri %]">[% account.item.barcode | html %]</a>[% END %]</td>
       <td>[% IF ( account.issue_id ) %][% account.checkout.date_due | $KohaDates as_due_date => 1 %][% END %]</td>
       <td>[% IF ( account.issue_id ) %][% account.checkout.returndate | $KohaDates with_hours => 1 %][% END %]</td>
+      <td>[% IF ( account.issue_id ) %][% account.checkout.issuedate | $KohaDates %][% END %]</td>
       <td>[% IF account.itemnumber %][% Branches.GetName( account.item.homebranch ) | html %][% END %]</td>
       <td>[% account.note | html_line_break %]</td>
       [% IF account.amount <= 0 %]<td class="credit" style="text-align: right;">[% ELSE %]<td class="debit" style="text-align: right;">[% END %][% account.amount | $Price %]</td>
   [% END %]
 <tfoot>
   <tr>
-    <td colspan="9">Total due</td>
+    <td colspan="10">Total due</td>
     [% IF ( totalcredit ) %]
         <td class="credit" style="text-align: right;">[% total | $Price %]</td>
     [% ELSE %]
                     var filteredValue = '^((?!0.00).*)$'; //Filter not matching 0.00 http://stackoverflow.com/a/406408
                     $(this).html('<i class="fa fa-filter"></i> '+txtInactivefilter);
                 }
-                table_account_fines.fnFilter(filteredValue, 9, true, false);
+                table_account_fines.fnFilter(filteredValue, 10, true, false);
                 $(this).toggleClass('filtered');
             });
 
index 406b3b0..d79c845 100644 (file)
@@ -52,6 +52,7 @@
     <th>Barcode</th>
     <th>Due date</th>
     <th>Return date</th>
+    <th>Issue date</th>
     <th class="NoSort">Payment note</th>
     <th>Amount</th>
     <th>Amount outstanding</th>
             [% line.checkout.returndate | $KohaDates with_hours => 1 %]
         [% END %]
     </td>
+    <td>
+        [% IF line.issue_id %]
+            [% line.checkout.issuedate | $KohaDates %]
+        [% END %]
+    </td>
     <td class="actions">
         <a href="#" class="add-note" data-accountlines_id="[% line.accountlines_id | html %]"><i class="fa fa-plus"></i> Add note</a>
         <span class="payment_note" id="payment_note_[% line.accountlines_id | html %]" style="display:none"><input type="text" size="10" name="payment_note_[% line.accountlines_id | html %]" value="" /> <a href="#" class="cancel-note"><i class="fa fa-remove"></i></a></span>
 
 <tfoot>
     <tr>
-        <td class="total" colspan="10">Total due:</td>
+        <td class="total" colspan="11">Total due:</td>
         <td style="text-align: right;">[% total | $Price %]</td>
     </tr>
     [% IF outstanding_credits.total_outstanding < 0 %]
         <tr>
-            <td class="total" colspan="10">Outstanding credits could be applied: </td>
+            <td class="total" colspan="11">Outstanding credits could be applied: </td>
             <td class="credit" style="text-align: right;"><button type="submit" id="apply_credits" name="apply_credits" value="apply_credits" class="btn btn-default btn-sm">Apply <strong class="credit">[% outstanding_credits.total_outstanding | $Price %]</strong></button></td>
         </tr>
         <tr>
-            <td class="total" colspan="10">Total due if credit applied:</td>
+            <td class="total" colspan="11">Total due if credit applied:</td>
             <td style="text-align: right;">[% total + outstanding_credits.total_outstanding | $Price %]</td>
         </tr>
     [% END %]