mirror of
https://github.com/crater-invoice/crater.git
synced 2025-10-27 11:41:09 -04:00
Merge branch 'build-version210' into 'master'
Build version210 See merge request mohit.panjvani/crater-web!139
This commit is contained in:
@ -1,6 +1,6 @@
|
||||
APP_ENV=production
|
||||
APP_KEY=base64:kgk/4DW1vEVy7aEvet5FPp5un6PIGe/so8H0mvoUtW0=
|
||||
APP_DEBUG=false
|
||||
APP_DEBUG=true
|
||||
APP_LOG_LEVEL=debug
|
||||
APP_URL=http://crater.test
|
||||
|
||||
|
||||
@ -177,6 +177,7 @@ class CustomersController extends Controller
|
||||
$customer->enable_portal = $request->enable_portal;
|
||||
$customer->save();
|
||||
|
||||
$customer->addresses()->delete();
|
||||
if ($request->addresses) {
|
||||
foreach ($request->addresses as $address) {
|
||||
$newAddress = $customer->addresses()->firstOrNew(['type' => $address["type"]]);
|
||||
|
||||
@ -277,7 +277,14 @@ class OnboardingController extends Controller
|
||||
|
||||
if (file_exists($path)) {
|
||||
file_put_contents($path, str_replace(
|
||||
'PROXY_OAUTH_CLIENT_SECRET='.config('auth.proxy.client_secret'), 'PROXY_OAUTH_CLIENT_SECRET='.$client->secret, file_get_contents($path)
|
||||
'PROXY_OAUTH_CLIENT_SECRET='.config('auth.proxy.client_secret'),
|
||||
'PROXY_OAUTH_CLIENT_SECRET='.$client->secret,
|
||||
file_get_contents($path)
|
||||
));
|
||||
file_put_contents($path, str_replace(
|
||||
'APP_DEBUG=true',
|
||||
'APP_DEBUG=false',
|
||||
file_get_contents($path)
|
||||
));
|
||||
}
|
||||
|
||||
|
||||
@ -6,6 +6,7 @@ use Illuminate\Contracts\Queue\ShouldQueue;
|
||||
use Illuminate\Queue\InteractsWithQueue;
|
||||
use Crater\Events\UpdateFinished;
|
||||
use Crater\Listeners\Updates\Listener;
|
||||
use Crater\Setting;
|
||||
|
||||
class Version210 extends Listener
|
||||
{
|
||||
|
||||
@ -61,7 +61,7 @@ class EnvironmentManager
|
||||
} catch (Exception $e) {
|
||||
|
||||
return [
|
||||
'error' => $e->getMessage()
|
||||
'error_message' => $e->getMessage()
|
||||
];
|
||||
}
|
||||
|
||||
|
||||
@ -149,7 +149,7 @@ return array(
|
||||
* Used if no suitable fonts can be found. This must exist in the font folder.
|
||||
* @var string
|
||||
*/
|
||||
"default_font" => "serif",
|
||||
"default_font" => "DejaVu Sans",
|
||||
|
||||
/**
|
||||
* Image DPI setting
|
||||
|
||||
File diff suppressed because one or more lines are too long
@ -1,4 +1,4 @@
|
||||
{
|
||||
"/assets/js/app.js": "/assets/js/app.js?id=0459d5b0a925f3472c37",
|
||||
"/assets/js/app.js": "/assets/js/app.js?id=5e2defab289e20b6776c",
|
||||
"/assets/css/crater.css": "/assets/css/crater.css?id=193e5770a0e7a8604f35"
|
||||
}
|
||||
|
||||
@ -124,7 +124,7 @@ export default {
|
||||
},
|
||||
percent: {
|
||||
required,
|
||||
between: between(-1, 100)
|
||||
between: between(0, 100)
|
||||
},
|
||||
description: {
|
||||
maxLength: maxLength(255)
|
||||
|
||||
@ -162,7 +162,7 @@
|
||||
:options="billingCountries"
|
||||
:searchable="true"
|
||||
:show-labels="false"
|
||||
:allow-empty="false"
|
||||
:allow-empty="true"
|
||||
:tabindex="8"
|
||||
:placeholder="$t('general.select_country')"
|
||||
label="name"
|
||||
@ -265,7 +265,7 @@
|
||||
:searchable="true"
|
||||
:show-labels="false"
|
||||
:tabindex="16"
|
||||
:allow-empty="false"
|
||||
:allow-empty="true"
|
||||
:placeholder="$t('general.select_country')"
|
||||
label="name"
|
||||
track-by="id"
|
||||
@ -411,6 +411,36 @@ export default {
|
||||
return true
|
||||
}
|
||||
return false
|
||||
},
|
||||
hasBillingAdd () {
|
||||
let billing = this.billing
|
||||
if (
|
||||
billing.name ||
|
||||
billing.country_id ||
|
||||
billing.state ||
|
||||
billing.city ||
|
||||
billing.phone ||
|
||||
billing.zip ||
|
||||
billing.address_street_1 ||
|
||||
billing.address_street_2) {
|
||||
return true
|
||||
}
|
||||
return false
|
||||
},
|
||||
hasShippingAdd () {
|
||||
let shipping = this.shipping
|
||||
if (
|
||||
shipping.name ||
|
||||
shipping.country_id ||
|
||||
shipping.state ||
|
||||
shipping.city ||
|
||||
shipping.phone ||
|
||||
shipping.zip ||
|
||||
shipping.address_street_1 ||
|
||||
shipping.address_street_2) {
|
||||
return true
|
||||
}
|
||||
return false
|
||||
}
|
||||
},
|
||||
watch: {
|
||||
@ -418,12 +448,16 @@ export default {
|
||||
if (newCountry) {
|
||||
this.billing.country_id = newCountry.id
|
||||
this.isDisabledBillingState = false
|
||||
} else {
|
||||
this.billing.country_id = null
|
||||
}
|
||||
},
|
||||
shipping_country (newCountry) {
|
||||
if (newCountry) {
|
||||
this.shipping.country_id = newCountry.id
|
||||
return true
|
||||
} else {
|
||||
this.shipping.country_id = null
|
||||
}
|
||||
}
|
||||
},
|
||||
@ -446,7 +480,14 @@ export default {
|
||||
]),
|
||||
async loadCustomer () {
|
||||
let { data: { customer, currencies, currency } } = await this.fetchCustomer(this.$route.params.id)
|
||||
this.formData = customer
|
||||
|
||||
this.formData.id = customer.id
|
||||
this.formData.name = customer.name
|
||||
this.formData.contact_name = customer.contact_name
|
||||
this.formData.email = customer.email
|
||||
this.formData.phone = customer.phone
|
||||
this.formData.currency_id = customer.currency_id
|
||||
this.formData.website = customer.website
|
||||
|
||||
if (customer.billing_address) {
|
||||
this.billing = customer.billing_address
|
||||
@ -495,7 +536,16 @@ export default {
|
||||
if (this.$v.$invalid) {
|
||||
return true
|
||||
}
|
||||
this.formData.addresses = [{...this.billing}, {...this.shipping}]
|
||||
if (this.hasBillingAdd && this.hasShippingAdd) {
|
||||
this.formData.addresses = [{...this.billing}, {...this.shipping}]
|
||||
} else {
|
||||
if (this.hasBillingAdd) {
|
||||
this.formData.addresses = [{...this.billing}]
|
||||
}
|
||||
if (this.hasShippingAdd) {
|
||||
this.formData.addresses = [{...this.shipping}]
|
||||
}
|
||||
}
|
||||
|
||||
if (this.isEdit) {
|
||||
if (this.currency) {
|
||||
|
||||
@ -32,8 +32,8 @@
|
||||
class="show-customer"
|
||||
>
|
||||
<div class="row px-2 mt-1">
|
||||
<div class="col col-6">
|
||||
<div v-if="selectedCustomer.billing_address != null" class="row address-menu">
|
||||
<div v-if="selectedCustomer.billing_address" class="col col-6">
|
||||
<div class="row address-menu">
|
||||
<label class="col-sm-4 px-2 title">{{ $t('general.bill_to') }}</label>
|
||||
<div class="col-sm p-0 px-2 content">
|
||||
<label v-if="selectedCustomer.billing_address.name">
|
||||
@ -57,8 +57,8 @@
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col col-6">
|
||||
<div v-if="selectedCustomer.shipping_address != null" class="row address-menu">
|
||||
<div v-if="selectedCustomer.shipping_address" class="col col-6">
|
||||
<div class="row address-menu">
|
||||
<label class="col-sm-4 px-2 title">{{ $t('general.ship_to') }}</label>
|
||||
<div class="col-sm p-0 px-2 content">
|
||||
<label v-if="selectedCustomer.shipping_address.name">
|
||||
@ -84,7 +84,7 @@
|
||||
</div>
|
||||
</div>
|
||||
<div class="customer-content mb-1">
|
||||
<label class="email">{{ selectedCustomer.email ? selectedCustomer.email : selectedCustomer.name }}</label>
|
||||
<label class="email">{{ selectedCustomer.name }}</label>
|
||||
<label class="action" @click="removeCustomer">{{ $t('general.remove') }}</label>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
@ -30,8 +30,8 @@
|
||||
<div
|
||||
v-if="selectedCustomer" class="show-customer">
|
||||
<div class="row px-2 mt-1">
|
||||
<div class="col col-6">
|
||||
<div v-if="selectedCustomer.billing_address" class="row address-menu">
|
||||
<div v-if="selectedCustomer.billing_address" class="col col-6">
|
||||
<div class="row address-menu">
|
||||
<label class="col-sm-4 px-2 title">{{ $t('general.bill_to') }}</label>
|
||||
<div class="col-sm p-0 px-2 content">
|
||||
<label v-if="selectedCustomer.billing_address.name">
|
||||
@ -55,8 +55,8 @@
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col col-6">
|
||||
<div v-if="selectedCustomer.shipping_address" class="row address-menu">
|
||||
<div v-if="selectedCustomer.shipping_address" class="col col-6">
|
||||
<div class="row address-menu">
|
||||
<label class="col-sm-4 px-2 title">{{ $t('general.ship_to') }}</label>
|
||||
<div class="col-sm p-0 px-2 content">
|
||||
<label v-if="selectedCustomer.shipping_address.name">
|
||||
|
||||
@ -203,8 +203,10 @@ export default {
|
||||
this.$emit('next')
|
||||
window.toastr['success'](this.$t('wizard.success.' + response.data.success))
|
||||
return true
|
||||
} else {
|
||||
} else if (response.data.error) {
|
||||
window.toastr['error'](this.$t('wizard.errors.' + response.data.error))
|
||||
} else if (response.data.error_message) {
|
||||
window.toastr['error'](response.data.error_message)
|
||||
}
|
||||
} catch (e) {
|
||||
window.toastr['error'](e.response.data.message)
|
||||
|
||||
@ -60,13 +60,11 @@
|
||||
margin-left:160px;
|
||||
}
|
||||
.header {
|
||||
font-family: "DejaVu Sans";
|
||||
font-size: 20px;
|
||||
color: rgba(0, 0, 0, 0.7);
|
||||
}
|
||||
|
||||
.TextColor1 {
|
||||
font-family: "DejaVu Sans";
|
||||
font-size: 16px;
|
||||
color: rgba(0, 0, 0, 0.5);
|
||||
}
|
||||
@ -341,7 +339,6 @@
|
||||
}
|
||||
|
||||
.notes {
|
||||
font-family: "DejaVu Sans";
|
||||
font-style: normal;
|
||||
font-weight: 300;
|
||||
font-size: 12px;
|
||||
@ -354,7 +351,6 @@
|
||||
}
|
||||
|
||||
.notes-label {
|
||||
font-family: "DejaVu Sans";
|
||||
font-style: normal;
|
||||
font-weight: normal;
|
||||
font-size: 15px;
|
||||
@ -412,7 +408,7 @@
|
||||
<div class="bill-address-container">
|
||||
@include('app.pdf.estimate.partials.billing-address')
|
||||
</div>
|
||||
@if($estimate->user->billingaddress && ($estimate->user->billingaddress->name || $estimate->user->billingaddress->address_street_1 || $estimate->user->billingaddress->address_street_2 || $estimate->user->billingaddress->country || $estimate->user->billingaddress->state || $estimate->user->billingaddress->city || $estimate->user->billingaddress->zip || $estimate->user->billingaddress->phone))
|
||||
@if($estimate->user->billingaddress)
|
||||
<div class="ship-address-container">
|
||||
@else
|
||||
<div class="ship-address-container " style="float:left;padding-left:0px;">
|
||||
|
||||
@ -64,13 +64,11 @@
|
||||
margin-left:160px;
|
||||
}
|
||||
.header {
|
||||
font-family: "DejaVu Sans";
|
||||
font-size: 20px;
|
||||
color: rgba(0, 0, 0, 0.7);
|
||||
}
|
||||
|
||||
.TextColor1 {
|
||||
font-family: "DejaVu Sans";
|
||||
font-size: 16px;
|
||||
color: rgba(0, 0, 0, 0.5);
|
||||
}
|
||||
@ -366,7 +364,6 @@
|
||||
}
|
||||
|
||||
.notes {
|
||||
font-family: "DejaVu Sans";
|
||||
font-style: normal;
|
||||
font-weight: 300;
|
||||
font-size: 12px;
|
||||
@ -379,7 +376,6 @@
|
||||
}
|
||||
|
||||
.notes-label {
|
||||
font-family: "DejaVu Sans";
|
||||
font-style: normal;
|
||||
font-weight: normal;
|
||||
font-size: 15px;
|
||||
@ -423,7 +419,7 @@
|
||||
<div class="ship-address-container">
|
||||
@include('app.pdf.estimate.partials.shipping-address')
|
||||
</div>
|
||||
@if($estimate->user->shippingaddress && ($estimate->user->shippingaddress->name || $estimate->user->shippingaddress->address_street_1 || $estimate->user->shippingaddress->address_street_2 || $estimate->user->shippingaddress->country || $estimate->user->shippingaddress->state || $estimate->user->shippingaddress->city || $estimate->user->shippingaddress->zip || $estimate->user->phone))
|
||||
@if($estimate->user->shippingaddress)
|
||||
<div class="bill-address-container">
|
||||
@else
|
||||
<div class="bill-address-container" style="float:right;padding-right:0px;">
|
||||
|
||||
@ -66,13 +66,11 @@
|
||||
margin-left:160px;
|
||||
}
|
||||
.header {
|
||||
font-family: "DejaVu Sans";
|
||||
font-size: 20px;
|
||||
color: rgba(0, 0, 0, 0.7);
|
||||
}
|
||||
|
||||
.TextColor1 {
|
||||
font-family: "DejaVu Sans";
|
||||
font-size: 16px;
|
||||
color: rgba(0, 0, 0, 0.5);
|
||||
}
|
||||
@ -374,7 +372,6 @@
|
||||
}
|
||||
|
||||
.notes {
|
||||
font-family: "DejaVu Sans";
|
||||
font-style: normal;
|
||||
font-weight: 300;
|
||||
font-size: 12px;
|
||||
@ -387,7 +384,6 @@
|
||||
}
|
||||
|
||||
.notes-label {
|
||||
font-family: "DejaVu Sans";
|
||||
font-style: normal;
|
||||
font-weight: normal;
|
||||
font-size: 15px;
|
||||
@ -428,7 +424,7 @@
|
||||
<div style="float:left;">
|
||||
@include('app.pdf.estimate.partials.billing-address')
|
||||
</div>
|
||||
@if($estimate->user->billingaddress && ($estimate->user->billingaddress->name || $estimate->user->billingaddress->address_street_1 || $estimate->user->billingaddress->address_street_2 || $estimate->user->billingaddress->country || $estimate->user->billingaddress->state || $estimate->user->billingaddress->city || $estimate->user->billingaddress->zip || $estimate->user->billingaddress->phone))
|
||||
@if($estimate->user->billingaddress)
|
||||
<div style="float:right;">
|
||||
@else
|
||||
<div style="float:left;">
|
||||
|
||||
@ -1,7 +1,5 @@
|
||||
@if($estimate->user->billingaddress)
|
||||
@if($estimate->user->billingaddress->name || $estimate->user->billingaddress->address_street_1 || $estimate->user->billingaddress->address_street_2 || $estimate->user->billingaddress->country || $estimate->user->billingaddress->state || $estimate->user->billingaddress->city || $estimate->user->billingaddress->zip || $estimate->user->billingaddress->phone)
|
||||
<p class="bill-to">Bill To,</p>
|
||||
@endif
|
||||
<p class="bill-to">Bill To,</p>
|
||||
@if($estimate->user->billingaddress->name)
|
||||
<p class="bill-user-name">
|
||||
{{$estimate->user->billingaddress->name}}
|
||||
@ -16,11 +14,11 @@
|
||||
{{$estimate->user->billingaddress->address_street_2}}<br>
|
||||
@endif
|
||||
|
||||
@if($estimate->user->billingaddress->city && $estimate->user->billingaddress->city)
|
||||
@if($estimate->user->billingaddress->city)
|
||||
{{$estimate->user->billingaddress->city}},
|
||||
@endif
|
||||
|
||||
@if($estimate->user->billingaddress->state && $estimate->user->billingaddress->state)
|
||||
@if($estimate->user->billingaddress->state)
|
||||
{{$estimate->user->billingaddress->state}}.
|
||||
@endif
|
||||
|
||||
|
||||
@ -1,7 +1,5 @@
|
||||
@if($estimate->user->shippingaddress)
|
||||
@if($estimate->user->shippingaddress->name || $estimate->user->shippingaddress->address_street_1 || $estimate->user->shippingaddress->address_street_2 || $estimate->user->shippingaddress->country || $estimate->user->shippingaddress->state || $estimate->user->shippingaddress->city || $estimate->user->shippingaddress->zip || $estimate->user->phone)
|
||||
<p class="ship-to">Ship To,</p>
|
||||
@endif
|
||||
<p class="ship-to">Ship To,</p>
|
||||
@if($estimate->user->shippingaddress->name)
|
||||
<p class="ship-user-name">
|
||||
{{$estimate->user->shippingaddress->name}}
|
||||
|
||||
@ -18,24 +18,48 @@
|
||||
@endphp
|
||||
@foreach ($estimate->items as $item)
|
||||
<tr class="item-details">
|
||||
<td class="inv-item items" style="text-align: right; color: #040405; padding-right: 20px; vertical-align: top;">{{$index}}</td>
|
||||
<td class="inv-item items" style="text-align: left; color: #040405;padding-left: 0px">
|
||||
<span>{{ $item->name }}</span><br>
|
||||
<span style="text-align: left; color: #595959; font-size: 9px; font-weight:300; line-height: 12px;">{{ $item->description }}</span>
|
||||
<td
|
||||
class="inv-item items"
|
||||
style="text-align: right; color: #040405; padding-right: 20px; vertical-align: top;"
|
||||
>
|
||||
{{$index}}
|
||||
</td>
|
||||
<td
|
||||
class="inv-item items"
|
||||
style="text-align: left; color: #040405;padding-left: 0px"
|
||||
>
|
||||
<span>{{ $item->name }}</span><br>
|
||||
<span
|
||||
style="text-align: left; color: #595959; font-size: 9px; font-weight:300; line-height: 12px;"
|
||||
>
|
||||
{{ $item->description }}
|
||||
</span>
|
||||
</td>
|
||||
<td
|
||||
class="inv-item items"
|
||||
style="text-align: right; color: #040405; padding-right: 20px"
|
||||
>
|
||||
{{$item->quantity}}
|
||||
</td>
|
||||
<td
|
||||
class="inv-item items"
|
||||
style="text-align: right; color: #040405; padding-right: 40px"
|
||||
>
|
||||
{!! format_money_pdf($item->price, $estimate->user->currency) !!}
|
||||
</td>
|
||||
<td class="inv-item items" style="text-align: right; color: #040405; padding-right: 20px">{{$item->quantity}}</td>
|
||||
<td class="inv-item items" style="text-align: right; color: #040405; padding-right: 40px">{{$item->price/100}}</td>
|
||||
@if($estimate->discount_per_item === 'YES')
|
||||
<td class="inv-item items" style="text-align: right; color: #040405; padding-left: 10px">
|
||||
@if($item->discount_type === 'fixed')
|
||||
{{$item->discount_val/100}}
|
||||
{!! format_money_pdf($item->discount_val, $estimate->user->currency) !!}
|
||||
@endif
|
||||
@if($item->discount_type === 'percentage')
|
||||
{{$item->discount}}%
|
||||
@endif
|
||||
</td>
|
||||
@endif
|
||||
<td class="inv-item items" style="text-align: right; color: #040405;">{{$item->total/100}}</td>
|
||||
<td class="inv-item items" style="text-align: right; color: #040405;">
|
||||
{!! format_money_pdf($item->total, $estimate->user->currency) !!}
|
||||
</td>
|
||||
</tr>
|
||||
@php
|
||||
$index += 1
|
||||
|
||||
@ -61,13 +61,11 @@
|
||||
margin-left:160px;
|
||||
}
|
||||
.header {
|
||||
font-family: "DejaVu Sans";
|
||||
font-size: 20px;
|
||||
color: rgba(0, 0, 0, 0.7);
|
||||
}
|
||||
|
||||
.TextColor1 {
|
||||
font-family: "DejaVu Sans";
|
||||
font-size: 16px;
|
||||
color: rgba(0, 0, 0, 0.5);
|
||||
}
|
||||
@ -348,7 +346,6 @@
|
||||
}
|
||||
|
||||
.notes {
|
||||
font-family: "DejaVu Sans";
|
||||
font-style: normal;
|
||||
font-weight: 300;
|
||||
font-size: 12px;
|
||||
@ -361,7 +358,6 @@
|
||||
}
|
||||
|
||||
.notes-label {
|
||||
font-family: "DejaVu Sans";
|
||||
font-style: normal;
|
||||
font-weight: normal;
|
||||
font-size: 15px;
|
||||
@ -419,7 +415,7 @@
|
||||
<div class="bill-address-container">
|
||||
@include('app.pdf.invoice.partials.billing-address')
|
||||
</div>
|
||||
@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))
|
||||
@if($invoice->user->billingaddress)
|
||||
<div class="ship-address-container">
|
||||
@else
|
||||
<div class="ship-address-container " style="float:left;padding-left:0px;">
|
||||
|
||||
@ -62,13 +62,11 @@
|
||||
margin-left:160px;
|
||||
}
|
||||
.header {
|
||||
font-family: "DejaVu Sans";
|
||||
font-size: 20px;
|
||||
color: rgba(0, 0, 0, 0.7);
|
||||
}
|
||||
|
||||
.TextColor1 {
|
||||
font-family: "DejaVu Sans";
|
||||
font-size: 16px;
|
||||
color: rgba(0, 0, 0, 0.5);
|
||||
}
|
||||
@ -374,7 +372,6 @@
|
||||
}
|
||||
|
||||
.notes {
|
||||
font-family: "DejaVu Sans";
|
||||
font-style: normal;
|
||||
font-weight: 300;
|
||||
font-size: 12px;
|
||||
@ -387,7 +384,6 @@
|
||||
}
|
||||
|
||||
.notes-label {
|
||||
font-family: "DejaVu Sans";
|
||||
font-style: normal;
|
||||
font-weight: normal;
|
||||
font-size: 15px;
|
||||
@ -432,7 +428,7 @@
|
||||
<div class="ship-address-container">
|
||||
@include('app.pdf.invoice.partials.shipping-address')
|
||||
</div>
|
||||
@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))
|
||||
@if($invoice->user->shippingaddress)
|
||||
<div class="bill-address-container">
|
||||
@else
|
||||
<div class="bill-address-container" style="float:right;padding-right:0px;">
|
||||
|
||||
@ -66,13 +66,11 @@
|
||||
margin-left:160px;
|
||||
}
|
||||
.header {
|
||||
font-family: "DejaVu Sans";
|
||||
font-size: 20px;
|
||||
color: rgba(0, 0, 0, 0.7);
|
||||
}
|
||||
|
||||
.TextColor1 {
|
||||
font-family: "DejaVu Sans";
|
||||
font-size: 16px;
|
||||
color: rgba(0, 0, 0, 0.5);
|
||||
}
|
||||
@ -384,7 +382,6 @@
|
||||
}
|
||||
|
||||
.notes {
|
||||
font-family: "DejaVu Sans";
|
||||
font-style: normal;
|
||||
font-weight: 300;
|
||||
font-size: 12px;
|
||||
@ -397,7 +394,6 @@
|
||||
}
|
||||
|
||||
.notes-label {
|
||||
font-family: "DejaVu Sans";
|
||||
font-style: normal;
|
||||
font-weight: normal;
|
||||
font-size: 15px;
|
||||
@ -438,7 +434,7 @@
|
||||
<div style="float:left;">
|
||||
@include('app.pdf.invoice.partials.billing-address')
|
||||
</div>
|
||||
@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))
|
||||
@if($invoice->user->billingaddress)
|
||||
<div style="float:right;">
|
||||
@else
|
||||
<div style="float:left;">
|
||||
|
||||
@ -1,7 +1,5 @@
|
||||
@if($invoice->user->billingaddress)
|
||||
@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)
|
||||
<p class="bill-to">Bill To,</p>
|
||||
@endif
|
||||
<p class="bill-to">Bill To,</p>
|
||||
@if($invoice->user->billingaddress->name)
|
||||
<p class="bill-user-name">
|
||||
{{$invoice->user->billingaddress->name}}
|
||||
|
||||
@ -1,7 +1,5 @@
|
||||
@if($invoice->user->shippingaddress)
|
||||
@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)
|
||||
<p class="ship-to">Ship To,</p>
|
||||
@endif
|
||||
<p class="ship-to">Ship To,</p>
|
||||
@if($invoice->user->shippingaddress->name)
|
||||
<p class="ship-user-name">
|
||||
{{$invoice->user->shippingaddress->name}}
|
||||
|
||||
@ -18,24 +18,47 @@
|
||||
@endphp
|
||||
@foreach ($invoice->items as $item)
|
||||
<tr class="item-details">
|
||||
<td class="inv-item items" style="text-align: right; color: #040405; padding-right: 20px; vertical-align: top;">{{$index}}</td>
|
||||
<td class="inv-item items" style="text-align: left; color: #040405;padding-left: 0px">
|
||||
<td
|
||||
class="inv-item items"
|
||||
style="text-align: right; color: #040405; padding-right: 20px; vertical-align: top;"
|
||||
>
|
||||
{{$index}}
|
||||
</td>
|
||||
<td
|
||||
class="inv-item items"
|
||||
style="text-align: left; color: #040405;padding-left: 0px"
|
||||
>
|
||||
<span>{{ $item->name }}</span><br>
|
||||
<span style="text-align: left; color: #595959; font-size: 9px; font-weight:300; line-height: 12px;">{{ $item->description }}</span>
|
||||
</td>
|
||||
<td class="inv-item items" style="text-align: right; color: #040405; padding-right: 20px">{{$item->quantity}}</td>
|
||||
<td class="inv-item items" style="text-align: right; color: #040405; padding-right: 40px">{{$item->price/100}}</td>
|
||||
<td
|
||||
class="inv-item items"
|
||||
style="text-align: right; color: #040405; padding-right: 20px"
|
||||
>
|
||||
{{$item->quantity}}
|
||||
</td>
|
||||
<td
|
||||
class="inv-item items"
|
||||
style="text-align: right; color: #040405; padding-right: 40px"
|
||||
>
|
||||
{!! format_money_pdf($item->price, $invoice->user->currency) !!}
|
||||
</td>
|
||||
@if($invoice->discount_per_item === 'YES')
|
||||
<td class="inv-item items" style="text-align: right; color: #040405; padding-left: 10px">
|
||||
@if($item->discount_type === 'fixed')
|
||||
{{$item->discount_val/100}}
|
||||
{!! format_money_pdf($item->discount_val, $invoice->user->currency) !!}
|
||||
@endif
|
||||
@if($item->discount_type === 'percentage')
|
||||
{{$item->discount}}%
|
||||
@endif
|
||||
</td>
|
||||
@endif
|
||||
<td class="inv-item items" style="text-align: right; color: #040405;">{{$item->total/100}}</td>
|
||||
<td
|
||||
class="inv-item items"
|
||||
style="text-align: right; color: #040405;"
|
||||
>
|
||||
{!! format_money_pdf($item->total, $invoice->user->currency) !!}
|
||||
</td>
|
||||
</tr>
|
||||
@php
|
||||
$index += 1
|
||||
|
||||
@ -5,7 +5,7 @@
|
||||
{{-- <link href="https://fonts.googleapis.com/css?family=Poppins&display=swap" rel="stylesheet"> --}}
|
||||
<style type="text/css">
|
||||
body {
|
||||
font-family: 'Roboto', sans-serif;
|
||||
font-family: "DejaVu Sans";
|
||||
}
|
||||
|
||||
/* html {
|
||||
@ -181,10 +181,14 @@
|
||||
@foreach ($expenseCategories as $expenseCategory)
|
||||
<tr>
|
||||
<td>
|
||||
<p class="expense-title">{{ $expenseCategory->category->name }}</p>
|
||||
<p class="expense-title">
|
||||
{{ $expenseCategory->category->name }}
|
||||
</p>
|
||||
</td>
|
||||
<td>
|
||||
<p class="expense-money">{!! format_money_pdf($expenseCategory->total_amount) !!}</p>
|
||||
<p class="expense-money">
|
||||
{!! format_money_pdf($expenseCategory->total_amount) !!}
|
||||
</p>
|
||||
</td>
|
||||
</tr>
|
||||
@endforeach
|
||||
|
||||
@ -5,7 +5,7 @@
|
||||
{{-- <link href="https://fonts.googleapis.com/css?family=Poppins&display=swap" rel="stylesheet"> --}}
|
||||
<style type="text/css">
|
||||
body {
|
||||
font-family: 'Roboto', sans-serif;
|
||||
font-family: "DejaVu Sans";
|
||||
}
|
||||
|
||||
html {
|
||||
@ -220,10 +220,14 @@
|
||||
@foreach ($expenseCategories as $expenseCategory)
|
||||
<tr>
|
||||
<td>
|
||||
<p class="expense-title">{{ $expenseCategory->category->name }}</p>
|
||||
<p class="expense-title">
|
||||
{{ $expenseCategory->category->name }}
|
||||
</p>
|
||||
</td>
|
||||
<td>
|
||||
<p class="expense-money">{!! format_money_pdf($expenseCategory->total_amount) !!}</p>
|
||||
<p class="expense-money">
|
||||
{!! format_money_pdf($expenseCategory->total_amount) !!}
|
||||
</p>
|
||||
</td>
|
||||
</tr>
|
||||
@endforeach
|
||||
|
||||
@ -5,7 +5,7 @@
|
||||
{{-- <link href="https://fonts.googleapis.com/css?family=Poppins&display=swap" rel="stylesheet"> --}}
|
||||
<style type="text/css">
|
||||
body {
|
||||
font-family: 'Roboto', sans-serif;
|
||||
font-family: "DejaVu Sans";
|
||||
}
|
||||
|
||||
/* html {
|
||||
@ -223,10 +223,14 @@
|
||||
@foreach ($customer->invoices as $invoice)
|
||||
<tr>
|
||||
<td>
|
||||
<p class="expense-title">{{ $invoice->formattedInvoiceDate }} ({{ $invoice->invoice_number }})</p>
|
||||
<p class="expense-title">
|
||||
{{ $invoice->formattedInvoiceDate }} ({{ $invoice->invoice_number }})
|
||||
</p>
|
||||
</td>
|
||||
<td>
|
||||
<p class="expense-money">{!! format_money_pdf($invoice->total) !!}</p>
|
||||
<p class="expense-money">
|
||||
{!! format_money_pdf($invoice->total) !!}
|
||||
</p>
|
||||
</td>
|
||||
</tr>
|
||||
@endforeach
|
||||
@ -235,7 +239,9 @@
|
||||
<table class="expense-total-table">
|
||||
<tr>
|
||||
<td class="expense-total-cell">
|
||||
<p class="expense-total">{!! format_money_pdf($customer->totalAmount) !!}</p>
|
||||
<p class="expense-total">
|
||||
{!! format_money_pdf($customer->totalAmount) !!}
|
||||
</p>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
@ -249,7 +255,9 @@
|
||||
<p class="profit-title">TOTAL SALES</p>
|
||||
</td>
|
||||
<td>
|
||||
<p class="profit-money">{!! format_money_pdf($totalAmount) !!}</p>
|
||||
<p class="profit-money">
|
||||
{!! format_money_pdf($totalAmount) !!}
|
||||
</p>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
|
||||
@ -5,7 +5,7 @@
|
||||
{{-- <link href="https://fonts.googleapis.com/css?family=Poppins&display=swap" rel="stylesheet"> --}}
|
||||
<style type="text/css">
|
||||
body {
|
||||
font-family: 'Roboto', sans-serif;
|
||||
font-family: "DejaVu Sans";
|
||||
}
|
||||
|
||||
/* html {
|
||||
@ -222,10 +222,14 @@
|
||||
<table class="expenses-table">
|
||||
<tr>
|
||||
<td>
|
||||
<p class="expense-title">{{ $item->name }}</p>
|
||||
<p class="expense-title">
|
||||
{{ $item->name }}
|
||||
</p>
|
||||
</td>
|
||||
<td>
|
||||
<p class="expense-money">{!! format_money_pdf($item->total_amount) !!}</p>
|
||||
<p class="expense-money">
|
||||
{!! format_money_pdf($item->total_amount) !!}
|
||||
</p>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
@ -235,7 +239,9 @@
|
||||
<table class="expense-total-table">
|
||||
<tr>
|
||||
<td class="expense-total-cell">
|
||||
<p class="expense-total">{!! format_money_pdf($totalAmount) !!}</p>
|
||||
<p class="expense-total">
|
||||
{!! format_money_pdf($totalAmount) !!}
|
||||
</p>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
@ -248,7 +254,9 @@
|
||||
<p class="profit-title">TOTAL SALES</p>
|
||||
</td>
|
||||
<td>
|
||||
<p class="profit-money">{!! format_money_pdf($totalAmount) !!}</p>
|
||||
<p class="profit-money">
|
||||
{!! format_money_pdf($totalAmount) !!}
|
||||
</p>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
|
||||
@ -5,7 +5,7 @@
|
||||
{{-- <link href="https://fonts.googleapis.com/css?family=Poppins&display=swap" rel="stylesheet"> --}}
|
||||
<style type="text/css">
|
||||
body {
|
||||
font-family: 'Roboto', sans-serif;
|
||||
font-family: "DejaVu Sans";
|
||||
}
|
||||
|
||||
/* html {
|
||||
@ -174,10 +174,14 @@
|
||||
<table class="header">
|
||||
<tr>
|
||||
<td>
|
||||
<p class="heading-text">{{ $company->name }}</p>
|
||||
<p class="heading-text">
|
||||
{{ $company->name }}
|
||||
</p>
|
||||
</td>
|
||||
<td>
|
||||
<p class="heading-date-range">{{ $from_date }} - {{ $to_date }}</p>
|
||||
<p class="heading-date-range">
|
||||
{{ $from_date }} - {{ $to_date }}
|
||||
</p>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
@ -192,10 +196,14 @@
|
||||
@foreach ($taxTypes as $tax)
|
||||
<tr>
|
||||
<td>
|
||||
<p class="tax-title">{{ $tax->taxType->name }}</p>
|
||||
<p class="tax-title">
|
||||
{{ $tax->taxType->name }}
|
||||
</p>
|
||||
</td>
|
||||
<td>
|
||||
<p class="tax-money">{!! format_money_pdf($tax->total_tax_amount) !!}</p>
|
||||
<p class="tax-money">
|
||||
{!! format_money_pdf($tax->total_tax_amount) !!}
|
||||
</p>
|
||||
</td>
|
||||
</tr>
|
||||
@endforeach
|
||||
@ -207,7 +215,9 @@
|
||||
<table class="tax-total-table">
|
||||
<tr>
|
||||
<td class="tax-total-cell">
|
||||
<p class="tax-total">{!! format_money_pdf($totalTaxAmount) !!}</p>
|
||||
<p class="tax-total">
|
||||
{!! format_money_pdf($totalTaxAmount) !!}
|
||||
</p>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
@ -217,7 +227,9 @@
|
||||
<p class="total-tax-title">TOTAL TAX</p>
|
||||
</td>
|
||||
<td>
|
||||
<p class="total-tax-money">{!! format_money_pdf($totalTaxAmount) !!}</p>
|
||||
<p class="total-tax-money">
|
||||
{!! format_money_pdf($totalTaxAmount) !!}
|
||||
</p>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
|
||||
Reference in New Issue
Block a user