upated shipping fee and using voucher code

This commit is contained in:
franknstayn
2022-03-26 19:43:32 +08:00
parent b418b43469
commit 80bf7e6c67
7 changed files with 125 additions and 100 deletions

View File

@@ -315,6 +315,7 @@ class PaypalController extends Controller
$voucher = $m->selectVoucherWhereIn($voucherIds); $voucher = $m->selectVoucherWhereIn($voucherIds);
$item_id = $item->Id; $item_id = $item->Id;
$totalValue = $voucher[0]->VoucherValue; $totalValue = $voucher[0]->VoucherValue;
if ($voucher[0]->VoucherType == "Percentage") { if ($voucher[0]->VoucherType == "Percentage") {
$getPercentageValue = $totalValue / 100; $getPercentageValue = $totalValue / 100;
$getDiscountValue = ($getSubtotal[0]->Subtotal * $getPercentageValue); $getDiscountValue = ($getSubtotal[0]->Subtotal * $getPercentageValue);
@@ -323,7 +324,7 @@ class PaypalController extends Controller
); );
$m->updateVoucherValueInCart($data, $item_id); $m->updateVoucherValueInCart($data, $item_id);
} else if ($voucher[0]->VoucherType == "Percentage") { } else if ($voucher[0]->VoucherType == "Flat") {
$data = array( $data = array(
'Price' => round($totalValue * -1, 2) 'Price' => round($totalValue * -1, 2)
); );
@@ -336,6 +337,9 @@ class PaypalController extends Controller
} else if ($voucher[0]->VoucherType == "Shipping") { } else if ($voucher[0]->VoucherType == "Shipping") {
return $shippingFee = 0; return $shippingFee = 0;
} }
} else {
$getSmallItemQty += $item->Quantity;
$CAShippingfee += $item->Quantity; // for canada
} }
// var_dump($item->ShippingCostId); // var_dump($item->ShippingCostId);
// if ($item->ShippingCostId == 1) { // if ($item->ShippingCostId == 1) {
@@ -347,8 +351,7 @@ class PaypalController extends Controller
// } else if ($item->ShippingCostId == 4) { // } else if ($item->ShippingCostId == 4) {
// $getDGSItemQty += $item->Quantity; // $getDGSItemQty += $item->Quantity;
// } // }
$getSmallItemQty += $item->Quantity;
$CAShippingfee += $item->Quantity; // for canada
} }
$array_address_book = $UserModel->selectAddresBook('UserId', $userId); $array_address_book = $UserModel->selectAddresBook('UserId', $userId);

View File

@@ -95,7 +95,7 @@ class TeamStoreController extends Controller
} }
} }
$thumbnails = []; $thumbnails = [];
foreach ($product_array as $p => $pr_arr) { foreach ($product_array as $p => $pr_arr) {
@@ -650,6 +650,7 @@ class TeamStoreController extends Controller
$cartKey = $request->session()->get('cartkey'); $cartKey = $request->session()->get('cartkey');
$items = $m->myCart($cartKey); $items = $m->myCart($cartKey);
// var_dump($items);
$getSubtotal = $m->getSubtotal($cartKey); $getSubtotal = $m->getSubtotal($cartKey);
$items_group = $m->myCartGroup($cartKey); $items_group = $m->myCartGroup($cartKey);
//var_dump($items_group); //var_dump($items_group);
@@ -674,6 +675,8 @@ class TeamStoreController extends Controller
$vouchers = $m->selectVoucherWhereIn($voucherIds); $vouchers = $m->selectVoucherWhereIn($voucherIds);
} }
// var_dump($vouchers);
$totalValue = 0; $totalValue = 0;
if (!empty($vouchers)) { if (!empty($vouchers)) {
foreach ($vouchers as $voucher) { foreach ($vouchers as $voucher) {
@@ -693,6 +696,11 @@ class TeamStoreController extends Controller
if ($voucherData['type'] == "Percentage") { if ($voucherData['type'] == "Percentage") {
$getPercentageValue = $voucherData['totalValue'] / 100; $getPercentageValue = $voucherData['totalValue'] / 100;
// var_dump($getPercentageValue);
// var_dump($getSubtotal[0]->Subtotal);
// var_dump($getSubtotal[0]->Subtotal * $getPercentageValue);
$getDiscountValue = ($getSubtotal[0]->Subtotal * $getPercentageValue); $getDiscountValue = ($getSubtotal[0]->Subtotal * $getPercentageValue);
$finalSubTotal = $getSubtotal[0]->Subtotal - $getDiscountValue; $finalSubTotal = $getSubtotal[0]->Subtotal - $getDiscountValue;
} else { } else {
@@ -712,6 +720,7 @@ class TeamStoreController extends Controller
$tax = []; $tax = [];
} }
// var_dump($finalSubTotal);
return view('merchbay.cart') return view('merchbay.cart')
->with('item_group', $items_group) ->with('item_group', $items_group)
@@ -910,15 +919,17 @@ class TeamStoreController extends Controller
} }
if ($getVoucher[0]->VoucherType == "Percentage") { if ($getVoucher[0]->VoucherType == "Percentage") {
$offData = $getVoucher[0]->VoucherValue . '%'; $offData = $getVoucher[0]->VoucherValue . '%' . ' OFF';
} else { } else if ($voucherData['type'] == "Flat") {
$offData = $getVoucher[0]->VoucherValue . ' ' . $store_array[0]->StoreCurrency; $offData = $getVoucher[0]->VoucherValue . ' ' . $store_array[0]->StoreCurrency . ' OFF';
} else if ($voucherData['type'] == "Shipping") {
$offData = "";
} }
$message = '<div class="btn-group mb-2"> $message = '<div class="btn-group mb-2">
<button type="button" class="btn btn-black btn-sm dropdown-toggle" data-bs-toggle="dropdown">' . $getVoucher[0]->VoucherCode . ' ' . $offData . ' OFF</button> <button type="button" class="btn btn-black btn-sm dropdown-toggle" data-bs-toggle="dropdown">' . $getVoucher[0]->VoucherCode . ' ' . $offData . '</button>
<ul class="dropdown-menu"> <ul class="dropdown-menu">
<li><a class="dropdown-item" href="' . $removeItemURL . '">Remove</a></li> <li><a class="dropdown-item" href="' . $removeItemURL . '">Remove</a></li>
</ul> </ul>
@@ -929,7 +940,9 @@ class TeamStoreController extends Controller
'success' => true, 'success' => true,
'message' => $message, 'message' => $message,
'shippingFee' => number_format($shippingFee, 2), 'shippingFee' => number_format($shippingFee, 2),
'subtotal' => number_format($finalSubTotal + $shippingFee + $tax["tax"], 2) 'total' => number_format($finalSubTotal + $shippingFee + $tax["tax"], 2),
'subtotal' => number_format($finalSubTotal, 2),
'remaining_shippingfee' => number_format(99 - $finalSubTotal, 2)
)); ));
} else { } else {

View File

@@ -184,6 +184,7 @@ class TeamStoreModel extends Model
$i = DB::table('cart_tmp')->select(DB::raw('SUM(Quantity * Price) AS Subtotal')) $i = DB::table('cart_tmp')->select(DB::raw('SUM(Quantity * Price) AS Subtotal'))
->where('CartKey', '=', $cartKey) ->where('CartKey', '=', $cartKey)
->where('VoucherId', '=', null)
->get(); ->get();
return $i; return $i;
} }

View File

@@ -63,7 +63,7 @@
<div class="col-md-8 col-md-pull-4"> <div class="col-md-8 col-md-pull-4">
<div style="border: 1px solid #e2e2e2; padding: 10px;"> <div style="border: 1px solid #e2e2e2; padding: 10px;">
<h6><img height="30px" class="cart-store-logo" <h6><img height="30px" class="cart-store-logo"
src="{{ config('site_config.uploads') . 'teamstore/' . $store_array[0]->ImageFolder . '/' . $store_array[0]->StoreLogo }}"> src="{{ config('site_config.uploads') .'teamstore/' .$store_array[0]->ImageFolder .'/' .$store_array[0]->StoreLogo }}">
{{ $store_array[0]->StoreName }} {{ $store_array[0]->StoreName }}
</h6> </h6>
</div> </div>
@@ -110,15 +110,12 @@
<th>Quantity</th> <th>Quantity</th>
<th></th> <th></th>
</tr> </tr>
@elseif($item->FormUsed == 'quantity-form') @elseif($item->FormUsed == 'quantity-form')
<tr> <tr>
<th>Price</th> <th>Price</th>
<th>Quantity</th> <th>Quantity</th>
<th></th> <th></th>
</tr> </tr>
@elseif($item->FormUsed == 'name-number-form') @elseif($item->FormUsed == 'name-number-form')
<tr> <tr>
<th>Name</th> <th>Name</th>
@@ -127,8 +124,7 @@
<th>Quantity</th> <th>Quantity</th>
<th></th> <th></th>
</tr> </tr>
@elseif($item->FormUsed == 'name-number-size-form' || $item->FormUsed == 'roster-name-number-size-form')
@elseif($item->FormUsed == 'name-number-size-form' || $item->FormUsed == "roster-name-number-size-form")
<tr> <tr>
<th>Name</th> <th>Name</th>
<th>Number</th> <th>Number</th>
@@ -137,7 +133,6 @@
<th>Quantity</th> <th>Quantity</th>
<th></th> <th></th>
</tr> </tr>
@elseif($item->FormUsed == 'number-form') @elseif($item->FormUsed == 'number-form')
<tr> <tr>
<th>Number</th> <th>Number</th>
@@ -180,15 +175,19 @@
<th></th> <th></th>
</tr> </tr>
@else @else
@endif @endif
@foreach ($row as $sub_item) @foreach ($row as $sub_item)
@if ($sub_item->ProductId == $item->ProductId) @if ($sub_item->ProductId == $item->ProductId)
@if ($item->FormUsed == 'jersey-and-shorts-form') @if ($item->FormUsed == 'jersey-and-shorts-form')
<tr> <tr>
<td> @if ($sub_item->Name != '') {{ $sub_item->Name }} @else -- @endif </td> <td>
@if ($sub_item->Name != '')
{{ $sub_item->Name }}
@else
--
@endif
</td>
<td>{{ $sub_item->Number }}</td> <td>{{ $sub_item->Number }}</td>
<td>{{ $sub_item->JerseySize }}</td> <td>{{ $sub_item->JerseySize }}</td>
<td>{{ $sub_item->ShortsSize }}</td> <td>{{ $sub_item->ShortsSize }}</td>
@@ -229,7 +228,7 @@
href="{{ url('removeitem') }}/{{ $sub_item->Id }}"><i href="{{ url('removeitem') }}/{{ $sub_item->Id }}"><i
class="fa fa-times"></i></a></td> class="fa fa-times"></i></a></td>
</tr> </tr>
@elseif($item->FormUsed == 'name-number-size-form' || $item->FormUsed == "roster-name-number-size-form") @elseif($item->FormUsed == 'name-number-size-form' || $item->FormUsed == 'roster-name-number-size-form')
<tr> <tr>
<td>{{ $sub_item->Name }}</td> <td>{{ $sub_item->Name }}</td>
<td>{{ $sub_item->Number }}</td> <td>{{ $sub_item->Number }}</td>
@@ -298,9 +297,7 @@
class="fa fa-times"></i></a></td> class="fa fa-times"></i></a></td>
</tr> </tr>
@else @else
@endif @endif
@endif @endif
@endforeach @endforeach
</table> </table>
@@ -325,7 +322,6 @@
<h3>Order Summary</h3> <h3>Order Summary</h3>
</div> </div>
@if (!Auth::guest()) @if (!Auth::guest())
<div style="border: 1px solid #e2e2e2; padding: 10px; border-bottom: none;"> <div style="border: 1px solid #e2e2e2; padding: 10px; border-bottom: none;">
<p><strong>Ship to:</strong></p> <p><strong>Ship to:</strong></p>
@@ -336,7 +332,7 @@
<div>{{ $address_book[0]->Fullname }}</div> <div>{{ $address_book[0]->Fullname }}</div>
<div>{{ $address_book[0]->ContactNumber }}</div> <div>{{ $address_book[0]->ContactNumber }}</div>
<div> <div>
{{ $address_book[0]->Address . ' ' . $address_book[0]->Address2 . ', ' . $address_book[0]->State . ', ' . $address_book[0]->City . ', ' . $address_book[0]->Country . ', ' . $address_book[0]->CountryCode . ' ' . $address_book[0]->ZipCode }} {{ $address_book[0]->Address .' ' .$address_book[0]->Address2 .', ' .$address_book[0]->State .', ' .$address_book[0]->City .', ' .$address_book[0]->Country .', ' .$address_book[0]->CountryCode .' ' .$address_book[0]->ZipCode }}
<a href="{{ url('user/address-book/edit/' . $address_book[0]->Id) }}">[ Edit <a href="{{ url('user/address-book/edit/' . $address_book[0]->Id) }}">[ Edit
]</a> ]</a>
</div> </div>
@@ -346,17 +342,19 @@
@endif @endif
<div style="border: 1px solid #e2e2e2; padding: 10px; border-bottom: none;"> <div style="border: 1px solid #e2e2e2; padding: 10px; border-bottom: none;">
<h5>Subtotal: <h5>Subtotal:
<small>{{ number_format($tax['order_grandtotal'], 2) . ' ' . $store_array[0]->StoreCurrency }}</small> <small><span id="my_subtotal">{{ number_format($getSubtotal, 2) }}</span>
{{ $store_array[0]->StoreCurrency }}</small>
</h5> </h5>
<h5>Shipping Fee: <h5>Shipping Fee:
<small> <span id="shippingFee">{{ number_format($shipping_fee, 2) }}</span> {{ $store_array[0]->StoreCurrency }}</small> <small> <span id="shippingFee">{{ number_format($shipping_fee, 2) }}</span>
{{ $store_array[0]->StoreCurrency }}</small>
</h5> </h5>
<h5>Tax: <h5>Tax:
<small>{{ number_format($tax['tax'], 2) . ' ' . $store_array[0]->StoreCurrency }}</small> <small>{{ number_format($tax['tax'], 2) . ' ' . $store_array[0]->StoreCurrency }}</small>
</h5> </h5>
<hr> <hr>
<h3>Total: <span <h3>Total: <span
id="my_subtotal">{{ number_format($getSubtotal + $shipping_fee + $tax['tax'], 2) }}</span> id="my_total">{{ number_format($getSubtotal + $shipping_fee + $tax['tax'], 2) }}</span>
<small>{{ $store_array[0]->StoreCurrency }}</small> <small>{{ $store_array[0]->StoreCurrency }}</small>
</h3> </h3>
@@ -364,7 +362,9 @@
@if ($getSubtotal >= 1 && $getSubtotal <= 98) @if ($getSubtotal >= 1 && $getSubtotal <= 98)
<div class="border rounded-2 p-2 mt-2"> <div class="border rounded-2 p-2 mt-2">
If you order $99 worth of product you get free shipping (pre tax). You are If you order $99 worth of product you get free shipping (pre tax). You are
<strong>{{ number_format(99 - $getSubtotal, 2) }} <strong>
<span
id="remaining_shippingfee">{{ number_format(99 - $getSubtotal, 2) }}</span>
{{ $store_array[0]->StoreCurrency }}</strong> away. {{ $store_array[0]->StoreCurrency }}</strong> away.
</div> </div>
@endif @endif
@@ -387,10 +387,14 @@
<button type="button" class="btn btn-black btn-sm dropdown-toggle" <button type="button" class="btn btn-black btn-sm dropdown-toggle"
data-bs-toggle="dropdown">{{ $item->VoucherCode . ' ' . $item->VoucherValue . '%' }} data-bs-toggle="dropdown">{{ $item->VoucherCode . ' ' . $item->VoucherValue . '%' }}
OFF</button> OFF</button>
@else @elseif ($item->VoucherType == 'Flat')
<button type="button" class="btn btn-black btn-sm dropdown-toggle" <button type="button" class="btn btn-black btn-sm dropdown-toggle"
data-bs-toggle="dropdown">{{ $item->VoucherCode . ' ' . $item->VoucherValue . ' ' . $store_array[0]->StoreCurrency }} data-bs-toggle="dropdown">{{ $item->VoucherCode . ' ' . $item->VoucherValue . ' ' . $store_array[0]->StoreCurrency }}
OFF</button> OFF</button>
@else
{{-- Shipping Voucher --}}
<button type="button" class="btn btn-black btn-sm dropdown-toggle"
data-bs-toggle="dropdown">{{ $item->VoucherCode }}</button>
@endif @endif
<ul class="dropdown-menu"> <ul class="dropdown-menu">
<li><a class="dropdown-item" <li><a class="dropdown-item"
@@ -417,11 +421,12 @@
</div> </div>
<div style="border: 1px solid #e2e2e2; padding: 10px;"> <div style="border: 1px solid #e2e2e2; padding: 10px;">
<a @if ($getSubtotal <= 0) disabled @endif href="{{ url('getCheckout') }}" class="btn w-100" <a @if ($getSubtotal <= 0) disabled @endif href="{{ url('getCheckout') }}"
class="btn w-100"
style="background-color: #ffc300; border-color: #e2ad00; text-align: -webkit-center;">Checkout</a><br> style="background-color: #ffc300; border-color: #e2ad00; text-align: -webkit-center;">Checkout</a><br>
<!-- <div class="my-2"> <!-- <div class="my-2">
<button class="btn btn-lg btn-info w-100">Checkout with Voucher</button> <button class="btn btn-lg btn-info w-100">Checkout with Voucher</button>
</div> --> </div> -->
<div class="border rounded-2 p-2 mt-2"> <div class="border rounded-2 p-2 mt-2">
Payments made on Merchbay will show up as Crewsportswear on your order confirmations and Payments made on Merchbay will show up as Crewsportswear on your order confirmations and
receipt. receipt.

View File

@@ -478,8 +478,11 @@
$("#voucher_list").append(response.message); $("#voucher_list").append(response.message);
form.validate().resetForm(); form.validate().resetForm();
form[0].reset(); form[0].reset();
$('#my_total').text(response.total);
$('#my_subtotal').text(response.subtotal); $('#my_subtotal').text(response.subtotal);
$('#shippingFee').text(response.shippingFee); $('#shippingFee').text(response.shippingFee);
$('#remaining_shippingfee').text(response.remaining_shippingfee);
} else { } else {
$("#error_voucher").html(response.message).fadeIn().delay(5000).fadeOut('slow', $("#error_voucher").html(response.message).fadeIn().delay(5000).fadeOut('slow',

View File

@@ -131,8 +131,8 @@
@media screen and (min-width: 1440px) { @media screen and (min-width: 1440px) {
/* .carousel-inner{ /* .carousel-inner{
margin-left: -60px; margin-left: -60px;
} */ } */
} }
@media screen and (min-width: 1200px) and (max-width: 1439px) { @media screen and (min-width: 1200px) and (max-width: 1439px) {
@@ -194,8 +194,8 @@
/* .btn-roster-action { */ /* .btn-roster-action { */
/* width: 20px; /* width: 20px;
height: 20px; height: 20px;
border-radius: 10px; */ border-radius: 10px; */
/* } */ /* } */
.btn-group-sm>.btn { .btn-group-sm>.btn {
@@ -270,7 +270,7 @@
<div class="row"> <div class="row">
<div class="col-lg-12 text-center"> <div class="col-lg-12 text-center">
<div class="store-banner border-top"> <div class="store-banner border-top">
<img src="{{ config('site_config.uploads') . 'teamstore/' . $store_array[0]->ImageFolder . '/' . $store_array[0]->StoreBanner }}" <img src="{{ config('site_config.uploads') .'teamstore/' .$store_array[0]->ImageFolder .'/' .$store_array[0]->StoreBanner }}"
id="storeBanner" class="shadow-sm img-fluid w-100" alt="..." /> id="storeBanner" class="shadow-sm img-fluid w-100" alt="..." />
</div> </div>
</div> </div>
@@ -361,7 +361,9 @@
</div> </div>
<form id="frm-order-list"> <form id="frm-order-list">
<input type="hidden" value="{{ md5($product_array[0]->Id) }}" name="p_id" id="p_id" /> <input type="hidden" value="{{ md5($product_array[0]->Id) }}" name="p_id" id="p_id" />
@include('teamstore-sublayouts.forms.'.$product_array[0]->ProductForm) @include(
'teamstore-sublayouts.forms.' . $product_array[0]->ProductForm
)
@if ($product_array[0]->ProductPrice > 0) @if ($product_array[0]->ProductPrice > 0)
{{-- @if ($available_qty !== null) --}} {{-- @if ($available_qty !== null) --}}
@@ -372,7 +374,6 @@
</div> </div>
@endif @endif
{{-- @endif --}} {{-- @endif --}}
@endif @endif
</form> </form>
<hr> <hr>

View File

@@ -1,9 +1,8 @@
<div class="row py-5"> <div class="row py-5">
@foreach ($stores_array as $store) @foreach ($stores_array as $store)
<div class="col-lg-2 col-md-3 col-sm-4"> <div class="col-lg-2 col-md-3 col-sm-4">
<div class="p-3 store"> <div class="p-3 store">
{{-- {{-- @if ($store->Password != null)
@if($store->Password != null )
<a class="thumbnail password-protected" href="#" data-store-id="{{ $store->Id }}" data-store-url="{{ $store->StoreUrl }}"> <a class="thumbnail password-protected" href="#" data-store-id="{{ $store->Id }}" data-store-url="{{ $store->StoreUrl }}">
<img class="store-logo" src="{{ config('site_config.uploads') . 'teamstore/'. $store->ImageFolder . '/' . $store->StoreLogo }}"> <img class="store-logo" src="{{ config('site_config.uploads') . 'teamstore/'. $store->ImageFolder . '/' . $store->StoreLogo }}">
</a> </a>
@@ -14,34 +13,30 @@
</a> </a>
<h4 style="border-top: 1px solid #dddddd; padding: 10px; font-size: 16px; font-weight: bold; text-transform: uppercase;" class="text-center">{{ $store->StoreName }}</h4> <h4 style="border-top: 1px solid #dddddd; padding: 10px; font-size: 16px; font-weight: bold; text-transform: uppercase;" class="text-center">{{ $store->StoreName }}</h4>
@endif --}} @endif --}}
@if($store->Password != null ) @if ($store->Password != null)
<a href="#"> <a href="#">
<div class="store-logo password-protected" data-store-id="{{ $store->Id }}" data-store-url="{{ $store->StoreUrl }}"> <div class="store-logo password-protected" data-store-id="{{ $store->Id }}"
<img data-store-url="{{ $store->StoreUrl }}">
src="{{ config('site_config.uploads') . 'teamstore/' . $store->ImageFolder . '/' . $store->StoreLogo }}" <img src="{{ config('site_config.uploads') . 'teamstore/' . $store->ImageFolder . '/' . $store->StoreLogo }}"
class="d-block" class="d-block" alt="{{ $store->StoreName }}" />
alt="{{ $store->StoreName }}" <div class="store-locked">
/> <i class="fa fa-lock"></i>
<div class="store-locked"> </div>
<i class="fa fa-lock"></i> </div>
</div> <div class="store-name">{{ $store->StoreName }} <i class="fa fa-lock"
</div> title="This store is password protected."></i></div>
<div class="store-name">{{ $store->StoreName }} <i class="fa fa-lock" title="This store is password protected."></i></div> </a>
</a> @else
@else <a href="{{ url('store') . '/' . $store->StoreUrl }}">
<a href="{{ url('store') . '/' . $store->StoreUrl }}"> <div class="store-logo">
<div class="store-logo"> <img src="{{ config('site_config.uploads') . 'teamstore/' . $store->ImageFolder . '/' . $store->StoreLogo }}"
<img class="d-block" alt="{{ $store->StoreName }}" />
src="{{ config('site_config.uploads') . 'teamstore/' . $store->ImageFolder . '/' . $store->StoreLogo }}" </div>
class="d-block" <div class="store-name">{{ $store->StoreName }}</div>
alt="{{ $store->StoreName }}" </a>
/> @endif
</div> </div>
<div class="store-name">{{ $store->StoreName }}</div> </div>
</a>
@endif
</div>
</div>
@endforeach @endforeach
{{-- <div class="col-lg-12"> {{-- <div class="col-lg-12">
@@ -100,35 +95,39 @@
</div> --}} </div> --}}
{{-- <div id="team-store-login" class="modal fade" role="dialog"> --}} {{-- <div id="team-store-login" class="modal fade" role="dialog"> --}}
<div class="modal fade" id="team-store-login" tabindex="-1" aria-labelledby="storeLoginLabel" aria-hidden="true" data-bs-backdrop="static" data-bs-keyboard="false"> <div class="modal fade" id="team-store-login" tabindex="-1" aria-labelledby="storeLoginLabel" aria-hidden="true"
data-bs-backdrop="static" data-bs-keyboard="false">
<div class="modal-dialog"> <div class="modal-dialog">
<div class="modal-content"> <div class="modal-content">
<form class="form-horizontal" role="form" method="POST" action="{{ url('store/checkpassword') }}"> <form class="form-horizontal" role="form" method="POST" action="{{ url('store/checkpassword') }}">
<div class="modal-header"> <div class="modal-header">
<h5 class="modal-title" id="storeLoginLabel">Store Login</h5> <h5 class="modal-title" id="storeLoginLabel">Store Login</h5>
<button type="button" class="btn-close" data-bs-dismiss="modal" aria-label="Close"></button> <button type="button" class="btn-close" data-bs-dismiss="modal" aria-label="Close"></button>
</div>
<div class="modal-body">
@if (\Session::has('errors'))
<div class="alert alert-danger alert-dismissible fade show" role="alert">
<strong>Whoops!</strong> {!! \Session::get('errors') !!}.
<button type="button" class="btn-close" data-bs-dismiss="alert" aria-label="Close"></button>
</div>
@endif
<input type="hidden" name="_token" value="{{ csrf_token() }}">
<input type="hidden" class="form-control" id="_teamstore_id" name="store_id">
<label class="col-md-4 control-label">Store Password</label>
<div class="input-group mb-3">
<input type="password" class="form-control pwd" name="password" placeholder="Store Password" aria-label="Store Password" aria-describedby="button-addon2" required>
<button class="btn btn-outline-secondary reveal-password" type="button" id="button-addon2"><i class="fa fa-eye"></i></button>
</div> </div>
</div> <div class="modal-body">
<div class="modal-footer"> @if (\Session::has('errors'))
<button type="button" class="btn" data-bs-dismiss="modal">Cancel</button> <div class="alert alert-danger alert-dismissible fade show" role="alert">
<button type="submit" class="btn btn-black">Submit</button> <strong>Whoops!</strong> {!! \Session::get('errors') !!}.
</div> <button type="button" class="btn-close" data-bs-dismiss="alert"
</form> aria-label="Close"></button>
</div> </div>
@endif
<input type="hidden" name="_token" value="{{ csrf_token() }}">
<input type="hidden" class="form-control" id="_teamstore_id" name="store_id">
<label class="col-md-4 control-label">Store Password</label>
<div class="input-group mb-3">
<input type="password" class="form-control pwd" name="password" placeholder="Store Password"
aria-label="Store Password" aria-describedby="button-addon2" required>
<button class="btn btn-outline-secondary reveal-password" type="button" id="button-addon2"><i
class="fa fa-eye"></i></button>
</div>
</div>
<div class="modal-footer">
<button type="button" class="btn" data-bs-dismiss="modal">Cancel</button>
<button type="submit" class="btn btn-black">Submit</button>
</div>
</form>
</div>
</div> </div>
</div> </div>