Merge branch 'pdf-issue' into 'master'

fix Pdf issue

See merge request mohit.panjvani/crater-web!136
This commit is contained in:
Mohit Panjwani
2019-12-12 14:55:04 +00:00
8 changed files with 47 additions and 37 deletions

View File

@ -50,7 +50,7 @@ export default {
Layout.set('layout-default') Layout.set('layout-default')
}, },
created() { created () {
this.bootstrap().then((res) => { this.bootstrap().then((res) => {
this.setInitialCompany() this.setInitialCompany()
}) })
@ -59,7 +59,7 @@ export default {
methods: { methods: {
...mapActions(['bootstrap']), ...mapActions(['bootstrap']),
...mapActions('company', ['setSelectedCompany']), ...mapActions('company', ['setSelectedCompany']),
setInitialCompany() { setInitialCompany () {
let selectedCompany = Ls.get('selectedCompany') !== null let selectedCompany = Ls.get('selectedCompany') !== null
if (selectedCompany) { if (selectedCompany) {

View File

@ -3,9 +3,11 @@
<head> <head>
<title>Estimate</title> <title>Estimate</title>
{{-- <link href="https://fonts.googleapis.com/css?family=Poppins&display=swap" rel="stylesheet"> --}} {{-- <link href="https://fonts.googleapis.com/css?family=Poppins&display=swap" rel="stylesheet"> --}}
<meta http-equiv="Content-Type" content="text/html; charset=utf-8"/>
<style type="text/css"> <style type="text/css">
body { body {
font-family: 'Roboto', sans-serif; font-family: "DejaVu Sans";
} }
html { html {
@ -58,13 +60,13 @@
margin-left:160px; margin-left:160px;
} }
.header { .header {
font-family: 'Roboto', sans-serif; font-family: "DejaVu Sans";
font-size: 20px; font-size: 20px;
color: rgba(0, 0, 0, 0.7); color: rgba(0, 0, 0, 0.7);
} }
.TextColor1 { .TextColor1 {
font-family: 'Roboto', sans-serif; font-family: "DejaVu Sans";
font-size: 16px; font-size: 16px;
color: rgba(0, 0, 0, 0.5); color: rgba(0, 0, 0, 0.5);
} }
@ -339,7 +341,7 @@
} }
.notes { .notes {
font-family: 'Roboto', sans-serif; font-family: "DejaVu Sans";
font-style: normal; font-style: normal;
font-weight: 300; font-weight: 300;
font-size: 12px; font-size: 12px;
@ -352,7 +354,7 @@
} }
.notes-label { .notes-label {
font-family: 'Roboto', sans-serif; font-family: "DejaVu Sans";
font-style: normal; font-style: normal;
font-weight: normal; font-weight: normal;
font-size: 15px; font-size: 15px;

View File

@ -3,9 +3,11 @@
<head> <head>
<title>Estimate</title> <title>Estimate</title>
{{-- <link href="https://fonts.googleapis.com/css?family=Poppins&display=swap" rel="stylesheet"> --}} {{-- <link href="https://fonts.googleapis.com/css?family=Poppins&display=swap" rel="stylesheet"> --}}
<meta http-equiv="Content-Type" content="text/html; charset=utf-8"/>
<style type="text/css"> <style type="text/css">
body { body {
font-family: 'Roboto', sans-serif; font-family: "DejaVu Sans";
} }
html { html {
@ -62,13 +64,13 @@
margin-left:160px; margin-left:160px;
} }
.header { .header {
font-family: 'Roboto', sans-serif; font-family: "DejaVu Sans";
font-size: 20px; font-size: 20px;
color: rgba(0, 0, 0, 0.7); color: rgba(0, 0, 0, 0.7);
} }
.TextColor1 { .TextColor1 {
font-family: 'Roboto', sans-serif; font-family: "DejaVu Sans";
font-size: 16px; font-size: 16px;
color: rgba(0, 0, 0, 0.5); color: rgba(0, 0, 0, 0.5);
} }
@ -364,7 +366,7 @@
} }
.notes { .notes {
font-family: 'Roboto', sans-serif; font-family: "DejaVu Sans";
font-style: normal; font-style: normal;
font-weight: 300; font-weight: 300;
font-size: 12px; font-size: 12px;
@ -377,7 +379,7 @@
} }
.notes-label { .notes-label {
font-family: 'Roboto', sans-serif; font-family: "DejaVu Sans";
font-style: normal; font-style: normal;
font-weight: normal; font-weight: normal;
font-size: 15px; font-size: 15px;

View File

@ -3,9 +3,11 @@
<head> <head>
<title>Estimate</title> <title>Estimate</title>
{{-- <link href="https://fonts.googleapis.com/css?family=Poppins&display=swap" rel="stylesheet"> --}} {{-- <link href="https://fonts.googleapis.com/css?family=Poppins&display=swap" rel="stylesheet"> --}}
<meta http-equiv="Content-Type" content="text/html; charset=utf-8"/>
<style type="text/css"> <style type="text/css">
body { body {
font-family: 'Roboto', sans-serif; font-family: "DejaVu Sans";
} }
html { html {
@ -64,13 +66,13 @@
margin-left:160px; margin-left:160px;
} }
.header { .header {
font-family: 'Roboto', sans-serif; font-family: "DejaVu Sans";
font-size: 20px; font-size: 20px;
color: rgba(0, 0, 0, 0.7); color: rgba(0, 0, 0, 0.7);
} }
.TextColor1 { .TextColor1 {
font-family: 'Roboto', sans-serif; font-family: "DejaVu Sans";
font-size: 16px; font-size: 16px;
color: rgba(0, 0, 0, 0.5); color: rgba(0, 0, 0, 0.5);
} }
@ -372,7 +374,7 @@
} }
.notes { .notes {
font-family: 'Roboto', sans-serif; font-family: "DejaVu Sans";
font-style: normal; font-style: normal;
font-weight: 300; font-weight: 300;
font-size: 12px; font-size: 12px;
@ -385,7 +387,7 @@
} }
.notes-label { .notes-label {
font-family: 'Roboto', sans-serif; font-family: "DejaVu Sans";
font-style: normal; font-style: normal;
font-weight: normal; font-weight: normal;
font-size: 15px; font-size: 15px;

View File

@ -3,9 +3,11 @@
<head> <head>
<title>Invoice</title> <title>Invoice</title>
{{-- <link href="https://fonts.googleapis.com/css?family=Poppins&display=swap" rel="stylesheet"> --}} {{-- <link href="https://fonts.googleapis.com/css?family=Poppins&display=swap" rel="stylesheet"> --}}
<meta http-equiv="Content-Type" content="text/html; charset=utf-8"/>
<style type="text/css"> <style type="text/css">
body { body {
font-family: 'Roboto', sans-serif; font-family: "DejaVu Sans";
} }
html { html {
@ -59,13 +61,13 @@
margin-left:160px; margin-left:160px;
} }
.header { .header {
font-family: 'Roboto', sans-serif; font-family: "DejaVu Sans";
font-size: 20px; font-size: 20px;
color: rgba(0, 0, 0, 0.7); color: rgba(0, 0, 0, 0.7);
} }
.TextColor1 { .TextColor1 {
font-family: 'Roboto', sans-serif; font-family: "DejaVu Sans";
font-size: 16px; font-size: 16px;
color: rgba(0, 0, 0, 0.5); color: rgba(0, 0, 0, 0.5);
} }
@ -346,7 +348,7 @@
} }
.notes { .notes {
font-family: 'Roboto', sans-serif; font-family: "DejaVu Sans";
font-style: normal; font-style: normal;
font-weight: 300; font-weight: 300;
font-size: 12px; font-size: 12px;
@ -359,7 +361,7 @@
} }
.notes-label { .notes-label {
font-family: 'Roboto', sans-serif; font-family: "DejaVu Sans";
font-style: normal; font-style: normal;
font-weight: normal; font-weight: normal;
font-size: 15px; font-size: 15px;
@ -416,9 +418,8 @@
<div class="bill-add"> <div class="bill-add">
<div class="bill-address-container"> <div class="bill-address-container">
@include('app.pdf.invoice.partials.billing-address') @include('app.pdf.invoice.partials.billing-address')
</div> </div>
@if($invoice->user->billingaddress->name || $invoice->user->billingaddress->address_street_1 || $invoice->user->billingaddress->address_street_2 || $invoice->user->billingaddress->country || $invoice->user->billingaddress->state || $invoice->user->billingaddress->city || $invoice->user->billingaddress->zip || $invoice->user->billingaddress->phone) @if($invoice->user->billingaddress && ($invoice->user->billingaddress->name || $invoice->user->billingaddress->address_street_1 || $invoice->user->billingaddress->address_street_2 || $invoice->user->billingaddress->country || $invoice->user->billingaddress->state || $invoice->user->billingaddress->city || $invoice->user->billingaddress->zip || $invoice->user->billingaddress->phone))
<div class="ship-address-container"> <div class="ship-address-container">
@else @else
<div class="ship-address-container " style="float:left;padding-left:0px;"> <div class="ship-address-container " style="float:left;padding-left:0px;">

View File

@ -3,9 +3,10 @@
<head> <head>
<title>Invoice</title> <title>Invoice</title>
{{-- <link href="https://fonts.googleapis.com/css?family=Poppins&display=swap" rel="stylesheet"> --}} {{-- <link href="https://fonts.googleapis.com/css?family=Poppins&display=swap" rel="stylesheet"> --}}
<meta http-equiv="Content-Type" content="text/html; charset=utf-8"/>
<style type="text/css"> <style type="text/css">
body { body {
font-family: 'Roboto', sans-serif; font-family: "DejaVu Sans";
} }
html { html {
@ -61,13 +62,13 @@
margin-left:160px; margin-left:160px;
} }
.header { .header {
font-family: 'Roboto', sans-serif; font-family: "DejaVu Sans";
font-size: 20px; font-size: 20px;
color: rgba(0, 0, 0, 0.7); color: rgba(0, 0, 0, 0.7);
} }
.TextColor1 { .TextColor1 {
font-family: 'Roboto', sans-serif; font-family: "DejaVu Sans";
font-size: 16px; font-size: 16px;
color: rgba(0, 0, 0, 0.5); color: rgba(0, 0, 0, 0.5);
} }
@ -373,7 +374,7 @@
} }
.notes { .notes {
font-family: 'Roboto', sans-serif; font-family: "DejaVu Sans";
font-style: normal; font-style: normal;
font-weight: 300; font-weight: 300;
font-size: 12px; font-size: 12px;
@ -386,7 +387,7 @@
} }
.notes-label { .notes-label {
font-family: 'Roboto', sans-serif; font-family: "DejaVu Sans";
font-style: normal; font-style: normal;
font-weight: normal; font-weight: normal;
font-size: 15px; font-size: 15px;
@ -431,7 +432,7 @@
<div class="ship-address-container"> <div class="ship-address-container">
@include('app.pdf.invoice.partials.shipping-address') @include('app.pdf.invoice.partials.shipping-address')
</div> </div>
@if($invoice->user->shippingaddress->name || $invoice->user->shippingaddress->address_street_1 || $invoice->user->shippingaddress->address_street_2 || $invoice->user->shippingaddress->country || $invoice->user->shippingaddress->state || $invoice->user->shippingaddress->city || $invoice->user->shippingaddress->zip || $invoice->user->phone) @if($invoice->user->shippingaddress && ($invoice->user->shippingaddress->name || $invoice->user->shippingaddress->address_street_1 || $invoice->user->shippingaddress->address_street_2 || $invoice->user->shippingaddress->country || $invoice->user->shippingaddress->state || $invoice->user->shippingaddress->city || $invoice->user->shippingaddress->zip || $invoice->user->phone))
<div class="bill-address-container"> <div class="bill-address-container">
@else @else
<div class="bill-address-container" style="float:right;padding-right:0px;"> <div class="bill-address-container" style="float:right;padding-right:0px;">

View File

@ -3,9 +3,11 @@
<head> <head>
<title>Invoice</title> <title>Invoice</title>
{{-- <link href="https://fonts.googleapis.com/css?family=Poppins&display=swap" rel="stylesheet"> --}} {{-- <link href="https://fonts.googleapis.com/css?family=Poppins&display=swap" rel="stylesheet"> --}}
<meta http-equiv="Content-Type" content="text/html; charset=utf-8"/>
<style type="text/css"> <style type="text/css">
body { body {
font-family: 'Roboto', sans-serif; font-family: "DejaVu Sans";
} }
html { html {
@ -64,13 +66,13 @@
margin-left:160px; margin-left:160px;
} }
.header { .header {
font-family: 'Roboto', sans-serif; font-family: "DejaVu Sans";
font-size: 20px; font-size: 20px;
color: rgba(0, 0, 0, 0.7); color: rgba(0, 0, 0, 0.7);
} }
.TextColor1 { .TextColor1 {
font-family: 'Roboto', sans-serif; font-family: "DejaVu Sans";
font-size: 16px; font-size: 16px;
color: rgba(0, 0, 0, 0.5); color: rgba(0, 0, 0, 0.5);
} }
@ -382,7 +384,7 @@
} }
.notes { .notes {
font-family: 'Roboto', sans-serif; font-family: "DejaVu Sans";
font-style: normal; font-style: normal;
font-weight: 300; font-weight: 300;
font-size: 12px; font-size: 12px;
@ -395,7 +397,7 @@
} }
.notes-label { .notes-label {
font-family: 'Roboto', sans-serif; font-family: "DejaVu Sans";
font-style: normal; font-style: normal;
font-weight: normal; font-weight: normal;
font-size: 15px; font-size: 15px;
@ -436,7 +438,7 @@
<div style="float:left;"> <div style="float:left;">
@include('app.pdf.invoice.partials.billing-address') @include('app.pdf.invoice.partials.billing-address')
</div> </div>
@if($invoice->user->billingaddress->name || $invoice->user->billingaddress->address_street_1 || $invoice->user->billingaddress->address_street_2 || $invoice->user->billingaddress->country || $invoice->user->billingaddress->state || $invoice->user->billingaddress->city || $invoice->user->billingaddress->zip || $invoice->user->billingaddress->phone) @if($invoice->user->billingaddress && ($invoice->user->billingaddress->name || $invoice->user->billingaddress->address_street_1 || $invoice->user->billingaddress->address_street_2 || $invoice->user->billingaddress->country || $invoice->user->billingaddress->state || $invoice->user->billingaddress->city || $invoice->user->billingaddress->zip || $invoice->user->billingaddress->phone))
<div style="float:right;"> <div style="float:right;">
@else @else
<div style="float:left;"> <div style="float:left;">

View File

@ -3,6 +3,6 @@
<div class="notes-label"> <div class="notes-label">
Notes Notes
</div> </div>
{{$invoice->notes}} {!! $invoice->notes !!}
</div> </div>
@endif @endif