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

(-)a/reports/acquisitions_stats.pl (-1 / +1 lines)
Lines 108-114 if ($do_it) { Link Here
108
        }
108
        }
109
        print $sep. @$results[0]->{total};
109
        print $sep. @$results[0]->{total};
110
    }
110
    }
111
    exit(1);
111
    exit;
112
}
112
}
113
else {
113
else {
114
    my $dbh = C4::Context->dbh;
114
    my $dbh = C4::Context->dbh;
(-)a/reports/bor_issues_top.pl (-1 / +1 lines)
Lines 102-108 if ($do_it) { Link Here
102
		print join($sep, map {$_->{totalcol}} @$cols);
102
		print join($sep, map {$_->{totalcol}} @$cols);
103
        print $sep.@$results[0]->{total};
103
        print $sep.@$results[0]->{total};
104
    }
104
    }
105
    exit(0);
105
    exit;
106
}
106
}
107
107
108
my $dbh = C4::Context->dbh;
108
my $dbh = C4::Context->dbh;
(-)a/reports/borrowers_out.pl (-2 / +2 lines)
Lines 69-75 if ($do_it) { Link Here
69
# Printing results to screen
69
# Printing results to screen
70
        $template->param(mainloop => $results);
70
        $template->param(mainloop => $results);
71
        output_html_with_http_headers $input, $cookie, $template->output;
71
        output_html_with_http_headers $input, $cookie, $template->output;
72
        exit(1);
72
        exit;
73
    } else {
73
    } else {
74
# Printing to a csv file
74
# Printing to a csv file
75
        print $input->header(-type => 'application/vnd.sun.xml.calc',
75
        print $input->header(-type => 'application/vnd.sun.xml.calc',
Lines 103-109 if ($do_it) { Link Here
103
            print $sep.$col->{totalcol};
103
            print $sep.$col->{totalcol};
104
        }
104
        }
105
        print $sep.@$results[0]->{total};
105
        print $sep.@$results[0]->{total};
106
        exit(1);
106
        exit;
107
    }
107
    }
108
# Displaying choices
108
# Displaying choices
109
} else {
109
} else {
(-)a/reports/borrowers_stats.pl (-1 / +1 lines)
Lines 107-113 if ($do_it) { Link Here
107
		}
107
		}
108
		print $sep.@$results[0]->{total};
108
		print $sep.@$results[0]->{total};
109
	}
109
	}
110
	exit(1);	# exit after do_it, regardless
110
	exit;	# exit after do_it, regardless
111
} else {
111
} else {
112
	my $dbh = C4::Context->dbh;
112
	my $dbh = C4::Context->dbh;
113
	my $req;
113
	my $req;
(-)a/reports/cat_issues_top.pl (-2 / +2 lines)
Lines 75-81 if ($do_it) { Link Here
75
        $template->param(mainloop => $results,
75
        $template->param(mainloop => $results,
76
                        limit => $limit);
76
                        limit => $limit);
77
        output_html_with_http_headers $input, $cookie, $template->output;
77
        output_html_with_http_headers $input, $cookie, $template->output;
78
        exit(1);
78
        exit;
79
    } else {
79
    } else {
80
# Printing to a csv file
80
# Printing to a csv file
81
        print $input->header(-type => 'application/vnd.sun.xml.calc',
81
        print $input->header(-type => 'application/vnd.sun.xml.calc',
Lines 108-114 if ($do_it) { Link Here
108
            print $sep.$col->{totalcol};
108
            print $sep.$col->{totalcol};
109
        }
109
        }
110
        print $sep.@$results[0]->{total};
110
        print $sep.@$results[0]->{total};
111
        exit(1);
111
        exit;
112
    }
112
    }
113
# Displaying choices
113
# Displaying choices
114
} else {
114
} else {
(-)a/reports/catalogue_out.pl (-1 / +1 lines)
Lines 96-102 if ($do_it) { Link Here
96
        }
96
        }
97
        print $sep.@$results[0]->{total};
97
        print $sep.@$results[0]->{total};
98
    }
98
    }
99
	exit(1); # in either case, exit after do_it
99
    exit; # in either case, exit after do_it
100
}
100
}
101
101
102
# Displaying choices (i.e., not do_it)
102
# Displaying choices (i.e., not do_it)
(-)a/reports/catalogue_stats.pl (-2 / +2 lines)
Lines 74-80 if ($do_it) { Link Here
74
	if ($output eq "screen"){
74
	if ($output eq "screen"){
75
		$template->param(mainloop => $results);
75
		$template->param(mainloop => $results);
76
		output_html_with_http_headers $input, $cookie, $template->output;
76
		output_html_with_http_headers $input, $cookie, $template->output;
77
		exit(1);
77
		exit;
78
	} else {
78
	} else {
79
		print $input->header(-type => 'application/vnd.sun.xml.calc',
79
		print $input->header(-type => 'application/vnd.sun.xml.calc',
80
                                     -encoding    => 'utf-8',
80
                                     -encoding    => 'utf-8',
Lines 102-108 if ($do_it) { Link Here
102
			print $sep.$col->{totalcol};
102
			print $sep.$col->{totalcol};
103
		}
103
		}
104
		print $sep.@$results[0]->{total};
104
		print $sep.@$results[0]->{total};
105
		exit(1);
105
		exit;
106
	}
106
	}
107
} else {
107
} else {
108
	my $dbh = C4::Context->dbh;
108
	my $dbh = C4::Context->dbh;
(-)a/reports/issues_avg_stats.pl (-2 / +2 lines)
Lines 77-83 if ($do_it) { Link Here
77
# Printing results to screen
77
# Printing results to screen
78
        $template->param(mainloop => $results);
78
        $template->param(mainloop => $results);
79
        output_html_with_http_headers $input, $cookie, $template->output;
79
        output_html_with_http_headers $input, $cookie, $template->output;
80
        exit(1);
80
        exit;
81
    } else {
81
    } else {
82
# Printing to a csv file
82
# Printing to a csv file
83
        print $input->header(-type => 'application/vnd.sun.xml.calc',
83
        print $input->header(-type => 'application/vnd.sun.xml.calc',
Lines 110-116 if ($do_it) { Link Here
110
            print $sep.$col->{totalcol};
110
            print $sep.$col->{totalcol};
111
        }
111
        }
112
        print $sep.@$results[0]->{total};
112
        print $sep.@$results[0]->{total};
113
        exit(1);
113
        exit;
114
    }
114
    }
115
# Displaying choices
115
# Displaying choices
116
} else {
116
} else {
(-)a/reports/issues_stats.pl (-1 / +1 lines)
Lines 123-129 if ($do_it) { Link Here
123
		print map {$sep.$_->{totalcol}} @$cols;
123
		print map {$sep.$_->{totalcol}} @$cols;
124
        print $sep.@$results[0]->{total};
124
        print $sep.@$results[0]->{total};
125
	}
125
	}
126
	exit(1); # exit either way after $do_it
126
	exit; # exit either way after $do_it
127
}
127
}
128
128
129
my $dbh = C4::Context->dbh;
129
my $dbh = C4::Context->dbh;
(-)a/reports/reserves_stats.pl (-1 / +1 lines)
Lines 130-136 if ($do_it) { Link Here
130
		print map {$sep.$_->{totalcol}} @$cols;
130
		print map {$sep.$_->{totalcol}} @$cols;
131
        print $sep.@$results[0]->{total};
131
        print $sep.@$results[0]->{total};
132
	}
132
	}
133
	exit(1); # exit either way after $do_it
133
	exit; # exit either way after $do_it
134
}
134
}
135
135
136
my $dbh = C4::Context->dbh;
136
my $dbh = C4::Context->dbh;
(-)a/reports/serials_stats.pl (-2 / +1 lines)
Lines 125-131 if($do_it){ Link Here
125
            print $item->{startdate}.$sep;
125
            print $item->{startdate}.$sep;
126
            print $item->{enddate}."\n";
126
            print $item->{enddate}."\n";
127
        }
127
        }
128
        exit(1);
128
        exit;
129
    }
129
    }
130
}else{
130
}else{
131
    ## We generate booksellers list
131
    ## We generate booksellers list
132
- 

Return to bug 7829