VaKeR CYBER ARMY
Logo of a company Server : Apache
System : Linux host44.registrar-servers.com 4.18.0-513.18.1.lve.2.el8.x86_64 #1 SMP Sat Mar 30 15:36:11 UTC 2024 x86_64
User : vapecompany ( 2719)
PHP Version : 7.4.33
Disable Function : NONE
Directory :  /proc/thread-self/root/home/vapecompany/demo.vapecompany.com.bd/resources/views/backend/chalan/

Upload File :
current_dir [ Writeable ] document_root [ Writeable ]

 

Current File : //proc/thread-self/root/home/vapecompany/demo.vapecompany.com.bd/resources/views/backend/chalan/show.blade.php
@extends('backend.layout.app')
@section('content')
<div class="page-wrapper">
<div class="container-fluid">
    <div class="row">
        <div class="col-12">
            <div class="card mb-4 rounded-0">
                <div class="card-header py-3 d-flex flex-row align-items-center justify-content-between">
                    <h6 class="m-0 font-weight-bold text-primary">Challan Details</h6>
                    <div class="btn-group btn-group-sm" role="group" aria-label="Basic example">
                        {{-- @if(auth()->user()->canEvent('p_office_a')) --}}
                        <a href="{{url('/print_chalan/'.$chalan->chalan_id.'/1')}}" target="_blank" class="btn btn-warning rounded-0"><i class="fa fa-print"></i> Print(Office Copy-A) </a> 
                        {{-- @endif
                        @if(auth()->user()->canEvent('p_office_w')) --}}
                        <a href="{{url('/print_chalan/'.$chalan->chalan_id.'/2')}}" target="_blank" class="btn btn-warning rounded-0"><i class="fa fa-print"></i> Print(Office Copy-W) </a>
                        {{-- @endif
                        @if(auth()->user()->canEvent('p_customer_copy')) --}}
                        <a href="{{url('/print_chalan/'.$chalan->chalan_id.'/3')}}" target="_blank" class="btn btn-warning rounded-0"><i class="fa fa-print"></i> Print(Customer Copy) </a> 
                        {{-- @endif --}}

                    </div>
                </div>
                <div class="card-body">
                    <div class="row mb-4">
                        <div class="col-md-4">
                            <table class="table table-bordered table-sm">
                                <thead>
                                    <tr class="bg-secondary text-white text-center">
                                        <th colspan="2">Customer Info</th>
                                    </tr>
                                </thead>
                                <tbody>
                                <tr>
                                    <td>Name</td>
                                    <td>{{$chalan->customer->customer_name}}</td>
                                </tr>
                                <tr>
                                    <td>Address</td>
                                    <td>{{$chalan->customer->customer_address}}</td>
                                </tr>
                                 @if($chalan->customer->customer_email)
                                <tr>
                                    <td>Email</td>
                                    <td>{{$chalan->customer->customer_email}}</td>
                                </tr>
                                @endif
                                 @if($chalan->customer->customer_phone)
                                <tr>
                                    <td>Phone</td>
                                    <td>{{$chalan->customer->customer_phone}}</td>
                                </tr>
                                @endif
                                 @if($chalan->customer->customer_mobile)
                                <tr>
                                    <td>Mobile</td>
                                    <td>{{$chalan->customer->customer_mobile}}</td>
                                </tr>
                                @endif
                               
                                
                                </tbody>
                            </table>
                        </div>
                       
                        <div class="col-md-4">
                            <table class="table table-bordered table-sm">
                                <thead>
                                <tr class="bg-secondary text-white text-center">
                                    <th colspan="2">Challan Summary</th>
                                </tr>
                                </thead>
                                <tbody>
                                <tr>
                                    <td>Challan Code</td>
                                    <td>{{$chalan->chalan_number}}</td>
                                </tr>
                                 <tr>
                                    <td>Invoice Number</td>
                                    <td>{{$chalan->invoice_number}}</td>
                                </tr>

                                @if($chalan->chalan_status ==  1)
                                    <tr>
                                        <td>Created Date</td>
                                        <td>{{$chalan->chalan_date->format('Y-m-d')}}</td>
                                    </tr>
                                @elseif($chalan->chalan_status == 2) 
                                    <tr>
                                        <td>Delivered Date</td>
                                        {{-- <td>{{$chalan->status_update_at->format('d-m-Y')}}</td> --}}
                                    </tr>
                               
                                @endif
                                 <tr>
                                    <td>Deliver Mode</td>
                                    <td>
                                         @if($chalan->delivery_mode ==  1)
                                        Courier 
                                        @else
                                       Others
                                        @endif
                                    </td>
                                </tr>
                                
                                <tr>
                                    <td>Status</td>
                                    <td class="p-0">
                                        @if($chalan->chalan_status == 1)
                                            <label class="btn btn-info btn-sm btn-block m-0"><b>Pending</b></label>
                                        @elseif($chalan->chalan_status == 2)
                                            <label class="btn btn-success btn-sm btn-block m-0"><b>Delivered</b></label>
                                        @elseif($chalan->chalan_status == 3)
                                        <label class="btn btn-danger btn-sm btn-block m-0"><b>Rejected</b></label>
                                        @endif
                                    </td>
                                </tr>
                                </tbody>
                            </table>
                        </div>
                         @if($chalan->delivery_mode == 1 )
                         <div class="col-md-4">
                            <table class="table table-bordered table-sm">
                                <thead>
                                <tr class="bg-secondary text-white text-center">
                                    <th colspan="2">Courier Info</th>
                                </tr>
                                </thead>
                                <tbody>
                                <tr>
                                    <td>Courier Name</td>
                                    <td>{{$chalan->courier->courier_name}}</td>
                                </tr>
                                @if($chalan->track_no)
                                <tr>
                                    <td>Track No.</td>
                                    <td>{{$chalan->track_no}}</td>
                                </tr>
                                @endif
                                @if($chalan->courier->courier_address)
                                <tr>
                                    <td>Courier Address</td>
                                    <td>{{$chalan->courier->courier_address}}</td>
                                </tr>
                                @endif
                                @if($chalan->courier->courier_phone)
                                <tr>
                                    <td>Courier Phone</td>
                                    <td>{{$chalan->courier->courier_phone}}</td>
                                </tr>
                                @endif
                                
                                @if($chalan->courier->courier_mobile)
                                <tr>
                                    <td>Courier Mobile</td>
                                    <td>{{$chalan->courier->courier_mobile}}</td>
                                </tr>
                                @endif
                                
                                
                                </tbody>
                            </table>
                        </div>
                        @endif
                    </div>

                    <div class="table-responsive">
                        <table class="table table-bordered text-center table-sm" width="100%" cellspacing="0">
                            <thead>
                            <tr class="bg-secondary text-white">
                                <th>SL</th>
                                <th>Category</th>
                                <th>Product</th>
                                {{-- <th>Model</th> --}}
                                <th>Color</th>
                                <th>Quantity</th>
                            </tr>
                            </thead>
                            <tbody>
                            @foreach($chalan->chalan_details->sortBy(function ($product, $key) {

                        return $product['product_id'];

                    }) as $key => $requisition_product)
                                <tr>
                                    <td width="3%">{{$key+1}}</td>
                                    <td>{{$requisition_product->product->category->category_name}}</td>
                                    <td> {{$requisition_product->product->product_name}} </td>
                                    {{-- <td> {{$requisition_product->product->model->model_name}} </td> --}}
                                    {{-- <td> {{$requisition_product->color->color_name}} </td> --}}
                                    <td> {{$requisition_product->product_quantity}} </td>

                                </tr>
                            @endforeach
                            <tr>
                                <td colspan="5" class="text-right pr-5">
                                    <strong>Total Quantity:</strong>
                                </td>

                                <td>
                                    <strong>{{$chalan->chalan_details->sum('product_quantity')}}</strong>
                                </td>
                            </tr>
                            </tbody>
                        </table>
                        @if($chalan->chalan_status == 1)
                        {{-- @if(auth()->user()->canEvent('chalan_status')) --}}
                             
                   		     <a href="{{route('update_chalan_status', [$chalan->chalan_id,'delivered'])}}" class="btn btn-primary rounded-0 btn-block" onclick="return confirm('Are you Delivered Chalan ? ')"> Delivered </a>
                                 <a href="{{route('update_chalan_status', [$chalan->chalan_id,'reject'])}}" class="btn btn-danger rounded-0 btn-block" onclick="return confirm('Are you sure. you want to cancel this requisition ?')"> Reject </a>
                         {{-- @endif   --}}
                         @endif

                    
                    </div>
                </div>
            </div>
        </div>
    </div>
</div>
</div>
@endsection

VaKeR 2022