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

(-)a/admin/columns_settings.yml (+6 lines)
Lines 305-310 modules: Link Here
305
        -
305
        -
306
          columnname: description
306
          columnname: description
307
        -
307
        -
308
          columnname: barcode
309
        -
310
          columnname: date_due
311
        -
312
          columnname: returndate
313
        -
308
          columnname: note
314
          columnname: note
309
        -
315
        -
310
          columnname: amount
316
          columnname: amount
(-)a/koha-tmpl/intranet-tmpl/prog/en/modules/members/accountline-details.tt (+21 lines)
Lines 31-36 Link Here
31
                        <tr>
31
                        <tr>
32
                            <th class="title-string">Date</th>
32
                            <th class="title-string">Date</th>
33
                            <th>Description of charges</th>
33
                            <th>Description of charges</th>
34
                            <th>Barcode</th>
35
                            <th>Due date</th>
36
                            <th>Return date</th>
34
                            <th>Note</th>
37
                            <th>Note</th>
35
                            <th>Amount</th>
38
                            <th>Amount</th>
36
                            <th>Outstanding</th>
39
                            <th>Outstanding</th>
Lines 59-64 Link Here
59
                            </td>
62
                            </td>
60
63
61
                            <td>
64
                            <td>
65
                                [% IF ( accountline.itemnumber ) %]
66
                                    <a href="/cgi-bin/koha/catalogue/moredetail.pl?biblionumber=[% accountline.item.biblionumber | uri %]&amp;itemnumber=[% accountline.itemnumber | uri %]#item[% accountline.itemnumber | uri %]">[% accountline.item.barcode | html %]</a>
67
                                [% END %]
68
                            </td>
69
70
                            <td>
71
                                [% IF ( accountline.issue_id ) %]
72
                                    [% accountline.issue.date_due | $KohaDates with_hours => 1 | html %]
73
                                [% END %]
74
                            </td>
75
76
                            <td>
77
                                [% IF ( accountline.issue_id ) %]
78
                                    [% accountline.issue.returndate | $KohaDates with_hours => 1 | html %]
79
                                [% END %]
80
                            </td>
81
82
                            <td>
62
                                [% accountline.note | html_line_break %]
83
                                [% accountline.note | html_line_break %]
63
                            </td>
84
                            </td>
64
85
(-)a/koha-tmpl/intranet-tmpl/prog/en/modules/members/boraccount.tt (-1 / +7 lines)
Lines 46-51 Link Here
46
      <tr>
46
      <tr>
47
          <th class="title-string">Date</th>
47
          <th class="title-string">Date</th>
48
          <th>Description of charges</th>
48
          <th>Description of charges</th>
49
          <th>Barcode</th>
50
          <th>Due date</th>
51
          <th>Return date</th>
49
          <th>Home library</th>
52
          <th>Home library</th>
50
          <th>Note</th>
53
          <th>Note</th>
51
          <th>Amount</th>
54
          <th>Amount</th>
Lines 64-69 Link Here
64
        [%- IF account.payment_type %], [% AuthorisedValues.GetByCode('PAYMENT_TYPE', account.payment_type) | html %][% END %]
67
        [%- IF account.payment_type %], [% AuthorisedValues.GetByCode('PAYMENT_TYPE', account.payment_type) | html %][% END %]
65
        [%- IF account.description %], [% account.description | html %][% END %]
68
        [%- IF account.description %], [% account.description | html %][% END %]
66
        &nbsp;[% IF ( account.itemnumber ) %]<a href="/cgi-bin/koha/catalogue/moredetail.pl?biblionumber=[% account.item.biblionumber | uri %]&amp;itemnumber=[% account.itemnumber | uri %]">[% account.item.biblio.title | html %]</a>[% END %]</td>
69
        &nbsp;[% IF ( account.itemnumber ) %]<a href="/cgi-bin/koha/catalogue/moredetail.pl?biblionumber=[% account.item.biblionumber | uri %]&amp;itemnumber=[% account.itemnumber | uri %]">[% account.item.biblio.title | html %]</a>[% END %]</td>
70
      <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>
71
      <td>[% IF ( account.issue_id ) %][% account.issue.date_due | $KohaDates with_hours => 1 | html %][% END %]</td>
72
      <td>[% IF ( account.issue_id ) %][% account.issue.returndate | $KohaDates with_hours => 1 | html %][% END %]</td>
67
      <td>[% IF account.itemnumber %][% Branches.GetName( account.item.homebranch ) | html %][% END %]</td>
73
      <td>[% IF account.itemnumber %][% Branches.GetName( account.item.homebranch ) | html %][% END %]</td>
68
      <td>[% account.note | html_line_break %]</td>
74
      <td>[% account.note | html_line_break %]</td>
69
      [% IF account.amount <= 0 %]<td class="credit" style="text-align: right;">[% ELSE %]<td class="debit" style="text-align: right;">[% END %][% account.amount | $Price %]</td>
75
      [% IF account.amount <= 0 %]<td class="credit" style="text-align: right;">[% ELSE %]<td class="debit" style="text-align: right;">[% END %][% account.amount | $Price %]</td>
Lines 84-90 Link Here
84
  [% END %]
90
  [% END %]
85
<tfoot>
91
<tfoot>
86
  <tr>
92
  <tr>
87
    <td colspan="5">Total due</td>
93
    <td colspan="8">Total due</td>
88
    [% IF ( totalcredit ) %]
94
    [% IF ( totalcredit ) %]
89
        <td class="credit" style="text-align: right;">[% total | $Price %]</td>
95
        <td class="credit" style="text-align: right;">[% total | $Price %]</td>
90
    [% ELSE %]
96
    [% ELSE %]
(-)a/koha-tmpl/intranet-tmpl/prog/en/modules/members/pay.tt (-2 / +22 lines)
Lines 1-6 Link Here
1
[% USE raw %]
1
[% USE raw %]
2
[% USE Asset %]
2
[% USE Asset %]
3
[% USE Koha %]
3
[% USE Koha %]
4
[% USE KohaDates %]
4
[% USE AuthorisedValues %]
5
[% USE AuthorisedValues %]
5
[% USE Branches %]
6
[% USE Branches %]
6
[% USE Price %]
7
[% USE Price %]
Lines 43-48 Link Here
43
    <th>&nbsp;</th>
44
    <th>&nbsp;</th>
44
    <th>Fines &amp; charges</th>
45
    <th>Fines &amp; charges</th>
45
    <th>Description</th>
46
    <th>Description</th>
47
    <th>Barcode</th>
48
    <th>Due date</th>
49
    <th>Return date</th>
46
    <th>Payment note</th>
50
    <th>Payment note</th>
47
    <th>Account type</th>
51
    <th>Account type</th>
48
    <th>Amount</th>
52
    <th>Amount</th>
Lines 51-57 Link Here
51
</thead>
55
</thead>
52
<tfoot>
56
<tfoot>
53
<tr>
57
<tr>
54
    <td class="total" colspan="6">Total due:</td>
58
    <td class="total" colspan="9">Total due:</td>
55
[% IF outstanding_credits.total_outstanding < 0 %]
59
[% IF outstanding_credits.total_outstanding < 0 %]
56
    <td style="text-align: right;">[% total + outstanding_credits.total_outstanding | $Price %]</td>
60
    <td style="text-align: right;">[% total + outstanding_credits.total_outstanding | $Price %]</td>
57
[% ELSE %]
61
[% ELSE %]
Lines 74-79 Link Here
74
    [% END %]
78
    [% END %]
75
    <input type="hidden" name="itemnumber[% line.accountlines_id | html %]" value="[% line.itemnumber | html %]" />
79
    <input type="hidden" name="itemnumber[% line.accountlines_id | html %]" value="[% line.itemnumber | html %]" />
76
    <input type="hidden" name="description[% line.accountlines_id | html %]" value="[% line.description | html %]" />
80
    <input type="hidden" name="description[% line.accountlines_id | html %]" value="[% line.description | html %]" />
81
    <input type="hidden" name="issue_id[% line.accountlines_id | html %]" value="[% line.issue_id | html %]" />
77
    <input type="hidden" name="accounttype[% line.accountlines_id | html %]" value="[% line.accounttype | html %]" />
82
    <input type="hidden" name="accounttype[% line.accountlines_id | html %]" value="[% line.accounttype | html %]" />
78
    <input type="hidden" name="amount[% line.accountlines_id | html %]" value="[% line.amount | html %]" />
83
    <input type="hidden" name="amount[% line.accountlines_id | html %]" value="[% line.amount | html %]" />
79
    <input type="hidden" name="accountlines_id[% line.accountlines_id | html %]" value="[% line.accountlines_id | html %]" />
84
    <input type="hidden" name="accountlines_id[% line.accountlines_id | html %]" value="[% line.accountlines_id | html %]" />
Lines 105-111 Link Here
105
          [% CASE %][% line.accounttype | html %]
110
          [% CASE %][% line.accounttype | html %]
106
        [%- END -%]
111
        [%- END -%]
107
        [%- IF line.description %], [% line.description | html %][% END %]
112
        [%- IF line.description %], [% line.description | html %][% END %]
108
        [% IF line.title %]([% line.title | html %])[% END %]
113
        [% IF line.itemnumber %]([% line.item.biblio.title | html %])[% END %]
114
    </td>
115
    <td>
116
        [% IF line.itemnumber %]
117
            <a href="/cgi-bin/koha/catalogue/moredetail.pl?itemnumber=[% line.itemnumber | uri %]&amp;biblionumber=[% line.item.biblionumber | uri %]#item[% line.itemnumber | uri %]">[% line.item.barcode | html %]</a>
118
        [% END %]
119
    </td>
120
    <td>
121
        [% IF line.issue_id %]
122
            [% line.issue.date_due | $KohaDates with_hours => 1 | html %]
123
        [% END %]
124
    </td>
125
    <td>
126
        [% IF line.issue_id %]
127
            [% line.issue.returndate | $KohaDates with_hours => 1 | html %]
128
        [% END %]
109
    </td>
129
    </td>
110
    <td><input type="text" name="payment_note_[% line.accountlines_id | html %]" /></td>
130
    <td><input type="text" name="payment_note_[% line.accountlines_id | html %]" /></td>
111
    <td>[% line.accounttype | html %]</td>
131
    <td>[% line.accounttype | html %]</td>
(-)a/koha-tmpl/intranet-tmpl/prog/en/modules/members/printinvoice.tt (-5 / +11 lines)
Lines 21-43 Link Here
21
<table>
21
<table>
22
[% IF ( LibraryName ) %]
22
[% IF ( LibraryName ) %]
23
  <tr>
23
  <tr>
24
    <th colspan="5" class="centerednames">
24
    <th colspan="8" class="centerednames">
25
		<h3>[% LibraryName | html %]</h3>
25
		<h3>[% LibraryName | html %]</h3>
26
	</th>
26
	</th>
27
  </tr>
27
  </tr>
28
[% END %]
28
[% END %]
29
  <tr>
29
  <tr>
30
    <th colspan="5" class="centerednames">
30
    <th colspan="8" class="centerednames">
31
		<h2><u>INVOICE</u></h2>
31
		<h2><u>INVOICE</u></h2>
32
	</th>
32
	</th>
33
  </tr>
33
  </tr>
34
  <tr>
34
  <tr>
35
    <th colspan="5" class="centerednames">
35
    <th colspan="8" class="centerednames">
36
        <h2>[% Branches.GetName( patron.branchcode ) | html %]</h2>
36
        <h2>[% Branches.GetName( patron.branchcode ) | html %]</h2>
37
	</th>
37
	</th>
38
  </tr>
38
  </tr>
39
  <tr>
39
  <tr>
40
    <th colspan="5" >
40
    <th colspan="8" >
41
        Bill to: [% patron.firstname | html %] [% patron.surname | html %] <br />
41
        Bill to: [% patron.firstname | html %] [% patron.surname | html %] <br />
42
        Card number: [% patron.cardnumber | html %]<br />
42
        Card number: [% patron.cardnumber | html %]<br />
43
	</th>
43
	</th>
Lines 45-50 Link Here
45
  <tr>
45
  <tr>
46
	<th>Date</th>
46
	<th>Date</th>
47
    <th>Description of charges</th>
47
    <th>Description of charges</th>
48
    <th>Barcode</th>
49
    <th>Due date</th>
50
    <th>Return date</th>
48
    <th>Note</th>
51
    <th>Note</th>
49
    <th style="text-align:right;">Amount</th>
52
    <th style="text-align:right;">Amount</th>
50
    <th style="text-align:right;">Amount outstanding</th>
53
    <th style="text-align:right;">Amount outstanding</th>
Lines 57-62 Link Here
57
        [% PROCESS account_type_description account=account %]
60
        [% PROCESS account_type_description account=account %]
58
        [%- IF account.description %], [% account.description | html %][% END %]
61
        [%- IF account.description %], [% account.description | html %][% END %]
59
      </td>
62
      </td>
63
      <td>[% account.item.barcode | html %]</td>
64
      <td>[% account.issue.date_due | $KohaDates with_hours => 1 | html %]</td>
65
      <td>[% account.issue.returndate | $KohaDates with_hours => 1 | html %]</td>
60
      <td>[% account.note | html %]</td>
66
      <td>[% account.note | html %]</td>
61
      [% IF ( account.amountcredit ) %]<td class="credit">[% ELSE %]<td class="debit">[% END %][% account.amount | $Price %]</td>
67
      [% IF ( account.amountcredit ) %]<td class="credit">[% ELSE %]<td class="debit">[% END %][% account.amount | $Price %]</td>
62
      [% IF ( account.amountoutstandingcredit ) %]<td class="credit">[% ELSE %]<td class="debit">[% END %][% account.amountoutstanding | $Price %]</td>
68
      [% IF ( account.amountoutstandingcredit ) %]<td class="credit">[% ELSE %]<td class="debit">[% END %][% account.amountoutstanding | $Price %]</td>
Lines 65-71 Link Here
65
  [% END %]
71
  [% END %]
66
<tfoot>
72
<tfoot>
67
  <tr>
73
  <tr>
68
    <td colspan="4">Total outstanding dues as on date: </td>
74
    <td colspan="7">Total outstanding dues as on date: </td>
69
    [% IF ( totalcredit ) %]<td class="credit">[% ELSE %]<td class="debit">[% END %][% total | $Price %]</td>
75
    [% IF ( totalcredit ) %]<td class="credit">[% ELSE %]<td class="debit">[% END %][% total | $Price %]</td>
70
  </tr>
76
  </tr>
71
  </tfoot>
77
  </tfoot>
(-)a/members/pay.pl (-7 / +1 lines)
Lines 147-159 sub add_accounts_to_template { Link Here
147
    my $total = $account_lines->total_outstanding;
147
    my $total = $account_lines->total_outstanding;
148
    my @accounts;
148
    my @accounts;
149
    while ( my $account_line = $account_lines->next ) {
149
    while ( my $account_line = $account_lines->next ) {
150
        $account_line = $account_line->unblessed;
151
        if ( $account_line->{itemnumber} ) {
152
            my $item = Koha::Items->find( $account_line->{itemnumber} );
153
            my $biblio = $item->biblio;
154
            $account_line->{biblionumber} = $biblio->biblionumber;
155
            $account_line->{title}        = $biblio->title;
156
        }
157
        push @accounts, $account_line;
150
        push @accounts, $account_line;
158
    }
151
    }
159
    borrower_add_additional_fields($patron);
152
    borrower_add_additional_fields($patron);
Lines 198-203 sub redirect_to_paycollect { Link Here
198
    $redirect .=
191
    $redirect .=
199
      get_for_redirect( 'amountoutstanding', "amountoutstanding$line_no", 1 );
192
      get_for_redirect( 'amountoutstanding', "amountoutstanding$line_no", 1 );
200
    $redirect .= get_for_redirect( 'description', "description$line_no", 0 );
193
    $redirect .= get_for_redirect( 'description', "description$line_no", 0 );
194
    $redirect .= get_for_redirect( 'issue_id', "issue_id$line_no", 0 );
201
    $redirect .= get_for_redirect( 'title', "title$line_no", 0 );
195
    $redirect .= get_for_redirect( 'title', "title$line_no", 0 );
202
    $redirect .= get_for_redirect( 'itemnumber',   "itemnumber$line_no",   0 );
196
    $redirect .= get_for_redirect( 'itemnumber',   "itemnumber$line_no",   0 );
203
    $redirect .= get_for_redirect( 'accountlines_id', "accountlines_id$line_no", 0 );
197
    $redirect .= get_for_redirect( 'accountlines_id', "accountlines_id$line_no", 0 );
(-)a/members/printinvoice.pl (-2 / +4 lines)
Lines 55-61 output_and_exit_if_error( $input, $cookie, $template, { module => 'members', log Link Here
55
55
56
#get account details
56
#get account details
57
my $total = $patron->account->balance;
57
my $total = $patron->account->balance;
58
my $accountline = Koha::Account::Lines->find($accountlines_id)->unblessed;
58
my $accountline_object = Koha::Account::Lines->find($accountlines_id);
59
my $accountline = $accountline_object->unblessed;
60
$accountline->{'item'} = $accountline->{itemnumber} ? $accountline_object->item : "" ;
61
$accountline->{'issue'} = $accountline->{issue_id} ? $accountline_object->issue : "" ;
59
62
60
my $totalcredit;
63
my $totalcredit;
61
if ( $total <= 0 ) {
64
if ( $total <= 0 ) {
62
- 

Return to bug 19489