mirror of
https://github.com/invoiceninja/invoiceninja.git
synced 2025-07-09 03:14:30 -04:00
Client portal
This commit is contained in:
parent
b8998f1d94
commit
8ebef188b4
@ -120,24 +120,24 @@ class PdfSlot extends Component
|
|||||||
|
|
||||||
private function getEntityDetails()
|
private function getEntityDetails()
|
||||||
{
|
{
|
||||||
$entity_details = "<dl class=''>";
|
$entity_details = "<dl class='border-1'>";
|
||||||
|
|
||||||
if($this->entity_type == 'invoice' || $this->entity_type == 'recurring_invoice') {
|
if($this->entity_type == 'invoice' || $this->entity_type == 'recurring_invoice') {
|
||||||
foreach($this->settings->pdf_variables->invoice_details as $variable)
|
foreach($this->settings->pdf_variables->invoice_details as $variable)
|
||||||
$entity_details .= "<div class='px-1 py-1 sm:grid sm:grid-cols-4 sm:gap-0 sm:px-2 border-b-3 border-fuschia-500'><dt class=''>{$variable}_label</dt><dd class='flex text-sm font-mediumtext-gray-900 space-x-4'>{$variable}</dd></div>";
|
$entity_details .= "<div class='px-1 sm:grid sm:grid-cols-3'><dt class=''>{$variable}_label</dt><dd class='flex ml-5'>{$variable}</dd></div>";
|
||||||
|
|
||||||
}
|
}
|
||||||
elseif($this->entity_type == 'quote'){
|
elseif($this->entity_type == 'quote'){
|
||||||
foreach($this->settings->pdf_variables->quote_details as $variable)
|
foreach($this->settings->pdf_variables->quote_details as $variable)
|
||||||
$entity_details .= "<div class='px-1 py-1 sm:grid sm:grid-cols-4 sm:gap-0 sm:px-2 border-b-3 border-fuschia-500'><dt class=''>{$variable}_label</dt><dd class='flex text-sm font-mediumtext-gray-900 space-x-4'>{$variable}</dd></div>";
|
$entity_details .= "<div class='px-1 sm:grid sm:grid-cols-3'><dt class=''>{$variable}_label</dt><dd class='flex ml-5'>{$variable}</dd></div>";
|
||||||
}
|
}
|
||||||
elseif($this->entity_type == 'credit') {
|
elseif($this->entity_type == 'credit') {
|
||||||
foreach($this->settings->pdf_variables->credit_details as $variable)
|
foreach($this->settings->pdf_variables->credit_details as $variable)
|
||||||
$entity_details .= "<div class='px-1 py-1 sm:grid sm:grid-cols-4 sm:gap-0 sm:px-2 border-b-3 border-fuschia-500'><dt class=''>{$variable}_label</dt><dd class='flex text-sm font-mediumtext-gray-900 space-x-4'>{$variable}</dd></div>";
|
$entity_details .= "<div class='px-1 sm:grid sm:grid-cols-3'><dt class=''>{$variable}_label</dt><dd class='flex ml-5'>{$variable}</dd></div>";
|
||||||
}
|
}
|
||||||
elseif($this->entity_type == 'purchase_order'){
|
elseif($this->entity_type == 'purchase_order'){
|
||||||
foreach($this->settings->pdf_variables->purchase_order_details as $variable)
|
foreach($this->settings->pdf_variables->purchase_order_details as $variable)
|
||||||
$entity_details .= "<div class='px-1 py-1 sm:grid sm:grid-cols-4 sm:gap-0 sm:px-2 border-b-3 border-fuschia-500'><dt class=''>{$variable}_label</dt><dd class='flex text-sm font-mediumtext-gray-900 space-x-4'>{$variable}</dd></div>";
|
$entity_details .= "<div class='px-1 sm:grid sm:grid-cols-3'><dt class=''>{$variable}_label</dt><dd class='flex ml-5'>{$variable}</dd></div>";
|
||||||
}
|
}
|
||||||
|
|
||||||
$entity_details .= "</dl>";
|
$entity_details .= "</dl>";
|
||||||
|
@ -1,7 +1,6 @@
|
|||||||
|
|
||||||
<style>
|
<style>
|
||||||
|
|
||||||
|
|
||||||
table, th, td {
|
table, th, td {
|
||||||
border: 1px solid black;
|
border: 1px solid black;
|
||||||
border-collapse: collapse;
|
border-collapse: collapse;
|
||||||
@ -27,7 +26,7 @@ span {
|
|||||||
}
|
}
|
||||||
|
|
||||||
</style>
|
</style>
|
||||||
<div class="w-full">
|
<div class="w-full bg-white">
|
||||||
<div class="flex flex-row content-center border-fuchsia-600 border-b-2 pb-3">
|
<div class="flex flex-row content-center border-fuchsia-600 border-b-2 pb-3">
|
||||||
<div id="company-details" class="mx-auto">
|
<div id="company-details" class="mx-auto">
|
||||||
{!! $company_details !!}
|
{!! $company_details !!}
|
||||||
@ -38,14 +37,17 @@ span {
|
|||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="mt-3"> {!! $entity_details !!}</div>
|
<div class="flex flex-row content-center border-fuchsia-600 border-b-2 pb-3 mt-3">
|
||||||
|
|
||||||
<div id="user-details" class="mt-3">
|
<div class="mx-auto"> {!! $entity_details !!}</div>
|
||||||
|
|
||||||
|
<div id="user-details" class="mx-auto">
|
||||||
{!! $user_details !!}
|
{!! $user_details !!}
|
||||||
</div>
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
@if($products->count() > 0)
|
@if($products->count() > 0)
|
||||||
<div id="product-details" class="py-6">
|
<div id="product-details" class="py-6 mr-10 ml-10">
|
||||||
<table width="100%">
|
<table width="100%">
|
||||||
<thead>
|
<thead>
|
||||||
<tr>
|
<tr>
|
||||||
@ -72,7 +74,7 @@ span {
|
|||||||
</div>
|
</div>
|
||||||
@endif
|
@endif
|
||||||
@if($services->count() > 0)
|
@if($services->count() > 0)
|
||||||
<div id="task-details" class="py-6">
|
<div id="task-details" class="py-6 mr-10 ml-10">
|
||||||
<table width="100%">
|
<table width="100%">
|
||||||
<thead>
|
<thead>
|
||||||
<tr class="border-bottom>
|
<tr class="border-bottom>
|
||||||
@ -98,7 +100,7 @@ span {
|
|||||||
</table>
|
</table>
|
||||||
</div>
|
</div>
|
||||||
@endif
|
@endif
|
||||||
<div id="totals" class="mb-20">
|
<div id="totals" class="mb-10 mr-10 ml-10">
|
||||||
<table width="100%">
|
<table width="100%">
|
||||||
<thead>
|
<thead>
|
||||||
</thead>
|
</thead>
|
||||||
@ -129,45 +131,45 @@ span {
|
|||||||
</div>
|
</div>
|
||||||
|
|
||||||
@if(strlen($entity->public_notes) > 3)
|
@if(strlen($entity->public_notes) > 3)
|
||||||
<div x-data="{ show_notes: false }" class="mb-10">
|
<div x-data="{ show_notes: false }" class="mb-10 mr-10 ml-10 flex flex-col items-center">
|
||||||
|
|
||||||
<button @click="show_notes = !show_notes" :aria-expanded="show_notes ? 'true' : 'false'" :class="{ 'active': show_notes }" class="bg-gray-100 hover:bg-gray-200 text-gray-800 font-bold py-2 px-4 rounded inline-flex items-center">
|
<button @click="show_notes = !show_notes" :aria-expanded="show_notes ? 'true' : 'false'" :class="{ 'active': show_notes }" class="bg-gray-100 hover:bg-gray-200 text-gray-800 font-bold py-2 px-4 rounded inline-flex items-center mx-auto">
|
||||||
<svg xmlns="http://www.w3.org/2000/svg" height="1em" viewBox="0 0 512 512"><!--! Font Awesome Free 6.4.0 by @fontawesome - https://fontawesome.com License - https://fontawesome.com/license (Commercial License) Copyright 2023 Fonticons, Inc. --><path d="M233.4 406.6c12.5 12.5 32.8 12.5 45.3 0l192-192c12.5-12.5 12.5-32.8 0-45.3s-32.8-12.5-45.3 0L256 338.7 86.6 169.4c-12.5-12.5-32.8-12.5-45.3 0s-12.5 32.8 0 45.3l192 192z"/></svg>
|
|
||||||
<span>{{ ctrans('texts.notes') }}</span>
|
<span>{{ ctrans('texts.notes') }}</span>
|
||||||
|
<svg xmlns="http://www.w3.org/2000/svg" height="1em" viewBox="0 0 512 512"><path d="M233.4 406.6c12.5 12.5 32.8 12.5 45.3 0l192-192c12.5-12.5 12.5-32.8 0-45.3s-32.8-12.5-45.3 0L256 338.7 86.6 169.4c-12.5-12.5-32.8-12.5-45.3 0s-12.5 32.8 0 45.3l192 192z"/></svg>
|
||||||
</button>
|
</button>
|
||||||
|
|
||||||
<div id="notes" class="py-10 border-b-2 border-fuschia-600" x-show="show_notes">
|
<div id="notes" class="py-10 border-b-2 border-fuschia-600" x-show="show_notes">
|
||||||
{{ $entity->public_notes }}
|
{{ strip_tags($entity->public_notes) }}
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
</div>
|
</div>
|
||||||
@endif
|
@endif
|
||||||
|
|
||||||
@if(strlen($entity->terms) > 3)
|
@if(strlen($entity->terms) > 3)
|
||||||
<div x-data="{ show_terms: false }" class="mb-10">
|
<div x-data="{ show_terms: false }" class="mb-10 mr-10 ml-10 flex flex-col items-center">
|
||||||
|
|
||||||
<button @click="show_terms = !show_terms" :aria-expanded="show_terms ? 'true' : 'false'" :class="{ 'active': show_terms }" class="bg-gray-100 hover:bg-gray-200 text-gray-800 font-bold py-2 px-4 rounded inline-flex items-center">
|
<button @click="show_terms = !show_terms" :aria-expanded="show_terms ? 'true' : 'false'" :class="{ 'active': show_terms }" class="bg-gray-100 hover:bg-gray-200 text-gray-800 font-bold py-2 px-4 rounded inline-flex items-center">
|
||||||
<svg xmlns="http://www.w3.org/2000/svg" height="1em" viewBox="0 0 512 512"><!--! Font Awesome Free 6.4.0 by @fontawesome - https://fontawesome.com License - https://fontawesome.com/license (Commercial License) Copyright 2023 Fonticons, Inc. --><path d="M233.4 406.6c12.5 12.5 32.8 12.5 45.3 0l192-192c12.5-12.5 12.5-32.8 0-45.3s-32.8-12.5-45.3 0L256 338.7 86.6 169.4c-12.5-12.5-32.8-12.5-45.3 0s-12.5 32.8 0 45.3l192 192z"/></svg>
|
|
||||||
<span>{{ ctrans('texts.terms') }}</span>
|
<span>{{ ctrans('texts.terms') }}</span>
|
||||||
|
<svg xmlns="http://www.w3.org/2000/svg" height="1em" viewBox="0 0 512 512"><path d="M233.4 406.6c12.5 12.5 32.8 12.5 45.3 0l192-192c12.5-12.5 12.5-32.8 0-45.3s-32.8-12.5-45.3 0L256 338.7 86.6 169.4c-12.5-12.5-32.8-12.5-45.3 0s-12.5 32.8 0 45.3l192 192z"/></svg>
|
||||||
</button>
|
</button>
|
||||||
|
|
||||||
<div id="terms" class="py-10 border-b-2 border-fuschia-600" x-show="show_terms">
|
<div id="terms" class="py-10 border-b-2 border-fuschia-600" x-show="show_terms">
|
||||||
{{ $entity->terms }}
|
{{ strip_tags($entity->terms) }}
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
</div>
|
</div>
|
||||||
@endif
|
@endif
|
||||||
|
|
||||||
@if(strlen($entity->footer) > 3)
|
@if(strlen($entity->footer) > 3)
|
||||||
<div x-data="{ show_footer: false }" class="mb-10">
|
<div x-data="{ show_footer: false }" class="mb-10 mr-10 ml-10 flex flex-col items-center">
|
||||||
|
|
||||||
<button @click="show_footer = !show_footer" :aria-expanded="show_footer ? 'true' : 'false'" :class="{ 'active': show_footer }" class="bg-gray-100 hover:bg-gray-200 text-gray-800 font-bold py-2 px-4 rounded inline-flex items-center">
|
<button @click="show_footer = !show_footer" :aria-expanded="show_footer ? 'true' : 'false'" :class="{ 'active': show_footer }" class="bg-gray-100 hover:bg-gray-200 text-gray-800 font-bold py-2 px-4 rounded inline-flex items-center">
|
||||||
<svg xmlns="http://www.w3.org/2000/svg" height="1em" viewBox="0 0 512 512"><!--! Font Awesome Free 6.4.0 by @fontawesome - https://fontawesome.com License - https://fontawesome.com/license (Commercial License) Copyright 2023 Fonticons, Inc. --><path d="M233.4 406.6c12.5 12.5 32.8 12.5 45.3 0l192-192c12.5-12.5 12.5-32.8 0-45.3s-32.8-12.5-45.3 0L256 338.7 86.6 169.4c-12.5-12.5-32.8-12.5-45.3 0s-12.5 32.8 0 45.3l192 192z"/></svg>
|
|
||||||
<span>{{ ctrans('texts.footer') }}</span>
|
<span>{{ ctrans('texts.footer') }}</span>
|
||||||
|
<svg xmlns="http://www.w3.org/2000/svg" height="1em" viewBox="0 0 512 512"><path d="M233.4 406.6c12.5 12.5 32.8 12.5 45.3 0l192-192c12.5-12.5 12.5-32.8 0-45.3s-32.8-12.5-45.3 0L256 338.7 86.6 169.4c-12.5-12.5-32.8-12.5-45.3 0s-12.5 32.8 0 45.3l192 192z"/></svg>
|
||||||
</button>
|
</button>
|
||||||
|
|
||||||
<div id="terms" class="py-10 border-b-2 border-fuschia-600" x-show="show_footer">
|
<div id="terms" class="py-10 border-b-2 border-fuschia-600" x-show="show_footer">
|
||||||
{{ $entity->footer }}
|
{{ strip_tags($entity->footer) }}
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user