Small fixes for the invoice dir changes
This commit is contained in:
parent
a32cb00846
commit
79e9190956
|
@ -1,7 +1,7 @@
|
|||
.sass-cache
|
||||
htpasswd
|
||||
db/*
|
||||
public/*.pdf
|
||||
public/*.tex
|
||||
public/invoices/*.pdf
|
||||
public/invoices/*.tex
|
||||
public/stylesheets/*.css
|
||||
tmp/*
|
||||
|
|
|
@ -850,11 +850,11 @@ module StopTime::Controllers
|
|||
elsif @format == "tex"
|
||||
tex_file = PUBLIC_DIR + "invoices/#{@number}.tex"
|
||||
_generate_invoice_tex(@number) unless tex_file.exist?
|
||||
redirect(Static, tex_file.basename)
|
||||
redirect R(Static, "") + "invoices/#{tex_file.basename}"
|
||||
elsif @format == "pdf"
|
||||
pdf_file = PUBLIC_DIR + "invoices/#{@number}.pdf"
|
||||
_generate_invoice_pdf(@number) unless pdf_file.exist?
|
||||
redirect(Static, pdf_file.basename)
|
||||
redirect R(Static, "") + "invoices/#{pdf_file.basename}"
|
||||
end
|
||||
end
|
||||
|
||||
|
|
Loading…
Reference in New Issue