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

(-)a/reports/guided_reports.pl (-9 / +4 lines)
Lines 900-921 if ( $op eq 'run' ) { Link Here
900
                            $authorised_lib{$id} = $name;
900
                            $authorised_lib{$id} = $name;
901
                        }
901
                        }
902
                    } elsif ( $authorised_value eq "debit_types" ) {
902
                    } elsif ( $authorised_value eq "debit_types" ) {
903
                        my $sth = $dbh->prepare(
903
                        my $sth = $dbh->prepare("SELECT code, description FROM account_debit_types ORDER BY code");
904
                            "SELECT code, concat(description,' (',code,')') as display_value FROM account_debit_types ORDER BY code"
905
                        );
906
                        $sth->execute;
904
                        $sth->execute;
907
                        while ( my ( $code, $description ) = $sth->fetchrow_array ) {
905
                        while ( my ( $code, $description ) = $sth->fetchrow_array ) {
908
                            push @authorised_values, $code;
906
                            push @authorised_values, $code;
909
                            $authorised_lib{$code} = $description;
907
                            $authorised_lib{$code} = "$description ($code)";
910
                        }
908
                        }
911
                    } elsif ( $authorised_value eq "credit_types" ) {
909
                    } elsif ( $authorised_value eq "credit_types" ) {
912
                        my $sth = $dbh->prepare(
910
                        my $sth = $dbh->prepare("SELECT code, description FROM account_credit_types ORDER BY code");
913
                            "SELECT code, concat(description,' (',code,')') as display_value FROM account_credit_types ORDER BY code"
914
                        );
915
                        $sth->execute;
911
                        $sth->execute;
916
                        while ( my ( $code, $description ) = $sth->fetchrow_array ) {
912
                        while ( my ( $code, $description ) = $sth->fetchrow_array ) {
917
                            push @authorised_values, $code;
913
                            push @authorised_values, $code;
918
                            $authorised_lib{$code} = $description;
914
                            $authorised_lib{$code} = "$description ($code)";
919
                        }
915
                        }
920
                    } else {
916
                    } else {
921
                        if ( Koha::AuthorisedValues->search( { category => $authorised_value } )->count ) {
917
                        if ( Koha::AuthorisedValues->search( { category => $authorised_value } )->count ) {
922
- 

Return to bug 40500