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

(-)a/Koha/Acquisition/Order.pm (-3 / +4 lines)
Lines 503-514 sub populate_with_prices_for_ordering { Link Here
503
503
504
    my $discount = $self->discount || 0;
504
    my $discount = $self->discount || 0;
505
    $discount /= 100 if $discount > 1;
505
    $discount /= 100 if $discount > 1;
506
    my $unitprice = $self->unitprice // 0;
506
507
507
    if ( $bookseller->listincgst ) {
508
    if ( $bookseller->listincgst ) {
508
509
509
        # The user entered the prices tax included
510
        # The user entered the prices tax included
510
        $self->unitprice( $self->unitprice + 0 );
511
        $self->unitprice($unitprice);
511
        $self->unitprice_tax_included( $self->unitprice );
512
        $self->unitprice_tax_included($unitprice);
512
        $self->rrp_tax_included( $self->rrp );
513
        $self->rrp_tax_included( $self->rrp );
513
514
514
        # price tax excluded = price tax included / ( 1 + tax rate )
515
        # price tax excluded = price tax included / ( 1 + tax rate )
Lines 536-542 sub populate_with_prices_for_ordering { Link Here
536
    } else {
537
    } else {
537
538
538
        # The user entered the prices tax excluded
539
        # The user entered the prices tax excluded
539
        $self->unitprice_tax_excluded( $self->unitprice );
540
        $self->unitprice_tax_excluded($unitprice);
540
        $self->rrp_tax_excluded( $self->rrp );
541
        $self->rrp_tax_excluded( $self->rrp );
541
542
542
        # price tax included = price tax excluded * ( 1 - tax rate )
543
        # price tax included = price tax excluded * ( 1 - tax rate )
(-)a/t/db_dependent/Budgets.t (-2 / +2 lines)
Lines 1-6 Link Here
1
#!/usr/bin/perl
1
#!/usr/bin/perl
2
use Modern::Perl;
2
use Modern::Perl;
3
use Test::More tests => 156;
3
use Test::More tests => 157;
4
use Test::NoWarnings;
4
use JSON;
5
use JSON;
5
6
6
BEGIN {
7
BEGIN {
7
- 

Return to bug 40371