migrate to gtea from bistbucket
This commit is contained in:
@@ -0,0 +1,52 @@
|
||||
<div class="responsive-table m-0">
|
||||
<table class="table" id="datatable">
|
||||
<thead>
|
||||
<tr>
|
||||
<th class="d-print-none">{{ __('SL') }}.</th>
|
||||
<th class="text-start">{{ __('Date') }}</th>
|
||||
<th class="text-start">{{ __('Invoice') }}</th>
|
||||
<th class="text-start">{{ __('Description') }}</th>
|
||||
<th class="text-start">{{ __('Credit (In)') }}</th>
|
||||
<th class="text-start">{{ __('Debit (Out)') }}</th>
|
||||
<th class="text-start">{{ __('Balance') }}</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
@php
|
||||
$totalCredit = 0;
|
||||
$totalDebit = 0;
|
||||
@endphp
|
||||
@foreach ($ledger as $index => $row)
|
||||
@php
|
||||
$totalCredit += $row['credit_amount'];
|
||||
$totalDebit += $row['debit_amount'];
|
||||
@endphp
|
||||
<tr>
|
||||
<td class="text-start">{{ $index + 1 }}</td>
|
||||
<td class="text-start">{{ formatted_date($row['date']) }}</td>
|
||||
|
||||
<td class="text-start">
|
||||
<a target="_blank" href="{{ $row['platform'] === 'Purchase' ? route('business.purchases.invoice', $row['id'] ?? '') : route('business.collect.dues.invoice', $row['id'] ?? '') }}" class="stock-view-data text-primary">
|
||||
{{ $row['invoice_no'] ?? '-' }} - {{ $row['id'] }}
|
||||
</a>
|
||||
</td>
|
||||
<td class="d-print-none text-start">{{ $row['platform'] }}</td>
|
||||
<td class="text-start">{{ currency_format($row['credit_amount'], currency: business_currency()) }}</td>
|
||||
<td class="text-start">{{ currency_format($row['debit_amount'], currency: business_currency()) }}</td>
|
||||
<td class="text-start">{{ currency_format($row['balance'], currency: business_currency()) }}</td>
|
||||
</tr>
|
||||
@endforeach
|
||||
</tbody>
|
||||
@if ($ledger->count() > 0)
|
||||
<tr class="table-footer">
|
||||
<td class="text-start">{{__('Total')}}</td>
|
||||
<td class="d-print-none"></td>
|
||||
<td></td>
|
||||
<td></td>
|
||||
<td class="text-start">{{ currency_format($totalCredit, currency: business_currency()) }}</td>
|
||||
<td class="text-start ">{{ currency_format($totalDebit, currency: business_currency()) }}</td>
|
||||
<td class="text-start ">{{ currency_format($ledger->last()['balance'] ?? 0, currency: business_currency()) }}</td>
|
||||
</tr>
|
||||
@endif
|
||||
</table>
|
||||
</div>
|
||||
@@ -0,0 +1,47 @@
|
||||
<table class="table" id="datatable">
|
||||
<thead>
|
||||
<tr>
|
||||
<th class="d-print-none">{{ __('SL') }}.</th>
|
||||
<th class="text-start">{{ __('Date') }}</th>
|
||||
<th class="text-start">{{ __('Invoice') }}</th>
|
||||
<th class="text-start">{{ __('Description') }}</th>
|
||||
<th class="text-start">{{ __('Credit (In)') }}</th>
|
||||
<th class="text-start">{{ __('Debit (Out)') }}</th>
|
||||
<th class="text-start">{{ __('Balance') }}</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
@php
|
||||
$totalCredit = 0;
|
||||
$totalDebit = 0;
|
||||
@endphp
|
||||
@foreach ($ledger as $index => $row)
|
||||
@php
|
||||
$totalCredit += $row['credit_amount'];
|
||||
$totalDebit += $row['debit_amount'];
|
||||
@endphp
|
||||
<tr>
|
||||
<td class="text-start">{{ $index + 1 }}</td>
|
||||
<td class="text-start">{{ formatted_date($row['date']) }}</td>
|
||||
<td class="text-start">
|
||||
{{ $row['invoice_no'] ?? '-' }} - {{ $row['id'] }}
|
||||
</td>
|
||||
<td class="d-print-none text-start">{{ $row['platform'] }}</td>
|
||||
<td class="text-start">{{ currency_format($row['credit_amount']) }}</td>
|
||||
<td class="text-start">{{ currency_format($row['debit_amount']) }}</td>
|
||||
<td class="text-start">{{ currency_format($row['balance']) }}</td>
|
||||
</tr>
|
||||
@endforeach
|
||||
</tbody>
|
||||
@if ($ledger->count() > 0)
|
||||
<tr class="table-footer">
|
||||
<td class="text-start fw-bold">{{__('Total')}}</td>
|
||||
<td></td>
|
||||
<td></td>
|
||||
<td></td>
|
||||
<td class="text-center fw-bold">{{ currency_format($totalCredit, currency: business_currency()) }}</td>
|
||||
<td class="text-end fw-bold ">{{ currency_format($totalDebit, currency: business_currency()) }}</td>
|
||||
<td class="text-end fw-bold ">{{ currency_format($ledger->last()['balance'] ?? 0, currency: business_currency()) }}</td>
|
||||
</tr>
|
||||
@endif
|
||||
</table>
|
||||
@@ -0,0 +1,98 @@
|
||||
@extends('layouts.business.master')
|
||||
|
||||
@section('title')
|
||||
{{ $party->name }} {{ __("(Supplier Ledger)") }}
|
||||
@endsection
|
||||
|
||||
@section('main_content')
|
||||
<div class="erp-table-section">
|
||||
<div class="container-fluid">
|
||||
<div class="card">
|
||||
<div class="card-bodys">
|
||||
<div class="table-header p-16 d-print-none">
|
||||
<h4>{{ $party->name }} {{ __('(Ledger)') }}</h4>
|
||||
</div>
|
||||
|
||||
<div class="table-header justify-content-center border-0 d-none d-block d-print-block text-center">
|
||||
@include('business::print.header')
|
||||
<h4 class="mt-2">{{ __('supplier Ledger') }}</h4>
|
||||
</div>
|
||||
|
||||
<div class="table-top-form p-16">
|
||||
<form action="{{ route('business.supplier-ledger.show', $party->id) }}" method="GET" class="filter-form" table="#supplier-ledger-data">
|
||||
<div class="table-top-left d-flex gap-3 d-print-none flex-wrap">
|
||||
<div class="custom-from-to align-items-center date-filters d-none">
|
||||
<label class="header-label">{{ __('From Date') }}</label>
|
||||
<input type="date" name="from_date" value="{{ request('from_date') ?? now()->format('Y-m-d') }}" class="form-control">
|
||||
</div>
|
||||
<div class="custom-from-to align-items-center date-filters d-none">
|
||||
<label class="header-label">{{ __('To Date') }}</label>
|
||||
<input type="date" name="to_date" value="{{ request('to_date') ?? now()->format('Y-m-d') }}" class="form-control">
|
||||
</div>
|
||||
<div class="gpt-up-down-arrow position-relative d-print-none custom-date-filter">
|
||||
<select name="duration" class="form-control custom-days">
|
||||
<option value="">{{ __('All') }}</option>
|
||||
<option value="today"> {{ __('Today') }}</option>
|
||||
<option value="yesterday"> {{ __('Yesterday') }}</option>
|
||||
<option value="last_seven_days"> {{ __('Last 7 Days') }}</option>
|
||||
<option value="last_thirty_days"> {{ __('Last 30 Days') }}</option>
|
||||
<option value="current_month">{{ __('Current Month') }}</option>
|
||||
<option value="last_month"> {{ __('Last Month') }}</option>
|
||||
<option value="current_year"> {{ __('Current Year') }}</option>
|
||||
<option value="custom_date"> {{ __('Custom Date') }}</option>
|
||||
</select>
|
||||
|
||||
<span></span>
|
||||
<div class="calendar-icon">
|
||||
<svg width="16" height="16" viewBox="0 0 16 16" fill="none"
|
||||
xmlns="http://www.w3.org/2000/svg">
|
||||
<path d="M12.6667 2.67188H3.33333C2.59695 2.67188 2 3.26883 2 4.00521V13.3385C2 14.0749 2.59695 14.6719 3.33333 14.6719H12.6667C13.403 14.6719 14 14.0749 14 13.3385V4.00521C14 3.26883 13.403 2.67188 12.6667 2.67188Z"
|
||||
stroke="#4B5563" stroke-width="1.5" stroke-linecap="round"
|
||||
stroke-linejoin="round" />
|
||||
<path d="M10.6641 1.32812V3.99479" stroke="#4B5563" stroke-width="1.5"
|
||||
stroke-linecap="round" stroke-linejoin="round" />
|
||||
<path d="M5.33594 1.32812V3.99479" stroke="#4B5563" stroke-width="1.5"
|
||||
stroke-linecap="round" stroke-linejoin="round" />
|
||||
<path d="M2 6.67188H14" stroke="#4B5563" stroke-width="1.5" stroke-linecap="round"
|
||||
stroke-linejoin="round" />
|
||||
</svg>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</form>
|
||||
|
||||
<div class="table-top-btn-group d-print-none">
|
||||
<ul>
|
||||
<li>
|
||||
<a href="{{ route('business.single-supplier-ledger.csv', $party->id) }}">
|
||||
<img src="{{ asset('assets/images/logo/csv.svg') }}" alt="">
|
||||
</a>
|
||||
</li>
|
||||
<li>
|
||||
<a href="{{ route('business.single-supplier-ledger.excel', $party->id) }}">
|
||||
<img src="{{ asset('assets/images/logo/excel.svg') }}" alt="">
|
||||
</a>
|
||||
</li>
|
||||
<li>
|
||||
<a target="blank" href="{{ route('business.single-supplier-ledger.pdf', $party->id) }}">
|
||||
<img src="{{ asset('assets/images/logo/pdf.svg') }}" alt="">
|
||||
</a>
|
||||
</li>
|
||||
<li>
|
||||
<a onclick="window.print()" class="print-window">
|
||||
<img src="{{ asset('assets/images/logo/printer.svg') }}" alt="">
|
||||
</a>
|
||||
</li>
|
||||
</ul>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div id="supplier-ledger-data">
|
||||
@include('business::party-reports.supplier-ledger.show-details.datas')
|
||||
</div>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
@endsection
|
||||
@@ -0,0 +1,84 @@
|
||||
@extends('layouts.business.pdf.pdf_layout')
|
||||
|
||||
@section('pdf_title')
|
||||
<div class="table-header justify-content-center border-0 d-none d-block d-print-block text-center">
|
||||
@include('business::print.header')
|
||||
<p style="text-align: center; margin: 0; padding: 0; margin-bottom:5px; font-size: 16px;">
|
||||
{{ $party->name }} ({{ __('Ledger')}})
|
||||
</p>
|
||||
@endsection
|
||||
|
||||
@section('pdf_content')
|
||||
|
||||
<table width="100%" cellpadding="6" cellspacing="0"
|
||||
style="border-collapse: collapse; border: 1px solid gainsboro; font-size:12px;">
|
||||
|
||||
<thead>
|
||||
<tr style="background-color: #C52127; color: white;">
|
||||
<th style="font-size:12px; border:1px solid gainsboro; color: white">{{ __('Date') }}</th>
|
||||
<th style="font-size:12px; border:1px solid gainsboro; color: white">{{ __('Invoice') }}</th>
|
||||
<th style="font-size:12px; border:1px solid gainsboro; color: white">{{ __('Description') }}</th>
|
||||
<th style="font-size:12px; border:1px solid gainsboro; color: white">{{ __('Credit (In)') }}</th>
|
||||
<th style="font-size:12px; border:1px solid gainsboro; color: white">{{ __('Debit (Out)') }}</th>
|
||||
<th style="font-size:12px; border:1px solid gainsboro; color: white">{{ __('Balance') }}</th>
|
||||
</tr>
|
||||
</thead>
|
||||
|
||||
<tbody>
|
||||
@php
|
||||
$totalCredit = 0;
|
||||
$totalDebit = 0;
|
||||
@endphp
|
||||
|
||||
@foreach ($ledger as $index => $row)
|
||||
@php
|
||||
$totalCredit += $row['credit_amount'];
|
||||
$totalDebit += $row['debit_amount'];
|
||||
@endphp
|
||||
|
||||
<tr style="background-color: {{ $loop->even ? '#F5F5F5' : '#FFFFFF' }};">
|
||||
<td style="border:1px solid gainsboro; text-align:center;">
|
||||
{{ formatted_date($row['date']) }}
|
||||
</td>
|
||||
<td style="border:1px solid gainsboro; text-align:center;">
|
||||
{{ $row['invoice_no'] ?? '-' }} - {{ $row['id'] }}
|
||||
</td>
|
||||
<td style="border:1px solid gainsboro; text-align:center;">
|
||||
{{ $row['platform'] }}
|
||||
</td>
|
||||
<td style="border:1px solid gainsboro; text-align:center;">
|
||||
{{ currency_format($row['credit_amount'], currency: business_currency()) }}
|
||||
</td>
|
||||
<td style="border:1px solid gainsboro; text-align:center;">
|
||||
{{ currency_format($row['debit_amount'], currency: business_currency()) }}
|
||||
</td>
|
||||
<td style="border:1px solid gainsboro; text-align:center;">
|
||||
{{ currency_format($row['balance'], currency: business_currency()) }}
|
||||
</td>
|
||||
</tr>
|
||||
@endforeach
|
||||
</tbody>
|
||||
|
||||
@if ($ledger->count() > 0)
|
||||
<tr style="background-color:#C52127; color:#FFFFFF; font-weight:bold;">
|
||||
<td style="border:1px solid gainsboro; text-align:center; color: white; font-weight: 600;">{{ __('Total') }}</td>
|
||||
<td style="border:1px solid gainsboro;"></td>
|
||||
<td style="border:1px solid gainsboro;"></td>
|
||||
|
||||
<td style="border:1px solid gainsboro; text-align:center; color: white; font-weight: 600;">
|
||||
{{ currency_format($totalCredit, currency: business_currency()) }}
|
||||
</td>
|
||||
|
||||
<td style="border:1px solid gainsboro; text-align:center; color: white; font-weight: 600;">
|
||||
{{ currency_format($totalDebit, currency: business_currency()) }}
|
||||
</td>
|
||||
|
||||
<td style="border:1px solid gainsboro; text-align:center; color: white; font-weight: 600;">
|
||||
{{ currency_format($ledger->last()['balance'] ?? 0, currency: business_currency()) }}
|
||||
</td>
|
||||
</tr>
|
||||
@endif
|
||||
|
||||
</table>
|
||||
|
||||
@endsection
|
||||
Reference in New Issue
Block a user