improved print layout
This commit is contained in:
parent
27f0511417
commit
11219e4aa4
@ -300,7 +300,9 @@ class Bills extends Controller
|
||||
{
|
||||
$bill = $this->prepareBill($bill);
|
||||
|
||||
return view($bill->template_path, compact('bill'));
|
||||
$view = view($bill->template_path, compact('bill'));
|
||||
|
||||
return mb_convert_encoding($view, 'HTML-ENTITIES', 'UTF-8');
|
||||
}
|
||||
|
||||
/**
|
||||
@ -317,7 +319,7 @@ class Bills extends Controller
|
||||
$currency_style = true;
|
||||
|
||||
$view = view($bill->template_path, compact('bill', 'currency_style'))->render();
|
||||
$html = mb_convert_encoding($view, 'HTML-ENTITIES');
|
||||
$html = mb_convert_encoding($view, 'HTML-ENTITIES', 'UTF-8');
|
||||
|
||||
$pdf = app('dompdf.wrapper');
|
||||
$pdf->loadHTML($html);
|
||||
|
@ -342,7 +342,9 @@ class Invoices extends Controller
|
||||
{
|
||||
$invoice = $this->prepareInvoice($invoice);
|
||||
|
||||
return view($invoice->template_path, compact('invoice'));
|
||||
$view = view($invoice->template_path, compact('invoice'));
|
||||
|
||||
return mb_convert_encoding($view, 'HTML-ENTITIES', 'UTF-8');
|
||||
}
|
||||
|
||||
/**
|
||||
@ -359,7 +361,7 @@ class Invoices extends Controller
|
||||
$currency_style = true;
|
||||
|
||||
$view = view($invoice->template_path, compact('invoice', 'currency_style'))->render();
|
||||
$html = mb_convert_encoding($view, 'HTML-ENTITIES');
|
||||
$html = mb_convert_encoding($view, 'HTML-ENTITIES', 'UTF-8');
|
||||
|
||||
$pdf = app('dompdf.wrapper');
|
||||
$pdf->loadHTML($html);
|
||||
|
2
public/css/custom.css
vendored
2
public/css/custom.css
vendored
@ -11,8 +11,6 @@
|
||||
font-style: normal;
|
||||
}
|
||||
|
||||
@import url(https://fonts.googleapis.com/css?family=Raleway:300,400,600);
|
||||
|
||||
/*--------General Button Hover--------*/
|
||||
.btn:hover
|
||||
{
|
||||
|
@ -1,4 +1,4 @@
|
||||
@extends('layouts.bill')
|
||||
@extends('layouts.print')
|
||||
|
||||
@section('title', trans_choice('general.bills', 1) . ': ' . $bill->bill_number)
|
||||
|
||||
|
@ -1,4 +1,4 @@
|
||||
@extends('layouts.invoice')
|
||||
@extends('layouts.print')
|
||||
|
||||
@section('title', trans_choice('general.invoices', 1) . ': ' . $invoice->invoice_number)
|
||||
|
||||
@ -261,6 +261,7 @@
|
||||
</div>
|
||||
</div>
|
||||
|
||||
@if ($invoice->footer)
|
||||
<div class="row">
|
||||
<div class="col-md-12">
|
||||
<div class="table-responsive">
|
||||
@ -268,9 +269,7 @@
|
||||
<tbody>
|
||||
<tr>
|
||||
<th>
|
||||
@if ($invoice->footer)
|
||||
{!! $invoice->footer !!}
|
||||
@endif
|
||||
{!! $invoice->footer !!}
|
||||
</th>
|
||||
</tr>
|
||||
</tbody>
|
||||
@ -278,5 +277,6 @@
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
@endif
|
||||
</div>
|
||||
@endsection
|
||||
|
@ -1,15 +0,0 @@
|
||||
<html lang="{{ app()->getLocale() }}">
|
||||
|
||||
@include('partials.bill.head')
|
||||
|
||||
<body onload="window.print();">
|
||||
|
||||
@stack('body_start')
|
||||
|
||||
@yield('content')
|
||||
|
||||
@stack('body_end')
|
||||
|
||||
</body>
|
||||
|
||||
</html>
|
@ -1,15 +0,0 @@
|
||||
<html lang="{{ app()->getLocale() }}">
|
||||
|
||||
@include('partials.invoice.head')
|
||||
|
||||
<body onload="window.print();">
|
||||
|
||||
@stack('body_start')
|
||||
|
||||
@yield('content')
|
||||
|
||||
@stack('body_end')
|
||||
|
||||
</body>
|
||||
|
||||
</html>
|
@ -2,6 +2,12 @@
|
||||
|
||||
@include('partials.admin.head')
|
||||
|
||||
<style type="text/css">
|
||||
* {
|
||||
font-family: DejaVu Sans, sans-serif !important;
|
||||
}
|
||||
</style>
|
||||
|
||||
<body onload="window.print();">
|
||||
|
||||
@stack('body_start')
|
||||
|
@ -1,7 +1,9 @@
|
||||
<head>
|
||||
@stack('head_start')
|
||||
<meta charset="utf-8">
|
||||
<meta http-equiv="X-UA-Compatible" content="IE=edge">
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1, shrink-to-fit=no">
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=utf-8; charset=ISO-8859-1" />
|
||||
|
||||
<title>@yield('title') - @setting('company.name')</title>
|
||||
|
||||
@ -18,12 +20,8 @@
|
||||
<link rel="stylesheet" href="{{ asset('public/vendor/@fortawesome/fontawesome-free/css/all.min.css') }}" type="text/css">
|
||||
|
||||
<!-- Css -->
|
||||
<!-- Argon -->
|
||||
<link rel="stylesheet" href="{{ asset('public/css/argon.css?v=1.1.0') }}" type="text/css">
|
||||
|
||||
<!-- Color -->
|
||||
<link rel="stylesheet" href="{{ asset('public/css/akaunting-color.css?v=' . version('short')) }}">
|
||||
<!-- Custom -->
|
||||
<link rel="stylesheet" href="{{ asset('public/css/custom.css?v=' . version('short')) }}">
|
||||
|
||||
@stack('css')
|
||||
|
@ -1,27 +0,0 @@
|
||||
<head>
|
||||
@stack('head_start')
|
||||
<meta charset="utf-8">
|
||||
<meta http-equiv="X-UA-Compatible" content="IE=edge">
|
||||
<!-- Tell the browser to be responsive to screen width -->
|
||||
<meta content="width=device-width, initial-scale=1, maximum-scale=1, user-scalable=no" name="viewport">
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=utf-8; charset=ISO-8859-1"/>
|
||||
|
||||
<title>@yield('title') - @setting('company.name')</title>
|
||||
|
||||
<!-- Css -->
|
||||
<!-- Argon -->
|
||||
<link rel="stylesheet" href="{{ asset('public/css/argon.css?v=1.1.0') }}" type="text/css">
|
||||
<!-- Color -->
|
||||
<link rel="stylesheet" href="{{ asset('public/css/akaunting-color.css?v=' . version('short')) }}">
|
||||
<!-- Custom -->
|
||||
<link rel="stylesheet" href="{{ asset('public/css/custom.css?v=' . version('short')) }}">
|
||||
|
||||
@stack('css')
|
||||
|
||||
@stack('stylesheet')
|
||||
|
||||
@stack('js')
|
||||
|
||||
@stack('scripts')
|
||||
@stack('head_end')
|
||||
</head>
|
@ -1,27 +0,0 @@
|
||||
<head>
|
||||
@stack('head_start')
|
||||
<meta charset="utf-8">
|
||||
<meta http-equiv="X-UA-Compatible" content="IE=edge">
|
||||
<!-- Tell the browser to be responsive to screen width -->
|
||||
<meta content="width=device-width, initial-scale=1, maximum-scale=1, user-scalable=no" name="viewport">
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=utf-8; charset=ISO-8859-1"/>
|
||||
|
||||
<title>@yield('title') - @setting('company.name')</title>
|
||||
|
||||
<!-- Css -->
|
||||
<!-- Argon -->
|
||||
<link rel="stylesheet" href="{{ asset('public/css/argon.css?v=1.1.0') }}" type="text/css">
|
||||
<!-- Color -->
|
||||
<link rel="stylesheet" href="{{ asset('public/css/akaunting-color.css?v=' . version('short')) }}">
|
||||
<!-- Custom -->
|
||||
<link rel="stylesheet" href="{{ asset('public/css/custom.css?v=' . version('short')) }}">
|
||||
|
||||
@stack('css')
|
||||
|
||||
@stack('stylesheet')
|
||||
|
||||
@stack('js')
|
||||
|
||||
@stack('scripts')
|
||||
@stack('head_end')
|
||||
</head>
|
Loading…
x
Reference in New Issue
Block a user