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 :  /home/vapecompany/demo.vapecompany.com.bd/resources/views/frontend/pages/

Upload File :
current_dir [ Writeable ] document_root [ Writeable ]

 

Current File : /home/vapecompany/demo.vapecompany.com.bd/resources/views/frontend/pages/checkout.blade.php
@extends('frontend.layouts.app')
@section('css')

    <link rel="stylesheet" type="text/css" href="{{url('public/frontend/styles/cart_styles.css')}}">
    <link rel="stylesheet" type="text/css" href="{{url('public/frontend/styles/cart_responsive.css')}}">
@endsection

@section('content')



    <!-- Cart -->
    <div class="container cart-container">
        <div class="card cart_card">
            <div class="row row-mar">

                <div class="col-md-7 cart_page">
                    <div class="title cart_title">
                        <div class="row row-mar">
                            <div class="col">
                                <h4><b>Check Out</b></h4>
                            </div>
                            <div class="col align-self-center text-right text-muted">Items {{ $cartQty }}</div>
                        </div>
                    </div>


                </div>

                <form action="{{ route('checkout.store') }}" method="post" class="col-md-5 summary">
                    <div>
                        <h5 class="h5summary"><b>Summary</b></h5>
                    </div>
                    <hr>
                    <div class="row row-mar">
                        <div class="col" style="padding-left:0;">ITEMS {{$cartQty}}</div>
                        <div class="col text-right">&euro; {{$cartTotal}}</div>
                    </div>
                    @foreach($cart as $details)
                        <div class="row row-mar border-top border-bottom">
                            <div class="row row-mar main align-items-center">
                                <div class="col-2"><img style="height:30px;width:100%;" class="img-fluid"
                                                        src="{{url('public/images/product/'.$details->options->image)}}">
                                </div>
                                <div class="col-7">
                                    <div class="row row-mar text-muted">{{$details->name}}</div>
                                    <!-- <div class="row row-mar">Cotton T-shirt</div> -->
                                </div>
                                <div class="col">&euro; {{$details->subtotal}}
                                </div>
                            </div>
                        </div>
                        <input type="hidden" name="product_id[]" id="productId" value="{{ $details->id }}">
                        <input type="hidden" name="qty[]" id="productId" value="{{ $details->qty }}">
                    @endforeach
                    <div class="row row-mar" style="border-top: 1px solid rgba(0,0,0,.1); padding: 2vh 0;">
                        <div class="col">TOTAL PRICE</div>
                        <div class="col text-right">&euro; {{$cartTotal}}</div>
                    </div>
                    @csrf
                    <button type="submit" class="chekoutbtn" style="display: block; text-align: center">CHECKOUT</button>
                </form>

            </div>
        </div>
    </div>




@endsection

@section('js')
    <script src="{{url('public/frontend/plugins/slick-1.8.0/slick.js')}}"></script>
    <script
        src="https://maps.googleapis.com/maps/api/js?v=3.exp&amp;key=AIzaSyCIwF204lFZg1y4kPSIhKaHEXMLYxxuMhA"></script>
    <script src="{{url('public/frontend/js/custom.js')}}"></script>

    <script>
        $('#cartRemove').click(function (e) {
            e.preventDefault();
            var id = $(this).data('id');
            $.ajax({
                type: "POST",
                url: "{{ route('remove.cart') }}",
                data: {
                    id: id,
                },
                dataType: "json",
                success: function (response) {
                    window.location.reload();
                    Swal.fire({
                        toast: true,
                        position: 'top-end',
                        icon: 'success',
                        title: 'Product removed successfull',
                        showConfirmButton: false,
                        timer: 3000
                    })
                },
                error: function (error) {
                    Swal.fire({
                        toast: true,
                        position: 'top-end',
                        icon: 'error',
                        title: 'Product removed failed',
                        showConfirmButton: false,
                        timer: 3000
                    })
                }
            });
        });
        // cart increment
        $('#cartIncrement').click(function (e) {
            e.preventDefault();
            var id = $(this).data('id');
            $.ajax({
                type: "POST",
                url: "{{ route('cart.increment') }}",
                data: {
                    id: id,
                },
                dataType: "json",
                success: function (response) {
                    window.location.reload();
                }
            });
        });
        // cart increment
        $('#cartDecrement').click(function (e) {
            e.preventDefault();
            var id = $(this).data('id');
            $.ajax({
                type: "POST",
                url: "{{ route('cart.decrement') }}",
                data: {
                    id: id,
                },
                dataType: "json",
                success: function (response) {
                    window.location.reload();
                }
            });
        });
    </script>
@endsection

VaKeR 2022