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

(-)a/acqui/ordered.pl (-1 / +2 lines)
Lines 58-64 SELECT Link Here
58
    ecost_tax_included, budgetdate, entrydate,
58
    ecost_tax_included, budgetdate, entrydate,
59
    aqbasket.booksellerid,
59
    aqbasket.booksellerid,
60
    aqbooksellers.name as vendorname,
60
    aqbooksellers.name as vendorname,
61
    GROUP_CONCAT(DISTINCT itype),
61
    GROUP_CONCAT(DISTINCT itype SEPARATOR '|') AS itypes,
62
    title
62
    title
63
FROM (aqorders, aqbasket)
63
FROM (aqorders, aqbasket)
64
LEFT JOIN biblio ON
64
LEFT JOIN biblio ON
Lines 93-98 my @ordered; Link Here
93
93
94
my $total = 0;
94
my $total = 0;
95
while ( my $data = $sth->fetchrow_hashref ) {
95
while ( my $data = $sth->fetchrow_hashref ) {
96
    $data->{'itemtypes'} = [split('\|', $data->{itypes})];
96
    my $left = $data->{'tleft'};
97
    my $left = $data->{'tleft'};
97
    if ( !$left || $left eq '' ) {
98
    if ( !$left || $left eq '' ) {
98
        $left = $data->{'quantity'};
99
        $left = $data->{'quantity'};
(-)a/acqui/spent.pl (-1 / +2 lines)
Lines 59-65 SELECT Link Here
59
    quantity-quantityreceived AS tleft,
59
    quantity-quantityreceived AS tleft,
60
    budgetdate, entrydate,
60
    budgetdate, entrydate,
61
    aqbasket.booksellerid,
61
    aqbasket.booksellerid,
62
    GROUP_CONCAT(DISTINCT itype),
62
    GROUP_CONCAT(DISTINCT itype SEPARATOR '|') as itypes,
63
    title,
63
    title,
64
    aqorders.invoiceid,
64
    aqorders.invoiceid,
65
    aqinvoices.invoicenumber,
65
    aqinvoices.invoicenumber,
Lines 106-111 my $subtotal = 0; Link Here
106
my @spent;
106
my @spent;
107
while ( my $data = $sth->fetchrow_hashref ) {
107
while ( my $data = $sth->fetchrow_hashref ) {
108
    my $recv = $data->{'quantityreceived'};
108
    my $recv = $data->{'quantityreceived'};
109
    $data->{'itemtypes'} = [split('\|', $data->{itypes})];
109
    if ( $recv > 0 ) {
110
    if ( $recv > 0 ) {
110
        my $rowtotal = $recv * get_rounded_price($data->{'unitprice_tax_included'});
111
        my $rowtotal = $recv * get_rounded_price($data->{'unitprice_tax_included'});
111
        $data->{'rowtotal'}  = sprintf( "%.2f", $rowtotal );
112
        $data->{'rowtotal'}  = sprintf( "%.2f", $rowtotal );
(-)a/koha-tmpl/intranet-tmpl/prog/en/modules/acqui/ordered.tt (-2 / +5 lines)
Lines 29-35 Link Here
29
    <th class="anti-the"> Title </th>
29
    <th class="anti-the"> Title </th>
30
    <th> Order </th>
30
    <th> Order </th>
31
    <th> Vendor </th>
31
    <th> Vendor </th>
32
    <th> Item type </th>
32
    <th> Item types </th>
33
    <th> Left on order </th>
33
    <th> Left on order </th>
34
    <th> Estimated cost per unit </th>
34
    <th> Estimated cost per unit </th>
35
    <th class="title-string"> Date ordered </th>
35
    <th class="title-string"> Date ordered </th>
Lines 55-61 Link Here
55
        <a href="/cgi-bin/koha/acqui/supplier.pl?booksellerid=[% order.booksellerid | uri %]">[% order.vendorname | html %]</a>
55
        <a href="/cgi-bin/koha/acqui/supplier.pl?booksellerid=[% order.booksellerid | uri %]">[% order.vendorname | html %]</a>
56
    </td>
56
    </td>
57
    <td class="cell">
57
    <td class="cell">
58
        [% ItemTypes.GetDescription( order.itype ) | html %]
58
        [% FOREACH itemtype IN order.itemtypes %]
59
            [% IF !(loop.count() mod 2) %] | [% END %]
60
            [% ItemTypes.GetDescription( itemtype ) | html %]
61
        [% END %]
59
    </td>
62
    </td>
60
    <td class="cell">
63
    <td class="cell">
61
        [% order.left | html %]
64
        [% order.left | html %]
(-)a/koha-tmpl/intranet-tmpl/prog/en/modules/acqui/spent.tt (-3 / +5 lines)
Lines 30-36 Link Here
30
           <th>Order</th>
30
           <th>Order</th>
31
           <th>Vendor</th>
31
           <th>Vendor</th>
32
           <th>Invoice</th>
32
           <th>Invoice</th>
33
           <th>Item type</th>
33
           <th>Item types</th>
34
           <th>Received</th>
34
           <th>Received</th>
35
           <th>Unit price</th>
35
           <th>Unit price</th>
36
           <th class="title-string">Date ordered</th>
36
           <th class="title-string">Date ordered</th>
Lines 56-62 Link Here
56
                <a href="/cgi-bin/koha/acqui/invoice.pl?invoiceid=[% order.invoiceid | uri %]">[% order.invoicenumber | html %]</a>
56
                <a href="/cgi-bin/koha/acqui/invoice.pl?invoiceid=[% order.invoiceid | uri %]">[% order.invoicenumber | html %]</a>
57
            </td>
57
            </td>
58
            <td class="cell">
58
            <td class="cell">
59
                [% ItemTypes.GetDescription( order.itype ) | html %]
59
                [% FOREACH itemtype IN order.itemtypes %]
60
                    [% IF !(loop.count() mod 2) %] | [% END %]
61
                    [% ItemTypes.GetDescription( itemtype ) | html %]
62
                [% END %]
60
            </td>
63
            </td>
61
            <td class="cell">
64
            <td class="cell">
62
                [% order.quantityreceived | html %]
65
                [% order.quantityreceived | html %]
63
- 

Return to bug 23397