diff --git a/app/Abstracts/View/Components/DocumentShow.php b/app/Abstracts/View/Components/DocumentShow.php index 66734686c..8cf844f77 100644 --- a/app/Abstracts/View/Components/DocumentShow.php +++ b/app/Abstracts/View/Components/DocumentShow.php @@ -392,7 +392,7 @@ abstract class DocumentShow extends Component $this->routeButtonEdit = $this->getRouteButtonEdit($type, $routeButtonEdit); $this->routeButtonDuplicate = $this->getRouteButtonDuplicate($type, $routeButtonDuplicate); $this->routeButtonPrint = $this->getRouteButtonPrint($type, $routeButtonPrint); - $this->routeButtonPdf = $this->getRouteButtonPrint($type, $routeButtonPdf); + $this->routeButtonPdf = $this->getRouteButtonPdf($type, $routeButtonPdf); $this->routeButtonCancelled = $this->getRouteButtonCancelled($type, $routeButtonCancelled); $this->routeButtonCustomize = $this->getRouteButtonCustomize($type, $routeButtonCustomize); $this->routeButtonDelete = $this->getRouteButtonDelete($type, $routeButtonDelete); diff --git a/app/Http/Controllers/Purchases/Bills.php b/app/Http/Controllers/Purchases/Bills.php index 672ee3309..f13c22f7d 100644 --- a/app/Http/Controllers/Purchases/Bills.php +++ b/app/Http/Controllers/Purchases/Bills.php @@ -293,7 +293,7 @@ class Bills extends Controller $pdf = app('dompdf.wrapper'); $pdf->loadHTML($html); - $file_name = $this->getBillFileName($bill); + $file_name = $this->getDocumentFileName($bill); return $pdf->download($file_name); }