KUJUNTI.ID MINISH3LL
Path : /var/www/html/jewelry-pos/resources/views/warehouses/
(S)h3ll Cr3at0r :
F!le Upl0ad :

B-Con CMD Config cPanel C-Rdp D-Log Info Jump Mass Ransom Symlink vHost Zone-H

Current File : /var/www/html/jewelry-pos/resources/views/warehouses/print.blade.php


@extends('layouts.admin-main')
@section('content')
{{--    <style>--}}
{{--        @media print {--}}
{{--            @page {--}}
{{--                size: A4 landscape; /* auto is default portrait; */--}}
{{--            }--}}
{{--        }--}}
{{--    </style>--}}
    <div class="for-print" style="display: flex;justify-content: center;width: 100%;height: 100%;background-color: #eee;">
        <div class="text-center mt-4 ml-4 notPrint" style="width: 5%;; height: 50%;">
            <a href="{{route('warehouse-product.index' , $category->id)}}" id="back" name="back" class="btn-sm btn-danger mt-6 fw-bold notPrint" style="cursor: pointer;color: white;">Back</a>
        </div>
        <div class="" style="height: 100%;width: 90%;">
            <div class="text-center bg-white print" id="print" style="width: 100%;height: 100%;margin: auto;color: rebeccapurple">
                {{--                <div class="row" style="display: flex;justify-content: end;align-items: center;color: rebeccapurple">--}}
                {{--                    <div class="col-sm-4 col-xl-4 m-6 text-left" style="display:flex;justify-content: center;align-items: center;font-size: 14px">--}}
                {{--                        GRN Number--}}
                {{--                    </div>--}}
                {{--                </div>--}}
                <div class="row" style="display: flex;justify-content: center;align-items: center;color: rebeccapurple;">
                    <div class="col-sm-6 col-xl-6 p-2" style="border: 1px solid rebeccapurple;display: flex;justify-content: center;align-items: center;">
                        <h1 style="font-weight: bold;font-size: 24px">{{$settings_->shop_name}}</h1>
                    </div>
                </div>
                <div class="row m-2">
                    <div class="col-sm-6 col-xl-8 text-left mt-4" style="font-size: 14px;">
                        {{__('message.cashier')}} : <b>{{Auth::user()->name}}</b>
                    </div>
                    <div class="col-sm-6 col-xl-4 text-right mt-4" style="font-size: 14px;">
                        {{__('message.invoice date')}} : <b>{{now()->format('d-m-Y H:i')}}</b>
                    </div>
                </div>
                <div class="row m-2">
                    <div class="col-sm-8 col-xl-8 text-left mt-4" style="font-size: 14px">
                        {{__('message.location')}} : <b>{{$settings_->address}}</b>
                    </div>
                    <div class="col-sm-4 col-xl-4 text-right mt-4" style="font-size: 14px;">
                        {{__('message.phone number')}} : <b>{{$settings_->phone}}</b>
                    </div>
                </div>
                <div class="row m-2">
                    <div class="col-sm-8 col-xl-8 text-left mt-4" style="font-size: 14px">
                        {{__('message.product category')}} : <b>
                            @if($platinum_category_id && $platinum_category_id != $category->id)
                                {{$platinumCategories->find($platinum_category_id)->name}}
                            @else
                                {{$category->name}}
                            @endif
                        </b>
                    </div>
                    <div class="col-sm-4 col-xl-4 text-right mt-4" style="font-size: 14px;">
{{--                        {{__('message.phone number')}} : <b>{{$settings_->phone}}</b>--}}
                    </div>
                </div>
                <div class="row mt-4" style="display: flex;justify-content: center;align-items: center;color: rebeccapurple;">
                    <div class="col-sm-6 col-xl-12 p-2 text-center" style="display: flex;justify-content: center;align-items: center;">
                        <h1 style="font-weight: bold;border-bottom: 2px solid rebeccapurple;font-size: 18px" class="">{{__('message.warehouse balance report')}}</h1>
                    </div>
                </div>
                <div class="row ml-2 mt-2" style="width: 98%;display: flex;justify-content: center;align-items: center">
                    <table class="table table-bordered table-hover table-striped">
                        <thead class="bg-fusion-50 text-center">
                        <tr>
                            <th>#</th>
                            <th>{{__('message.original invoice')}}</th>
                            <th class="text-center">{{ __('message.part number') }}</th>
                            <th>{{ __('message.product name') }}</th>
                            <th>{{ __('message.qty') }}</th>
                            @if($category->name == 'មាស' || $category->name == 'Gold' || $category->name == 'ทอง')
                            @else
                                <th>{{ __('message.weight') }}</th>
                            @endif
                            @if($category->fixed_price)
                            @else
                                @if($category->name == 'ផលិតផលបន្ថែម' || $category->name == 'Other Stock' || $category->name == 'Extra Stock')

                                @else
                                    <th>{{ __('message.gold weight') }}</th>
                                @endif
                            @endif
                            <th>{{ __('message.diamond size') }}</th>
                            <th>{{ __('message.cost of sale') }}</th>
                            <th>{{ __('message.original wages') }}</th>
{{--                            <th>{{ __('message.gain lose amount') }}</th>--}}
                            <th>{{ __('message.sale wages') }}</th>
                            <th>{{ __('message.sales price') }}</th>
                            <th>{{ __('message.purity upgrade to') }}</th>
                            <th>{{ __('message.selling purity') }}</th>
                            <th>{{ __('message.image') }}</th>
                            <th>{{__('message.supplier')}}</th>
                            <th>{{__('message.supplier rate')}}</th>
                            <th>{{ __('message.created date') }}</th>
                        </tr>
                        </thead>
                        <tbody>
                        <?php
                            $totalGainLoseAmount = 0;
                        ?>
                        @foreach ($products as $index => $product)
                            <tr @if (!$product->is_active) class="inactive" @endif>
                                <td>{{ $index + 1 }}</td>
                                <td>{{$product->original_invoice??''}}</td>
                                <td class="text-center">{{$product->part_number}}</td>
                                <td>
                                    {{ $product->name ??''}}
                                </td>
                                <td class="credit">
                                    {{ $product->qty??0 }}
                                </td>
                                @if($category->name == 'មាស' || $category->name == 'Gold' || $category->name == 'ทอง')
                                @else
                                    <td class="credit">
                                        {{ number_format($product->weight ,2) }}
                                    </td>
                                @endif
                                @if($category->fixed_price)
                                @else
                                    @if($category->name == 'ផលិតផលបន្ថែម' || $category->name == 'Other Stock' || $category->name == 'Extra Stock')
                                    @else
                                        <td class="credit">
                                            {{number_format($product->goldWeight() ,2)}}
                                        </td>
                                    @endif
                                @endif
                                <td>
                                    {!!$product->diamond_size!!}
                                </td>
                                <td class="credit">
                                    {{ number_format($product->cost(), 2) }} {{$currency_->currency_symbol}}
                                </td>
                                <td class="credit">
                                    {{number_format($product->cost_wagesInWeight()??0 , 2)}} {{$currency_->currency_symbol}}
                                </td>
{{--                                <td class="credit" style="color: @if(($product->weight*$product->productCategory->price())-$product->cost($product->weight) < 0) red @endif;">--}}
{{--                                    {{number_format(($product->weight*$product->productCategory->price())-$product->cost($product->weight))}} {{$currency_->currency_symbol??''}}--}}
{{--                                </td>--}}
                                <td class="credit">
                                    {{number_format($product->selling_wagesInWeight()??0 , 2)}} {{$currency_->currency_symbol}}
                                </td>
                                @if($product->fixed_price)
                                    <td class="credit">
                                        {{number_format($product->price,2)}} {{$currency_->currency_symbol}}
                                    </td>
                                @else
                                    <td class="credit">
                                        {{number_format($product->sellingPrice(),2)}} {{$currency_->currency_symbol}}
                                    </td>
                                @endif
                                <td class="credit">
                                    @if($product->purity_upgrade_to)
                                        {{$product->purity_upgrade_to??''}}
                                    @endif
                                </td>
                                <td class="credit">
                                    @if($product->selling_purity)
                                        {{$product->selling_purity??''}}
                                    @endif
                                </td>
                                <td>
                                    <div class="col-xs-12 col-sm-10">
                                        <div class="d-flex justify-content-centers">
                                            @if($product->image)
                                                <img src="{{asset($product->image)}}" style="width:55px;">
                                            @else
                                            @endif
                                         </div>
                                    </div>
                                </td>
                                <td>{{$product->supplier->name??''}}</td>
                                <td class="credit">{{number_format($product->supplier_rate??0 , 0)}}</td>
                                <td>{{ $product->created_at->format('d/m/Y H:i') }}</td>
                            </tr>
                            <?php
                                $totalGainLoseAmount += ($product->weight*$product->productCategory->price())-$product->cost($product->weight);
                            ?>
                        @endforeach
                        @if(!$category->fixed_price)

                            <tr style="font-weight:400;font-size:16px;background-color: #99b288;">
                                <th colspan="4" style="text-align: center;">
                                    {{__('message.total')}} :
                                </th>
                                <th colspan="" style="text-align: left;" class="credit">
                                    {{number_format($totalQty,0)}}
                                </th>
                                @if($category->name=='Platinum'|| $category->name=='ផ្លាកទីន'||$category->name=='แพลตตินัม' || $category->name == 'ផ្លាកទីន វៀតណាម'|| $category->name == 'ផ្លាកទីនទឹក 8')
                                    <th colspan="" class="credit">
                                        {{number_format($totalWeight ,2)}}
                                    </th>
                                @endif
                                <th colspan="" style="text-align: left;" class="credit">
                                    {{number_format($totalGoldWeight,2)}}
                                </th>
                                <th></th>
                                <th colspan="" style="text-align: left;" class="credit">
                                    {{number_format($totalCost,2)}} {{$currency_->currency_symbol??''}}
                                </th>
                                <th colspan="" style="text-align: left;" class="credit">
                                    {{number_format($totalOriginalWage,2)}} {{$currency_->currency_symbol??''}}
                                </th>
{{--                                <td class="credit">--}}
{{--                                    {{number_format($totalGainLoseAmount,2)}} {{$currency_->currency_symbol??''}}--}}
{{--                                </td>--}}
                                <th class="credit">
                                    {{number_format($totalWage,2)}} {{$currency_->currency_symbol??''}}
                                </th>
                                <th colspan="" style="text-align: center;" class="credit">
                                    {{number_format($totalPrice,2)}} {{$currency_->currency_symbol??''}}
                                </th>

                            </tr>

                        @else

                            <tr style="font-weight:400;font-size:16px;background-color: #99b288;">
                                <th colspan="4" style="text-align: center;">
                                    {{__('message.total')}} :
                                </th>
                                <th colspan="" style="text-align: left;" class="credit">
                                    {{number_format($totalQty,0)}}
                                </th>
                                <th colspan="" class="credit">
                                    {{number_format($totalWeight ,2)}}
                                </th>
                                <th></th>
                                <th colspan="" style="text-align: left;" class="credit">
                                    {{number_format($totalCost,2)}} {{$currency_->currency_symbol??''}}
                                </th>
                                <th colspan="" style="text-align: left;" class="credit">
                                    {{number_format($totalOriginalWage,2)}} {{$currency_->currency_symbol??''}}
                                </th>
                                <th class="credit">
                                    {{number_format($totalWage,2)}} {{$currency_->currency_symbol??''}}
                                </th>
                                <th colspan="" style="text-align: center;" class="credit">
                                     {{number_format($totalPrice,2)}} {{$currency_->currency_symbol??''}}
                                </th>

                            </tr>
                        @endif
                        </tbody>
                    </table>
                </div>
            </div>
        </div>
        <div class="text-center mt-4 mr-4 notPrint" style="width: 5%;; height: 50%;">
            <a id="print" name="print" class="btn-sm btn-info mt-6 fw-bold notPrint" onclick="return print()" style="cursor: pointer;color: white;">Print</a>
        </div>
    </div>
    <div class="page-number"></div>
@endsection
@section('scripts')
    <script>

        window.print();
        setTimeout("closePrintView()", 1000);
        function closePrintView(){
              window.location.href = "{{route('warehouse-product.index' , $category->id)}}?start_date={{$start_date}}&end_date={{$end_date}}&search={{$search}}&paginate={{$paginate}}";
        }
    </script>
    <script>
        $(document).ready(function() {
            $("#js-nav-menu").removeClass('active');
            $("#js-nav-menu li ul li").removeClass('active');
            // $("#menu_setup_list").addClass('active open');
            // $("#collapse_setup").addClass('collapse in')
            $("#menu_product").addClass('active')
        })
    </script>
@endsection

© KUJUNTI.ID