mirror of
https://gitlab.com/CIEFWorldwideSdnBhd/exchange-2.0.git
synced 2026-08-19 04:23:55 +00:00
Merge branch 'export-currency-vendor-order-module' of gitlab.com:CIEFWorldwideSdnBhd/exchange-2.0
This commit is contained in:
Vendored
+7
@@ -34,6 +34,13 @@ Vue.use(VueTheMask);
|
||||
Vue.use(filters);
|
||||
|
||||
Vue.directive('closable', closable);
|
||||
Vue.directive('tooltip', function(el, binding){
|
||||
$(el).tooltip({
|
||||
title: binding.value,
|
||||
placement: binding.arg,
|
||||
trigger: 'hover'
|
||||
})
|
||||
})
|
||||
Vue.mixin({
|
||||
methods: {
|
||||
route: route
|
||||
|
||||
@@ -13,7 +13,7 @@
|
||||
<download-supplier-white-form-component section="paymentsReportSection" ></download-supplier-white-form-component>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="row m-b-20">
|
||||
<div class="col-12 col-md-6">
|
||||
<div class="row">
|
||||
<div class="col p-l-0">
|
||||
|
||||
@@ -17,6 +17,28 @@
|
||||
{{item.issuer_name}}
|
||||
</div>
|
||||
</div>
|
||||
<div class="col">
|
||||
<div class="font-heading fs-10 muted all-caps text-right">Export</div>
|
||||
<div class="row parentcontainer">
|
||||
<div class="col d-flex justify-content-end">
|
||||
<a :href="route('group.text', item.id)" target="_blank" v-tooltip:top="'Export in Text'" class="m-l-5">
|
||||
<button class="btn btn-xs b-rad-none">
|
||||
<i class="fa fa-font"></i>
|
||||
</button>
|
||||
</a>
|
||||
<a :href="route('group.excel', item.id)" target="_blank" v-tooltip:top="'Export in Excel'" class="m-l-5">
|
||||
<button class="btn btn-xs b-rad-none">
|
||||
<i class="fa fa-file-excel-o"></i>
|
||||
</button>
|
||||
</a>
|
||||
<a :href="route('group.invoice', item.id)" target="_blank" v-tooltip:top="'Export Invoice PDF'" class="m-l-5">
|
||||
<button class="btn btn-xs b-rad-none">
|
||||
<i class="fa fa-list-alt"></i>
|
||||
</button>
|
||||
</a>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col-auto">
|
||||
@@ -79,11 +101,6 @@
|
||||
<div class="col-auto">
|
||||
<div class="row parentContainer">
|
||||
<div class="col p-l-0">
|
||||
<a :href="route('group.text', item.id)" target="_blank">
|
||||
<button class="btn btn-xs b-rad-none">
|
||||
<i class="fa fa-align-left"></i>
|
||||
</button>
|
||||
</a>
|
||||
<button class="btn btn-xs btn-complete b-rad-none">
|
||||
<i class="fa fa-refresh" @click="updateDo()"></i>
|
||||
</button>
|
||||
|
||||
@@ -0,0 +1,77 @@
|
||||
|
||||
<table style="margin-bottom: 25px; border: none;">
|
||||
<tbody>
|
||||
<tr>
|
||||
<td>{{$supplier->name}}</td>
|
||||
<td>{{\Carbon\Carbon::now('Asia/Singapore')->format('d-m-Y h:s')}}</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
<br>
|
||||
<table style="width:100%">
|
||||
<tbody>
|
||||
<tr>
|
||||
<td>Reference</td>
|
||||
<td>Marking</td>
|
||||
<td>Rate</td>
|
||||
<td>Amount</td>
|
||||
<td>Bank in Details</td>
|
||||
</tr>
|
||||
@foreach($transactions as $transaction)
|
||||
<tr style="margin-bottom: 10px;">
|
||||
<td>{{$transaction->owner->owner->marking}}</td>
|
||||
<td>{{$transaction->owner->owner->company->reference}}</td>
|
||||
<td>{{$transaction->currency_rate}}</td>
|
||||
<td>{{$transaction->currency->short_code}} {{number_format((float)$transaction->amount, 2, '.', '')}}</td>
|
||||
<td>Account Holder Name: {{$transaction->owner->owner->bank->holder_name}}<br>{{$transaction->owner->owner->bank->bank_name}}: {{$transaction->owner->owner->bank->account_no}}
|
||||
<br>Branch: {{$transaction->owner->owner->bank->bank_branch}}@if($transaction->original_currency->short_code === 'USD')<br>Swift Code: {{$transaction->owner->owner->bank->swift}}@endif<br>Bank in Amount: {{$transaction->original_currency->short_code}} {{$transaction->original_amount}}</td>
|
||||
</tr>
|
||||
@endforeach
|
||||
</tbody>
|
||||
</table>
|
||||
<table style="margin-bottom: 25px; border: none;">
|
||||
<tbody>
|
||||
<tr>
|
||||
<td width="70%" style="text-align: right;" colspan="4">Sub total booking amount: </td>
|
||||
@php
|
||||
$sub_total_booking_amount = number_format((float)$transactions->sum('original_amount'), 2, '.', '');
|
||||
@endphp
|
||||
<td>{{$transaction->original_currency->short_code}} {{$sub_total_booking_amount}}</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td width="70%" style="text-align: right;" colspan="4">Transfer fee: </td>
|
||||
@php
|
||||
$transfer_fee = number_format((float)$transferFeeTransactions->sum('service_charge'), 2, '.', '');
|
||||
@endphp
|
||||
<td>{{$transaction->original_currency->short_code}} {{$transfer_fee}}</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td width="70%" style="text-align: right;" colspan="4">Total booking amount: </td>
|
||||
@php
|
||||
$total_booking_amount = number_format((float) ($transactions->sum('original_amount') + $transfer_fee), 2, '.', '');
|
||||
@endphp
|
||||
<td>{{$transaction->original_currency->short_code}} {{$total_booking_amount}}</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td width="70%" style="text-align: right;" colspan="4">Sub total amount: </td>
|
||||
@php
|
||||
$sub_total_amount = number_format((float)$transactions->sum('amount') + ($transfer_fee * 1/$transactions[0]->currency_rate), 2, '.', '');
|
||||
@endphp
|
||||
<td>MYR {{$sub_total_amount}}</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td width="70%" style="text-align: right;" colspan="4">Service charge: </td>
|
||||
@php
|
||||
$service_charge = number_format((float)$transactions->sum('service_charge'), 2, '.', '');
|
||||
@endphp
|
||||
<td>MYR {{$service_charge}}</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td width="70%" style="text-align: right;" colspan="4">Total amount: </td>
|
||||
@php
|
||||
$total_amount = number_format((float)$sub_total_amount + $service_charge, 2, '.', '');
|
||||
@endphp
|
||||
<td>MYR {{$total_amount}}</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
@@ -0,0 +1,85 @@
|
||||
@extends('layouts.base_pdf')
|
||||
<htmlpageheader name="page-header">
|
||||
<br>
|
||||
<table width="100%" style="border-bottom: 1px solid black;">
|
||||
<tr>
|
||||
<td style="text-align: center; color: red; text-transform: uppercase; font-weight: bold; font-size: 18px; padding-bottom: 5px;">
|
||||
{{ $supplier->name }}
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
</htmlpageheader>
|
||||
<table>
|
||||
<tr>
|
||||
<td class="title">
|
||||
<strong>Invoice</strong>
|
||||
</td>
|
||||
<td class="document-detail">
|
||||
PO#: {{$group->reference}} <br>
|
||||
Ref#: {{$supplier->reference}} <br>
|
||||
Date: {{$group->created_at}}
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
|
||||
<br>
|
||||
|
||||
<table class="buyer-seller">
|
||||
<tr>
|
||||
<td width="50%" class="top">
|
||||
<span class="buyer-seller-title">
|
||||
Buyer
|
||||
</span>
|
||||
<br>
|
||||
<span class="buyer-company">
|
||||
CIEF Worldwide Sdn Bhd (1134596-M)
|
||||
</span>
|
||||
<div class="address">
|
||||
No. 72-3, Jalan Jalil 1,<br>
|
||||
The Earth Bukit Jalil,<br>
|
||||
57000 Kuala Lumpur
|
||||
</div>
|
||||
<div class="contact-no">
|
||||
Tel: 03-8082 1252
|
||||
</div>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
|
||||
<br>
|
||||
|
||||
<table class="line-table" style="overflow: wrap" autosize="1">
|
||||
<thead>
|
||||
<tr>
|
||||
<th width="5%">No</th>
|
||||
<th class="marking" width="10%">Marking</th>
|
||||
<th class="description">Description</th>
|
||||
<th width="10%">Currency Rate</th>
|
||||
<th width="15%">Unit Price (RM)</th>
|
||||
<th width="10%">Total Amount<br>(RM)</th>
|
||||
</tr>
|
||||
</thead>
|
||||
|
||||
<tbody>
|
||||
|
||||
@foreach($transactions as $key => $transaction)
|
||||
<tr style="margin-bottom: 10px;">
|
||||
<td width="5%" class="center top">{{ $key + 1 }}</td>
|
||||
<td class="marking top" width="10%">{{$transaction->owner->owner->marking}}</td>
|
||||
<td class="description">Please refer to the appedix reference no: {{$transaction->owner->owner->marking}}</td>
|
||||
<td width="10%" class="center top">{{$transaction->currency_rate}}</td>
|
||||
<td>{{$transaction->currency->short_code}} {{number_format((float)$transaction->amount, 2, '.', '')}}</td>
|
||||
@php
|
||||
$sub_total_booking_amount = number_format((float)$transactions->sum('original_amount'), 2, '.', '');
|
||||
$transfer_fee = number_format((float)$transferFeeTransactions->sum('service_charge'), 2, '.', '');
|
||||
$total_booking_amount = number_format((float) ($transactions->sum('original_amount') + $transfer_fee), 2, '.', '');
|
||||
$sub_total_amount = number_format((float)$transactions->sum('amount') + ($transfer_fee * 1/$transactions[0]->currency_rate), 2, '.', '');
|
||||
$service_charge = number_format((float)$transactions->sum('service_charge'), 2, '.', '');
|
||||
$total_amount = number_format((float)$sub_total_amount + $service_charge, 2, '.', '');
|
||||
@endphp
|
||||
<td>MYR {{$total_amount}}</td>
|
||||
</tr>
|
||||
@endforeach
|
||||
</tbody>
|
||||
|
||||
</table>
|
||||
Reference in New Issue
Block a user