Compare commits
No commits in common. "eec3c041219bfc6bb344e1870ab296877394d47e" and "4d7a47b158355765dd996356fe384ed22503119e" have entirely different histories.
eec3c04121
...
4d7a47b158
|
@ -1,6 +1,10 @@
|
|||
<style>
|
||||
.nav-link:hover{
|
||||
border-left: 5px solid #87CEFA;
|
||||
.sidenav-item.active {
|
||||
background-color: #f0f0f0; /* Change background color */
|
||||
}
|
||||
|
||||
.sidenav-item.active .nav-text {
|
||||
color: #333; /* Change text color */
|
||||
}
|
||||
</style>
|
||||
|
||||
|
@ -17,17 +21,18 @@
|
|||
<!-- begin sidebar scrollbar -->
|
||||
<div class="ec-navigation" data-simplebar>
|
||||
<!-- sidebar menu -->
|
||||
<ul class="nav sidebar-inner">
|
||||
<ul class="nav sidebar-inner" id="sidebar-menu">
|
||||
<!-- Dashboard -->
|
||||
<li class="nav-link">
|
||||
<li class="active">
|
||||
<a class="sidenav-item-link" href="index.php">
|
||||
<i class="mdi mdi-view-dashboard-outline"></i>
|
||||
<span class="nav-text">Dashboard</span>
|
||||
</a>
|
||||
<hr>
|
||||
</li>
|
||||
|
||||
<!-- Vendors -->
|
||||
<li class="nav-link">
|
||||
<li>
|
||||
<a class="sidenav-item-link" href="vendor-card.php">
|
||||
<i class="mdi mdi-account-group-outline"></i>
|
||||
<span class="nav-text">Vendors</span>
|
||||
|
@ -55,7 +60,7 @@
|
|||
</li>
|
||||
|
||||
<!-- Users -->
|
||||
<li class="nav-link">
|
||||
<li >
|
||||
<a class="sidenav-item-link" href="user-card.php">
|
||||
<i class="mdi mdi-account-group"></i>
|
||||
<span class="nav-text">Users</span>
|
||||
|
@ -138,7 +143,7 @@
|
|||
</li> -->
|
||||
|
||||
<!-- Orders -->
|
||||
<li class="nav-link">
|
||||
<li >
|
||||
<a class="sidenav-item-link" href="order-history.php">
|
||||
<i class="mdi mdi-cart"></i>
|
||||
<span class="nav-text">Orders</span>
|
||||
|
@ -252,6 +257,4 @@
|
|||
</ul>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
</div>
|
|
@ -350,9 +350,7 @@ function updateWishItemCount() {
|
|||
<div class="col-lg-3 col-md-6 ec-catalog-since pad-15">
|
||||
|
||||
<h6>Seller since</h6>
|
||||
<!-- <p><?php echo $vendor["date_registered"] ?></p> -->
|
||||
<p><?php echo date('F j, Y', strtotime($vendor['date_registered'])); ?></p>
|
||||
|
||||
<p><?php echo $vendor["date_registered"] ?></p>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
|
@ -528,7 +526,7 @@ xhrVendors1.onreadystatechange = function() {
|
|||
let imageUrls = product.images.split(',');
|
||||
let firstImageUrl = imageUrls[0].trim();
|
||||
let img = document.createElement("img");
|
||||
img.setAttribute("style", "border: 1px solid #eeeeee; height: 330px; object-fit: cover;");
|
||||
img.setAttribute("style", "width: 290px; height: 200px; object-fit: cover;");
|
||||
img.setAttribute("class", "main-image");
|
||||
img.setAttribute("src", firstImageUrl);
|
||||
img.setAttribute("alt", "Product");
|
||||
|
@ -539,7 +537,7 @@ xhrVendors1.onreadystatechange = function() {
|
|||
} else {
|
||||
let img = document.createElement("img");
|
||||
img.className = "main-image";
|
||||
img.setAttribute("style", "border: 1px solid #eeeeee; height: 330px; object-fit: cover;");
|
||||
img.setAttribute("style", "width: 290px; height: 200px; object-fit: cover;");
|
||||
img.setAttribute("loading", "lazy");
|
||||
img.setAttribute("class", "main-image");
|
||||
img.setAttribute("src", "https://api.obanana.com/images/storage/web_images/1709002636671-viber_image_2024-02-22_15-54-42-498.png");
|
||||
|
@ -552,21 +550,14 @@ xhrVendors1.onreadystatechange = function() {
|
|||
card.classList.add("col-lg-4", "col-md-6", "col-sm-6", "col-xs-6", "mb-6", "pro-gl-content", "width-100");
|
||||
card.innerHTML = `
|
||||
<div class="ec-product-inner">
|
||||
<div class="ec-pro-image-outer" style="max-width: 290px; height: 350px;">
|
||||
<div class="ec-pro-image-outer" style="width: 290px; height: 200px;">
|
||||
<div class="ec-pro-image">
|
||||
<a href="product-left-sidebar.php?id=${product._id}">
|
||||
${imageContainer.innerHTML} <!-- Include the dynamically loaded image here -->
|
||||
</a>
|
||||
<div class="ec-pro-actions" style="bottom: -36px;">
|
||||
${
|
||||
(product["sale_price"] && product["sale_price"] > 0) ?
|
||||
`<button title="Add To Cart" onclick="popupAddToCart('${encodeURIComponent(JSON.stringify(product))}','${encodeURIComponent(JSON.stringify(vendorOfProduct))}', '${token}', '${email}', '${password}', '${encodeURIComponent(JSON.stringify(customer_data))}');" class="add-to-cart"><i class="fi-rr-shopping-basket"></i> Add To Cart</button>
|
||||
<a class="ec-btn-group wishlist" title="Wishlist" onclick="popupWishlist('${encodeURIComponent(JSON.stringify(product))}', '${encodeURIComponent(JSON.stringify(customer_data))}');"><i class="fi-rr-heart"></i></a>` :
|
||||
(product["regular_price"] && product["regular_price"] != "") ?
|
||||
`<button title="Add To Cart" onclick="popupAddToCart('${encodeURIComponent(JSON.stringify(product))}','${encodeURIComponent(JSON.stringify(vendorOfProduct))}', '${token}', '${email}', '${password}', '${encodeURIComponent(JSON.stringify(customer_data))}');" class="add-to-cart"><i class="fi-rr-shopping-basket"></i> Add To Cart</button>
|
||||
<a class="ec-btn-group wishlist" title="Wishlist" onclick="popupWishlist('${encodeURIComponent(JSON.stringify(product))}', '${encodeURIComponent(JSON.stringify(customer_data))}');"><i class="fi-rr-heart"></i></a>` :
|
||||
`<a class="ec-btn-group wishlist" title="Wishlist" onclick="popupWishlist('${encodeURIComponent(JSON.stringify(product))}', '${encodeURIComponent(JSON.stringify(customer_data))}');"><i class="fi-rr-heart"></i></a>`
|
||||
}
|
||||
<button title="Add To Cart" onclick="popupAddToCart('${encodeURIComponent(JSON.stringify(product))}','${encodeURIComponent(JSON.stringify(vendorOfProduct))}', '${token}', '${email}', '${password}', '${encodeURIComponent(JSON.stringify(customer_data))}');" class="add-to-cart"><i class="fi-rr-shopping-basket"></i> Add To Cart</button>
|
||||
<a class="ec-btn-group wishlist" title="Wishlist" onclick="popupWishlist('${encodeURIComponent(JSON.stringify(product))}', '${encodeURIComponent(JSON.stringify(customer_data))}');"><i class="fi-rr-heart"></i></a>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
@ -1175,7 +1166,7 @@ maxPriceInput.addEventListener('input', function() {
|
|||
<!-- Modal end -->
|
||||
|
||||
<!-- Footer navigation panel for responsive display -->
|
||||
<!-- <div class="ec-nav-toolbar">
|
||||
<div class="ec-nav-toolbar">
|
||||
<div class="container">
|
||||
<div class="ec-nav-panel">
|
||||
<div class="ec-nav-panel-icons">
|
||||
|
@ -1196,7 +1187,7 @@ maxPriceInput.addEventListener('input', function() {
|
|||
|
||||
</div>
|
||||
</div>
|
||||
</div> -->
|
||||
</div>
|
||||
<!-- Footer navigation panel for responsive display end -->
|
||||
|
||||
<!-- Recent Purchase Popup -->
|
||||
|
|
31
footer.php
31
footer.php
|
@ -1,7 +1,3 @@
|
|||
<style>
|
||||
|
||||
</style>
|
||||
|
||||
<!-- Footer Start -->
|
||||
<footer class="ec-footer section-space-mt">
|
||||
<div class="footer-container">
|
||||
|
@ -169,30 +165,5 @@
|
|||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<!-- Footer navigation panel for responsive display -->
|
||||
<div class="ec-nav-toolbar">
|
||||
<div class="container">
|
||||
<div class="ec-nav-panel">
|
||||
<!-- <div class="ec-nav-panel-icons">
|
||||
<a href="#ec-mobile-menu" class="navbar-toggler-btn ec-header-btn ec-side-toggle"><i class="fi-rr-menu-burger"></i></a>
|
||||
</div> -->
|
||||
<div class="ec-nav-panel-icons">
|
||||
<a href="cart.php" class="ec-header-btn ec-header-wishlist">
|
||||
<div class="header-icon"><i class="fi-rr-shopping-bag"></i></div>
|
||||
</a>
|
||||
</div>
|
||||
<div class="ec-nav-panel-icons">
|
||||
<a href="index.php" class="ec-header-btn"><i class="fi-rr-home"></i></a>
|
||||
</div>
|
||||
<div class="ec-nav-panel-icons">
|
||||
<a href="wishlist.php" class="ec-header-btn"><i class="fi-rr-heart"></i></a>
|
||||
</div>
|
||||
<div class="ec-nav-panel-icons">
|
||||
<a href="#" class="ec-header-btn"><i class="fi-rr-user"></i></a>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<!-- Footer navigation panel for responsive display -->
|
||||
</footer>
|
||||
<!-- Footer Area End -->
|
||||
<!-- Footer Area End -->
|
48
header.php
48
header.php
|
@ -139,20 +139,6 @@ if ($_SESSION["userId"] <> "") {
|
|||
font-size: 16px;
|
||||
line-height: 1;
|
||||
}
|
||||
|
||||
@media (hover: hover), (hover: none) {
|
||||
.fi-rr-heart:hover,
|
||||
.fi-rr-heart:active,
|
||||
.fi-rr-user:hover,
|
||||
.fi-rr-user:active,
|
||||
.fi-rr-shopping-bag:hover,
|
||||
.fi-rr-shopping-bag:active,
|
||||
.fi-rr-home:hover,
|
||||
.fi-rr-home:active {
|
||||
cursor: pointer !important;
|
||||
color: #005eff !important;
|
||||
}
|
||||
}
|
||||
</style>
|
||||
|
||||
|
||||
|
@ -302,13 +288,13 @@ if ($_SESSION["userId"] <> "") {
|
|||
<!-- Header Cart Start -->
|
||||
<a href="wishlist.php" class="ec-header-btn ec-header-wishlist">
|
||||
<div class="header-icon"><i class="fi-rr-heart"></i></div>
|
||||
<span id="wishItemCount" class="ec-header-count">0</span>
|
||||
<span class="ec-header-count">0</span>
|
||||
</a>
|
||||
<!-- Header Cart End -->
|
||||
<!-- Header Cart Start -->
|
||||
<a href="cart.php" class="ec-header-btn ec-header-wishlist">
|
||||
<div class="header-icon"><i class="fi-rr-shopping-bag"></i></div>
|
||||
<span id="cartItemCount" class="ec-header-count">0</span>
|
||||
<span class="ec-header-count cart-count-lable">0</span>
|
||||
</a>
|
||||
<!-- Header Cart End -->
|
||||
<a href="javascript:void(0)" class="ec-header-btn ec-sidebar-toggle">
|
||||
|
@ -1144,41 +1130,23 @@ if ($_SESSION["userId"] <> "") {
|
|||
</ul>
|
||||
</li> -->
|
||||
<li><a href="offer.php">Hot Offers</a></li>
|
||||
<?php
|
||||
// Check if the current page is the index page
|
||||
if(basename($_SERVER['PHP_SELF']) === 'index.php') {
|
||||
//include the scroll menu
|
||||
?>
|
||||
<li class="dropdown scroll-to"><a href="javascript:void(0)"><i class="fi fi-rr-sort-amount-down-alt"></i></a>
|
||||
<ul class="sub-menu">
|
||||
<li class="menu_title">Scroll To Section</li>
|
||||
<li><a href="javascript:void(0)" data-scroll="collection" class="nav-scroll">Top Collection</a></li>
|
||||
<li><a href="javascript:void(0)" data-scroll="categories" class="nav-scroll">Categories</a></li>
|
||||
<li><a href="javascript:void(0)" data-scroll="vendors" class="nav-scroll">Top Vendors</a></li>
|
||||
<li><a href="javascript:void(0)" data-scroll="services" class="nav-scroll">Services</a></li>
|
||||
<li><a href="javascript:void(0)" data-scroll="arrivals" class="nav-scroll">New Arrivals</a></li>
|
||||
</ul>
|
||||
</li>
|
||||
<?php
|
||||
}
|
||||
?>
|
||||
<!-- <li class="dropdown scroll-to"><a href="javascript:void(0)"><i class="fi fi-rr-sort-amount-down-alt"></i></a>
|
||||
<li class="dropdown scroll-to"><a href="javascript:void(0)"><i class="fi fi-rr-sort-amount-down-alt"></i></a>
|
||||
<ul class="sub-menu">
|
||||
<li class="menu_title">Scroll To Section</li>
|
||||
<li><a href="javascript:void(0)" data-scroll="collection" class="nav-scroll">Top
|
||||
Collection</a></li>
|
||||
<li><a href="javascript:void(0)" data-scroll="categories" class="nav-scroll">Categories</a></li>
|
||||
<li><a href="javascript:void(0)" data-scroll="offers" class="nav-scroll">Offers</a></li>
|
||||
<!-- <li><a href="javascript:void(0)" data-scroll="offers" class="nav-scroll">Offers</a></li> -->
|
||||
<li><a href="javascript:void(0)" data-scroll="vendors" class="nav-scroll">Top
|
||||
Vendors</a></li>
|
||||
<li><a href="javascript:void(0)" data-scroll="services" class="nav-scroll">Services</a></li>
|
||||
<li><a href="javascript:void(0)" data-scroll="arrivals" class="nav-scroll">New
|
||||
Arrivals</a></li>
|
||||
<li><a href="javascript:void(0)" data-scroll="reviews" class="nav-scroll">Client
|
||||
Review</a></li>
|
||||
<li><a href="javascript:void(0)" data-scroll="insta" class="nav-scroll">Instagram Feed</a></li>
|
||||
<!-- <li><a href="javascript:void(0)" data-scroll="reviews" class="nav-scroll">Client
|
||||
Review</a></li> -->
|
||||
<!-- <li><a href="javascript:void(0)" data-scroll="insta" class="nav-scroll">Instagram Feed</a></li> -->
|
||||
</ul>
|
||||
</li> -->
|
||||
</li>
|
||||
</ul>
|
||||
</div>
|
||||
</div>
|
||||
|
|
34
index.php
34
index.php
|
@ -224,9 +224,9 @@ if ($_SESSION["userId"] <> "") {
|
|||
$vendorOfProduct = getVendorbyId($forAll[$pid]['vendor_api_id']);
|
||||
?>
|
||||
<div class="col-lg-3 col-md-6 col-sm-6 col-xs-6 mb-6 ec-product-content" data-animation="fadeIn">
|
||||
<div class="ec-product-inner">
|
||||
<div class="ec-product-inner" style="width: 260px;">
|
||||
<!-- raymart added style feb 26 2024 -->
|
||||
<div class="ec-pro-image-outer" style="max-width: 290px; height: 350px;">
|
||||
<div class="ec-pro-image-outer">
|
||||
<!-- <div class="ec-pro-image-outer"> -->
|
||||
<div class="ec-pro-image">
|
||||
<a href="product-left-sidebar.php?id=<?php echo $forAll[$pid]["_id"]; ?>">
|
||||
|
@ -237,7 +237,7 @@ if ($_SESSION["userId"] <> "") {
|
|||
if (!empty($image_urls)) {
|
||||
$first_image_url = trim($image_urls[0]);
|
||||
?>
|
||||
<img loading="lazy" class="main-image" src="<?php echo $first_image_url; ?>" alt="edit" style="border: 1px solid #eeeeee; height: 330px; object-fit: cover;" />
|
||||
<img loading="lazy" class="main-image" src="<?php echo $first_image_url; ?>" alt="edit" style="border: 1px solid #eeeeee; height: 280px;" />
|
||||
<?php
|
||||
}
|
||||
} else {
|
||||
|
@ -344,9 +344,9 @@ if ($_SESSION["userId"] <> "") {
|
|||
$vendorOfProduct = getVendorbyId($electronics[$pid]['vendor_api_id']);
|
||||
?>
|
||||
<div class="col-lg-3 col-md-6 col-sm-6 col-xs-6 mb-6 ec-product-content" data-animation="fadeIn">
|
||||
<div class="ec-product-inner">
|
||||
<div class="ec-product-inner" style="width: 260px;">
|
||||
<!-- raymart added style feb 26 2024 -->
|
||||
<div class="ec-pro-image-outer" style="max-width: 290px; height: 350px;">
|
||||
<div class="ec-pro-image-outer">
|
||||
<!-- <div class="ec-pro-image-outer"> -->
|
||||
<div class="ec-pro-image">
|
||||
<a href="product-left-sidebar.php?id=<?php echo $electronics[$pid]["_id"]; ?>">
|
||||
|
@ -357,7 +357,7 @@ if ($_SESSION["userId"] <> "") {
|
|||
if (!empty($image_urls)) {
|
||||
$first_image_url = trim($image_urls[0]);
|
||||
?>
|
||||
<img loading="lazy" class="main-image" src="<?php echo $first_image_url; ?>" alt="edit" style="border: 1px solid #eeeeee; height: 330px; object-fit: cover;" />
|
||||
<img loading="lazy" class="main-image" src="<?php echo $first_image_url; ?>" alt="edit" style="border: 1px solid #eeeeee; height: 280px;" />
|
||||
<?php
|
||||
}
|
||||
} else {
|
||||
|
@ -466,9 +466,9 @@ if ($_SESSION["userId"] <> "") {
|
|||
$vendorOfProduct = getVendorbyId($smartHome[$pid]['vendor_api_id']);
|
||||
?>
|
||||
<div class="col-lg-3 col-md-6 col-sm-6 col-xs-6 mb-6 ec-product-content" data-animation="fadeIn">
|
||||
<div class="ec-product-inner">
|
||||
<div class="ec-product-inner" style="width: 260px;">
|
||||
<!-- raymart added style feb 26 2024 -->
|
||||
<div class="ec-pro-image-outer" style="max-width: 290px; height: 350px;">
|
||||
<div class="ec-pro-image-outer">
|
||||
<!-- <div class="ec-pro-image-outer"> -->
|
||||
<div class="ec-pro-image">
|
||||
<a href="product-left-sidebar.php?id=<?php echo $smartHome[$pid]["_id"]; ?>">
|
||||
|
@ -479,7 +479,7 @@ if ($_SESSION["userId"] <> "") {
|
|||
if (!empty($image_urls)) {
|
||||
$first_image_url = trim($image_urls[0]);
|
||||
?>
|
||||
<img loading="lazy" class="main-image" src="<?php echo $first_image_url; ?>" alt="edit" style="border: 1px solid #eeeeee; height: 330px; object-fit: cover;" />
|
||||
<img loading="lazy" class="main-image" src="<?php echo $first_image_url; ?>" alt="edit" style="border: 1px solid #eeeeee; height: 280px;" />
|
||||
<?php
|
||||
}
|
||||
} else {
|
||||
|
@ -586,9 +586,9 @@ if ($_SESSION["userId"] <> "") {
|
|||
$vendorOfProduct = getVendorbyId($forVehicle[$pid]['vendor_api_id']);
|
||||
?>
|
||||
<div class="col-lg-3 col-md-6 col-sm-6 col-xs-6 mb-6 ec-product-content" data-animation="fadeIn">
|
||||
<div class="ec-product-inner">
|
||||
<div class="ec-product-inner" style="width: 260px;">
|
||||
<!-- raymart added style feb 26 2024-->
|
||||
<div class="ec-pro-image-outer" style="max-width: 290px; height: 350px;">
|
||||
<div class="ec-pro-image-outer">
|
||||
<!-- <div class="ec-pro-image-outer"> -->
|
||||
<div class="ec-pro-image">
|
||||
<a href="product-left-sidebar.php?id=<?php echo $forVehicle[$pid]["_id"]; ?>">
|
||||
|
@ -599,7 +599,7 @@ if ($_SESSION["userId"] <> "") {
|
|||
if (!empty($image_urls)) {
|
||||
$first_image_url = trim($image_urls[0]);
|
||||
?>
|
||||
<img loading="lazy" class="main-image" src="<?php echo $first_image_url; ?>" alt="edit" style="border: 1px solid #eeeeee; height: 330px; object-fit: cover;" />
|
||||
<img loading="lazy" class="main-image" src="<?php echo $first_image_url; ?>" alt="edit" style="border: 1px solid #eeeeee; height: 280px;" />
|
||||
<?php
|
||||
}
|
||||
} else {
|
||||
|
@ -1229,9 +1229,9 @@ if ($_SESSION["userId"] <> "") {
|
|||
$vendorOfProduct = getVendorbyId($newArrival[$pid]['vendor_api_id']);
|
||||
?>
|
||||
<div class="col-lg-3 col-md-6 col-sm-6 col-xs-6 mb-6 ec-product-content" data-animation="flipInY">
|
||||
<div class="ec-product-inner">
|
||||
<div class="ec-product-inner" style="width: 260px;">
|
||||
<!-- raymart added style feb 26 2024 -->
|
||||
<div class="ec-pro-image-outer" style="max-width: 290px; height: 350px;">
|
||||
<div class="ec-pro-image-outer">
|
||||
<!-- <div class="ec-pro-image-outer"> -->
|
||||
<div class="ec-pro-image">
|
||||
<a href="product-left-sidebar.php?id=<?php echo $newArrival[$pid]["_id"]; ?>">
|
||||
|
@ -1242,7 +1242,7 @@ if ($_SESSION["userId"] <> "") {
|
|||
if (!empty($image_urls)) {
|
||||
$first_image_url = trim($image_urls[0]);
|
||||
?>
|
||||
<img loading="lazy" class="main-image" src="<?php echo $first_image_url; ?>" alt="edit" style="border: 1px solid #eeeeee; height: 330px; object-fit: cover;" />
|
||||
<img loading="lazy" class="main-image" src="<?php echo $first_image_url; ?>" alt="edit" style="border: 1px solid #eeeeee; height: 280px;" />
|
||||
<?php
|
||||
}
|
||||
} else {
|
||||
|
@ -1671,7 +1671,7 @@ if ($_SESSION["userId"] <> "") {
|
|||
</div>
|
||||
<!-- Newsletter Modal end -->
|
||||
<!-- Footer navigation panel for responsive display -->
|
||||
<!-- <div class="ec-nav-toolbar">
|
||||
<div class="ec-nav-toolbar">
|
||||
<div class="container">
|
||||
<div class="ec-nav-panel">
|
||||
<div class="ec-nav-panel-icons">
|
||||
|
@ -1692,7 +1692,7 @@ if ($_SESSION["userId"] <> "") {
|
|||
|
||||
</div>
|
||||
</div>
|
||||
</div> -->
|
||||
</div>
|
||||
<!-- Footer navigation panel for responsive display end -->
|
||||
|
||||
<!-- Recent Purchase Popup -->
|
||||
|
|
|
@ -321,7 +321,7 @@ function loadProducts(page,isFilter) {
|
|||
let product = prod;
|
||||
// let vendor = prod.vendor;
|
||||
|
||||
let vendorOfProduct = prod;
|
||||
let vendorOfProduct = prod.vendor;
|
||||
// let card = document.createElement("div");
|
||||
let token ="<?php echo $_SESSION['token'] ?>";
|
||||
let email ="<?php echo $_SESSION['email'] ?>";
|
||||
|
@ -334,7 +334,7 @@ function loadProducts(page,isFilter) {
|
|||
let imageUrls = product.images.split(',');
|
||||
let firstImageUrl = imageUrls[0].trim();
|
||||
let img = document.createElement("img");
|
||||
img.setAttribute("style", "border: 1px solid #eeeeee; height: 330px; object-fit: cover;");
|
||||
img.setAttribute("style", "width: 290px; height: 200px; object-fit: cover;");
|
||||
img.setAttribute("class", "main-image");
|
||||
img.setAttribute("loading", "lazy");
|
||||
|
||||
|
@ -345,7 +345,7 @@ function loadProducts(page,isFilter) {
|
|||
} else {
|
||||
let img = document.createElement("img");
|
||||
img.className = "main-image";
|
||||
img.setAttribute("style", "border: 1px solid #eeeeee; height: 330px; object-fit: cover;");
|
||||
img.setAttribute("style", "width: 290px; height: 200px; object-fit: cover;");
|
||||
img.setAttribute("loading", "lazy");
|
||||
img.setAttribute("class", "main-image");
|
||||
img.setAttribute("src", "https://api.obanana.com/images/storage/web_images/1709002636671-viber_image_2024-02-22_15-54-42-498.png");
|
||||
|
@ -358,21 +358,14 @@ function loadProducts(page,isFilter) {
|
|||
card.classList.add("col-lg-3", "col-md-6", "col-sm-6", "col-xs-6", "mb-6", "pro-gl-content", "width-100");
|
||||
card.innerHTML = `
|
||||
<div class="ec-product-inner">
|
||||
<div class="ec-pro-image-outer" style="max-width: 290px; height: 350px;">
|
||||
<div class="ec-pro-image-outer" style="width: 290px; height: 200px;">
|
||||
<div class="ec-pro-image">
|
||||
<a href="product-left-sidebar.php?id=${product._id}">
|
||||
${imageContainer.innerHTML} <!-- Include the dynamically loaded image here -->
|
||||
</a>
|
||||
<div class="ec-pro-actions" style="bottom: -36px;">
|
||||
${
|
||||
(product["sale_price"] && product["sale_price"] > 0) ?
|
||||
`<button title="Add To Cart" onclick="popupAddToCart('${encodeURIComponent(JSON.stringify(product))}','${encodeURIComponent(JSON.stringify(vendorOfProduct))}', '${token}', '${email}', '${password}', '${encodeURIComponent(JSON.stringify(customer_data))}');" class="add-to-cart"><i class="fi-rr-shopping-basket"></i> Add To Cart</button>
|
||||
<a class="ec-btn-group wishlist" title="Wishlist" onclick="popupWishlist('${encodeURIComponent(JSON.stringify(product))}', '${encodeURIComponent(JSON.stringify(customer_data))}');"><i class="fi-rr-heart"></i></a>` :
|
||||
(product["regular_price"] && product["regular_price"] != "") ?
|
||||
`<button title="Add To Cart" onclick="popupAddToCart('${encodeURIComponent(JSON.stringify(product))}','${encodeURIComponent(JSON.stringify(vendorOfProduct))}', '${token}', '${email}', '${password}', '${encodeURIComponent(JSON.stringify(customer_data))}');" class="add-to-cart"><i class="fi-rr-shopping-basket"></i> Add To Cart</button>
|
||||
<a class="ec-btn-group wishlist" title="Wishlist" onclick="popupWishlist('${encodeURIComponent(JSON.stringify(product))}', '${encodeURIComponent(JSON.stringify(customer_data))}');"><i class="fi-rr-heart"></i></a>` :
|
||||
`<a class="ec-btn-group wishlist" title="Wishlist" onclick="popupWishlist('${encodeURIComponent(JSON.stringify(product))}', '${encodeURIComponent(JSON.stringify(customer_data))}');"><i class="fi-rr-heart"></i></a>`
|
||||
}
|
||||
<button title="Add To Cart" onclick="popupAddToCart('${encodeURIComponent(JSON.stringify(product))}','${encodeURIComponent(JSON.stringify(vendorOfProduct))}', '${token}', '${email}', '${password}', '${encodeURIComponent(JSON.stringify(customer_data))}');" class="add-to-cart"><i class="fi-rr-shopping-basket"></i> Add To Cart</button>
|
||||
<a class="ec-btn-group wishlist" title="Wishlist" onclick="popupWishlist('${encodeURIComponent(JSON.stringify(product))}', '${encodeURIComponent(JSON.stringify(customer_data))}');"><i class="fi-rr-heart"></i></a>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
@ -932,7 +925,7 @@ maxPriceInput.addEventListener('input', function() {
|
|||
<!-- Modal end -->
|
||||
|
||||
<!-- Footer navigation panel for responsive display -->
|
||||
<!-- <div class="ec-nav-toolbar">
|
||||
<div class="ec-nav-toolbar">
|
||||
<div class="container">
|
||||
<div class="ec-nav-panel">
|
||||
<div class="ec-nav-panel-icons">
|
||||
|
@ -957,7 +950,7 @@ maxPriceInput.addEventListener('input', function() {
|
|||
|
||||
</div>
|
||||
</div>
|
||||
</div> -->
|
||||
</div>
|
||||
<!-- Footer navigation panel for responsive display end -->
|
||||
|
||||
<!-- Recent Purchase Popup -->
|
||||
|
|
|
@ -2027,7 +2027,7 @@ if (isset($_GET['id'])) {
|
|||
<!-- Modal end -->
|
||||
|
||||
<!-- Footer navigation panel for responsive display -->
|
||||
<!-- <div class="ec-nav-toolbar">
|
||||
<div class="ec-nav-toolbar">
|
||||
<div class="container">
|
||||
<div class="ec-nav-panel">
|
||||
<div class="ec-nav-panel-icons">
|
||||
|
@ -2048,7 +2048,7 @@ if (isset($_GET['id'])) {
|
|||
|
||||
</div>
|
||||
</div>
|
||||
</div> -->
|
||||
</div>
|
||||
<!-- Footer navigation panel for responsive display end -->
|
||||
|
||||
<!-- Recent Purchase Popup -->
|
||||
|
|
|
@ -129,7 +129,8 @@ $customerData = json_decode($customers, true);
|
|||
</span>
|
||||
<span class="ec-register-wrap ec-register-half">
|
||||
<label>Phone Number*</label>
|
||||
<input type="text" name="phonenumber" value="+63 <?php echo $_SESSION["phone"] ?>" oninput="preventEraseInPrefix(this)" required />
|
||||
<input type="text" name="phonenumber" value="<?php echo $_SESSION["phone"] ?>" placeholder="Enter your phone number"
|
||||
required />
|
||||
</span>
|
||||
<span class="ec-register-wrap ec-register-btn">
|
||||
<?php
|
||||
|
@ -152,25 +153,6 @@ $customerData = json_decode($customers, true);
|
|||
</div>
|
||||
</div>
|
||||
</section>
|
||||
|
||||
<script>
|
||||
|
||||
function preventEraseInPrefix(input) { /* edit details */
|
||||
|
||||
var numericValue = input.value.replace(/\D/g, '');
|
||||
if (numericValue.startsWith('63')) {
|
||||
input.value = "+63 " + numericValue.substring(2);
|
||||
} else {
|
||||
input.value = "+63 " + numericValue;
|
||||
}
|
||||
|
||||
if (input.value.length > 14) {
|
||||
input.value = input.value.slice(0, 14);
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
</script>
|
||||
<!-- End Register -->
|
||||
|
||||
<!-- Footer Start -->
|
||||
|
|
|
@ -144,7 +144,7 @@ $vendorData = json_decode($vendors, true);
|
|||
</span>
|
||||
<span class="ec-register-wrap ec-register-half">
|
||||
<label>Phone Number*</label>
|
||||
<input type="text" name="phonenumber" value="+63 <?php echo $vendorData['phone'] ?>" oninput="preventEraseInPrefix(this)" required />
|
||||
<input type="text" name="phonenumber" value="<?php echo $vendorData['phone'] ?>" placeholder="Enter your phone number" required />
|
||||
</span>
|
||||
|
||||
<!-- <span class="ec-register-wrap">
|
||||
|
@ -224,25 +224,6 @@ $vendorData = json_decode($vendors, true);
|
|||
</div>
|
||||
</div>
|
||||
</section>
|
||||
|
||||
<script>
|
||||
|
||||
function preventEraseInPrefix(input) { /* edit details */
|
||||
|
||||
var numericValue = input.value.replace(/\D/g, '');
|
||||
if (numericValue.startsWith('63')) {
|
||||
input.value = "+63 " + numericValue.substring(2);
|
||||
} else {
|
||||
input.value = "+63 " + numericValue;
|
||||
}
|
||||
|
||||
if (input.value.length > 14) {
|
||||
input.value = input.value.slice(0, 14);
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
</script>
|
||||
<!-- End Register -->
|
||||
|
||||
<!-- Footer Start -->
|
||||
|
|
|
@ -1108,22 +1108,20 @@ maxPriceInput.addEventListener('input', function() {
|
|||
|
||||
|
||||
<!-- Footer navigation panel for responsive display -->
|
||||
<!-- <div class="ec-nav-toolbar">
|
||||
<div class="ec-nav-toolbar">
|
||||
<div class="container">
|
||||
<div class="ec-nav-panel">
|
||||
<div class="ec-nav-panel-icons">
|
||||
<a href="javascript:void(0)" class="ec-header-btn ec-sidebar-toggle"><i class="fi fi-rr-apps"></i></a>
|
||||
</div>
|
||||
<div class="ec-nav-panel-icons">
|
||||
<a href="cart.php" class="ec-header-btn ec-header-wishlist">
|
||||
<div class="header-icon"><i class="fi-rr-shopping-bag"></i></div>
|
||||
<span class="ec-header-count cart-count-lable">0</span>
|
||||
</a> </div>
|
||||
<a href="cart.php" class="toggle-cart ec-header-btn ec-side-toggle"><i class="fi-rr-shopping-bag"></i><!-- <span class="ec-cart-noti ec-header-count cart-count-lable"></span> --></a>
|
||||
</div>
|
||||
<div class="ec-nav-panel-icons">
|
||||
<a href="index.php" class="ec-header-btn"><i class="fi-rr-home"></i></a>
|
||||
</div>
|
||||
<div class="ec-nav-panel-icons">
|
||||
<a href="wishlist.php" class="ec-header-btn"><i class="fi-rr-heart"></i></a>
|
||||
<a href="wishlist.php" class="ec-header-btn"><i class="fi-rr-heart"></i><!-- <span class="ec-cart-noti"></span> --></a>
|
||||
</div>
|
||||
<div class="ec-nav-panel-icons">
|
||||
<a href="login.php" class="ec-header-btn"><i class="fi-rr-user"></i></a>
|
||||
|
@ -1131,7 +1129,7 @@ maxPriceInput.addEventListener('input', function() {
|
|||
|
||||
</div>
|
||||
</div>
|
||||
</div> -->
|
||||
</div>
|
||||
<!-- Footer navigation panel for responsive display end -->
|
||||
|
||||
<!-- Recent Purchase Popup -->
|
||||
|
|
|
@ -74,7 +74,7 @@ $products = productList();
|
|||
text-decoration: none;
|
||||
padding: 5px 10px;
|
||||
border: 1px solid #ccc;
|
||||
margin: 0 5px;
|
||||
/* margin: 0 5px; */
|
||||
border-radius: 4px;
|
||||
}
|
||||
|
||||
|
@ -262,8 +262,7 @@ $products = productList();
|
|||
<a href="catalog-single-vendor.php?id=<?php echo $vendor['_id'] ?>">
|
||||
<h6>Seller since</h6>
|
||||
</a>
|
||||
<!-- <p><?php echo $vendor['date_registered']; ?></p> -->
|
||||
<p><?php echo date('F j, Y', strtotime($vendor['date_registered'])); ?></p>
|
||||
<p><?php echo $vendor['date_registered']; ?></p>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
@ -418,7 +417,7 @@ $products = productList();
|
|||
<!-- Modal end -->
|
||||
|
||||
<!-- Footer navigation panel for responsive display -->
|
||||
<!-- <div class="ec-nav-toolbar">
|
||||
<div class="ec-nav-toolbar">
|
||||
<div class="container">
|
||||
<div class="ec-nav-panel">
|
||||
<div class="ec-nav-panel-icons">
|
||||
|
@ -439,7 +438,7 @@ $products = productList();
|
|||
|
||||
</div>
|
||||
</div>
|
||||
</div> -->
|
||||
</div>
|
||||
<!-- Footer navigation panel for responsive display end -->
|
||||
|
||||
<!-- raymart remove popup feb 20 2024 -->
|
||||
|
|
|
@ -75,11 +75,8 @@ $vendorPayoutData = json_decode($response, true);
|
|||
<link rel="stylesheet" href="assets/css/style.css" />
|
||||
<link rel="stylesheet" href="assets/css/style2.css" />
|
||||
<link rel="stylesheet" href="assets/css/responsive.css" />
|
||||
|
||||
<link href="https://cdn.datatables.net/v/bs5/dt-2.0.3/r-3.0.0/sp-2.3.0/datatables.min.css" rel="stylesheet">
|
||||
|
||||
<link rel="stylesheet" href="https://cdn.metroui.org.ua/current/metro.css">
|
||||
<script src="https://cdn.metroui.org.ua/current/metro.js"></script>
|
||||
|
||||
|
||||
|
||||
<!-- Background css -->
|
||||
|
@ -87,6 +84,7 @@ $vendorPayoutData = json_decode($response, true);
|
|||
<link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/select2@latest/dist/css/select2.min.css" crossorigin="anonymous" referrerpolicy="no-referrer" />
|
||||
<script src="https://code.jquery.com/jquery-3.6.4.min.js"></script>
|
||||
<script src="https://cdn.jsdelivr.net/npm/select2@latest/dist/js/select2.min.js" crossorigin="anonymous" referrerpolicy="no-referrer"></script>
|
||||
|
||||
<script>
|
||||
function renewToken() {
|
||||
var xhr = new XMLHttpRequest();
|
||||
|
@ -161,221 +159,183 @@ $vendorPayoutData = json_decode($response, true);
|
|||
<!-- Sidebar Category Block -->
|
||||
<div class="ec-sidebar-block">
|
||||
<div class="ec-vendor-block">
|
||||
<!-- 03-12-2024 Stacy added placeholder for vendor banner -->
|
||||
<?php
|
||||
if (!empty($vendorData['vendor_banner'])) { ?>
|
||||
<div class="ec-vendor-block-bg" style="background-image: url(<?php echo $vendorData['vendor_banner'] ?>) !important;"></div>
|
||||
<?php } else { ?>
|
||||
<div class="ec-vendor-block-bg" style="background-color: orange; background-image: url(<?php echo $vendorData['vendor_banner'] ?>) !important;"></div>
|
||||
<?php } ?>
|
||||
<!-- <div class="ec-vendor-block-bg" style="background-image: url(<?php #echo $vendorData['vendor_banner'] ?>) !important;"></div> -->
|
||||
<div class="ec-vendor-block-detail">
|
||||
<!-- <img loading="lazy" class="v-img" src=<?php #echo $vendorData['vendor_image'] ?> alt="vendor image"> -->
|
||||
<!-- 03-12-2024 Stacy added placeholder for vendor profile -->
|
||||
<?php
|
||||
if (!empty($vendorData['vendor_image'])) { ?>
|
||||
<img loading="lazy" class="v-img" src=<?php echo $vendorData['vendor_image'] ?> alt="vendor image">
|
||||
<?php } else { ?>
|
||||
<img loading="lazy" class="v-img" src="https://yourteachingmentor.com/wp-content/uploads/2020/12/istockphoto-1223671392-612x612-1.jpg" alt="vendor image">
|
||||
<?php } ?>
|
||||
<h5 class="name"><?php echo $vendorData['user_login'] ?></h5>
|
||||
</div>
|
||||
<!-- <div class="ec-vendor-block-items">
|
||||
|
||||
<ul>
|
||||
<li><a href="vendor-dashboard.php">Dashboard</a></li>
|
||||
<li><a onclick="addProduct();" href="">Upload Product</a></li>
|
||||
<li><a href="vendor-settings.php">Settings (Edit)</a></li>
|
||||
</ul>
|
||||
</div> -->
|
||||
<?php include "vendor-user-tabs.php" ?>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="ec-shop-rightside col-lg-9 col-md-12">
|
||||
<div class="row">
|
||||
<div class="col-md-12">
|
||||
<div class="ec-vendor-dashboard-card">
|
||||
<div class="ec-vendor-card-header">
|
||||
<h5><strong>Upcoming Payout</strong></h5>
|
||||
</div>
|
||||
<div class="ec-vendor-card-body">
|
||||
<div class="row">
|
||||
<h4 style="color: #444;">
|
||||
<div class="d-flex align-items-center">
|
||||
<?php
|
||||
$response = getOrderbyVendorId($vendorId);
|
||||
$upcomingPayout = json_decode($response, true);
|
||||
$payoutSum = 0;
|
||||
|
||||
foreach ($upcomingPayout as $x => $val) {
|
||||
$paymentStatus = strtolower($val['payment']['status']);
|
||||
$orderStatus = strtolower($val['status']);
|
||||
$payoutStatus = empty($val['payout_status']);
|
||||
if(( $paymentStatus == "paid") && ( $orderStatus == "completed") && ($payoutStatus == true)){
|
||||
$orderAmount = $val['total_amount'];
|
||||
$payoutSum += $orderAmount;
|
||||
}
|
||||
}
|
||||
|
||||
$finalPayoutSum = number_format($payoutSum, 2, '.', ',');
|
||||
?>
|
||||
<strong>
|
||||
₱ <?php echo $finalPayoutSum ?>
|
||||
</strong>
|
||||
</div>
|
||||
</h4>
|
||||
<!-- <div class="text-sm mt-3">
|
||||
Payout Generation: Tue, Mar 19, 2024
|
||||
</div>
|
||||
<div class="text-sm">
|
||||
Receive Payout on or before: Wed, Mar 20, 2024
|
||||
</div> -->
|
||||
<div class="text-sm">
|
||||
<?php
|
||||
$vendorResponse = getVendorbyId($vendorId);
|
||||
$vendorInformation = json_decode($vendorResponse, true);
|
||||
$bankAccountNumber = $vendorInformation['bank_acount_details'][0]['bank_account_number'];
|
||||
$bankDetails = $vendorInformation['bank_acount_details'];
|
||||
foreach ($bankDetails as $details) {
|
||||
if ($details['bank_payout'] === true) {
|
||||
$bankName = $details['bank_name'];
|
||||
$bankAccountNumber = $details['bank_account_number'];
|
||||
}
|
||||
}
|
||||
$bankNumEnding = substr($bankAccountNumber, -3);
|
||||
?>
|
||||
Receipient: <?php echo $bankName; ?> Account ending in <?php echo $bankNumEnding?>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<!-- ADDITIONAL PANELS FOR PAYOUTS FOR FUTURE USE, DO NOT REMOVE -->
|
||||
<!-- <div class="col-md-12">
|
||||
<div class="ec-vendor-dashboard-card">
|
||||
<div class="ec-vendor-card-header">
|
||||
<h5><strong>Payout Generation Schedule</strong></h5>
|
||||
</div>
|
||||
<div class="ec-vendor-card-body">
|
||||
<div class="row">
|
||||
<h4 style="color: #444;">
|
||||
<div class="d-flex align-items-center">
|
||||
<i class="fi-rs-calendar mt-1 mr-3 "></i>
|
||||
<strong>
|
||||
Weekly
|
||||
</strong>
|
||||
</div>
|
||||
</h4>
|
||||
<div class="mt-3">
|
||||
<h6>
|
||||
<strong class="text-primary ">Every Tuesday</strong>
|
||||
</h6>
|
||||
</div>
|
||||
<div class="text-sm">
|
||||
Payouts that will fall on holiday will be processed the next banking day
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-12">
|
||||
<div class="ec-vendor-dashboard-card">
|
||||
<div class="ec-vendor-card-header">
|
||||
<h5><strong>Next Payout</strong></h5>
|
||||
</div>
|
||||
<div class="ec-vendor-card-body">
|
||||
<div class="row">
|
||||
<h4 style="color: #444;">
|
||||
<div class="d-flex align-items-center">
|
||||
<strong>
|
||||
₱ 0.00
|
||||
</strong>
|
||||
</div>
|
||||
</h4>
|
||||
<div class="text-sm mt-3">
|
||||
Payout Generation: Tue, Mar 25, 2024
|
||||
</div>
|
||||
<div class="text-sm">
|
||||
Receive Payout on or before: Wed, Mar 26, 2024
|
||||
</div>
|
||||
<div class="text-sm">
|
||||
Receipient: Philippine National Bank (PNB) Account ending in 123
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div> -->
|
||||
</div>
|
||||
<div class="ec-vendor-dashboard-card space-bottom-30">
|
||||
<div class="ec-vendor-card-header">
|
||||
<h5>Payout History</h5>
|
||||
</div>
|
||||
<div class="ec-vendor-dashboard-card ec-vendor-setting-card">
|
||||
<div class="ec-vendor-card-body">
|
||||
<div class="ec-vendor-card-table">
|
||||
<table class="table ec-table"
|
||||
id="order-table" style="overflow-x: auto;"
|
||||
data-role="table"
|
||||
data-pagination="true"
|
||||
data-searching="true"
|
||||
data-filtering="true"
|
||||
data-sorting="true"
|
||||
data-show-rows-steps="5,10,20,-1"
|
||||
data-horizontal-scroll="true"
|
||||
data-rownum="true"
|
||||
data-table-info-title="Display from $1 to $2 of $3 payment(s)"
|
||||
>
|
||||
<thead>
|
||||
<tr>
|
||||
<th data-sortable="true" scope="col">Amount</th>
|
||||
<th data-sortable="true" scope="col">Bank</th>
|
||||
<th data-sortable="true" scope="col">Account Number</th>
|
||||
<th data-sortable="true" scope="col">Payout Generation</th>
|
||||
<th data-sortable="true" scope="col">Status</th>
|
||||
<th data-sortable="true" scope="col">Action</th>
|
||||
<div class="row">
|
||||
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody class='table-group-divider'>
|
||||
<?php
|
||||
foreach ($vendorPayoutData as $x => $val) {
|
||||
$vendorIdCheck = $val['vendor_details'][0]['vendor_id'];
|
||||
$status = ucfirst(strtolower($val['status']));
|
||||
$payoutDate = date("F d, Y", strtotime($val['createdAt']));
|
||||
$payoutId = $val['_id'];
|
||||
if ((empty($vendorIdCheck) == false) && ($vendorIdCheck == $vendorId) && ($status == "Deposited")) { ?>
|
||||
<tr>
|
||||
<td> <?php echo "₱ " . $val['net_amount'] ?> </td>
|
||||
<?php if (empty($val['bank_information'][0]['bank_name']) == false) {
|
||||
<div class="col-md-12 mb-5">
|
||||
<div class="panel panel-primary">
|
||||
<div class="panel-heading">
|
||||
<h5 class="panel-title"><strong>Upcoming Payout</strong></h5>
|
||||
</div>
|
||||
<div class="panel-body ">
|
||||
<div class="row">
|
||||
<h4 style="color: #444;">
|
||||
<div class="d-flex align-items-center">
|
||||
<?php
|
||||
$response = getOrderbyVendorId($vendorId);
|
||||
$upcomingPayout = json_decode($response, true);
|
||||
$payoutSum = 0;
|
||||
|
||||
foreach ($upcomingPayout as $x => $val) {
|
||||
$paymentStatus = strtolower($val['payment']['status']);
|
||||
$orderStatus = strtolower($val['status']);
|
||||
$payoutStatus = empty($val['payout_status']);
|
||||
if(( $paymentStatus == "paid") && ( $orderStatus == "completed") && ($payoutStatus == true)){
|
||||
$orderAmount = $val['total_amount'];
|
||||
$payoutSum += $orderAmount;
|
||||
}
|
||||
}
|
||||
|
||||
$finalPayoutSum = number_format($payoutSum, 2, '.', ',');
|
||||
?>
|
||||
<strong>
|
||||
₱ <?php echo $finalPayoutSum ?>
|
||||
</strong>
|
||||
</div>
|
||||
</h4>
|
||||
<!-- <div class="text-sm mt-3">
|
||||
Payout Generation: Tue, Mar 19, 2024
|
||||
</div>
|
||||
<div class="text-sm">
|
||||
Receive Payout on or before: Wed, Mar 20, 2024
|
||||
</div> -->
|
||||
<div class="text-sm">
|
||||
<?php
|
||||
$vendorResponse = getVendorbyId($vendorId);
|
||||
$vendorInformation = json_decode($vendorResponse, true);
|
||||
$bankAccountNumber = $vendorInformation['bank_acount_details'][0]['bank_account_number'];
|
||||
$bankDetails = $vendorInformation['bank_acount_details'];
|
||||
foreach ($bankDetails as $details) {
|
||||
if ($details['bank_payout'] === true) {
|
||||
$bankName = $details['bank_name'];
|
||||
$bankAccountNumber = $details['bank_account_number'];
|
||||
}
|
||||
}
|
||||
$bankNumEnding = substr($bankAccountNumber, -3);
|
||||
?>
|
||||
<td> <?php echo $val['bank_information'][0]['bank_name'] ?> </td>
|
||||
<?php } else { ?>
|
||||
<td> N/A </td>
|
||||
<?php }
|
||||
if (empty($val['bank_information'][0]['bank_account_number']) == false) {
|
||||
$accNum = $val['bank_information'][0]['bank_account_number'];
|
||||
// Replace characters with asterisks for all characters except the last three segments
|
||||
$maskedAccNum = substr_replace($accNum, str_repeat('*', strlen($accNum) - 3), 0, -3); ?>
|
||||
<td> <?php echo $maskedAccNum ?> </td>
|
||||
<?php } else { ?>
|
||||
<td> N/A </td>
|
||||
<?php } ?>
|
||||
<td> <?php echo $payoutDate ?> </td>
|
||||
<td> <?php echo $status ?> </td>
|
||||
<td>
|
||||
<button type="button" class="btn btn-primary btn-sm showSinglePayoutBtn" data-order-id="<?php echo $payoutId; ?>" data-bs-toggle="modal" data-bs-target="#payoutsModal">View</button>
|
||||
</td>
|
||||
</tr>
|
||||
<?php
|
||||
}
|
||||
} ?>
|
||||
</tbody>
|
||||
</table>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
Receipient: <?php echo $bankName; ?> Account ending in <?php echo $bankNumEnding?>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<!-- ADDITIONAL PANELS FOR PAYOUTS FOR FUTURE USE, DO NOT REMOVE -->
|
||||
<!-- <div class="col-md-4 mb-5">
|
||||
<div class="panel panel-primary">
|
||||
<div class="panel-heading">
|
||||
<h5 class="panel-title"><strong>Payout Generation Schedule</strong></h5>
|
||||
</div>
|
||||
<div class="panel-body ">
|
||||
<div class="row">
|
||||
<h4 style="color: #444;">
|
||||
<div class="d-flex align-items-center">
|
||||
<i class="fi-rs-calendar mt-1 mr-3 "></i>
|
||||
<strong>
|
||||
Weekly
|
||||
</strong>
|
||||
</div>
|
||||
</h4>
|
||||
<div class="mt-3">
|
||||
<h6>
|
||||
<strong class="text-primary ">Every Tuesday</strong>
|
||||
</h6>
|
||||
</div>
|
||||
<div class="text-sm">
|
||||
Payouts that will fall on holiday will be processed the next banking day
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-4 mb-5">
|
||||
<div class="panel panel-primary">
|
||||
<div class="panel-heading">
|
||||
<h5 class="panel-title"><strong>Next Payout</strong></h5>
|
||||
</div>
|
||||
<div class="panel-body ">
|
||||
<div class="row">
|
||||
<h4 style="color: #444;">
|
||||
<div class="d-flex align-items-center">
|
||||
<strong>
|
||||
₱ 0.00
|
||||
</strong>
|
||||
</div>
|
||||
</h4>
|
||||
<- <div class="text-sm mt-3">
|
||||
Payout Generation: Tue, Mar 25, 2024
|
||||
</div>
|
||||
<div class="text-sm">
|
||||
Receive Payout on or before: Wed, Mar 26, 2024
|
||||
</div> -
|
||||
<div class="text-sm">
|
||||
Receipient: Philippine National Bank (PNB) Account ending in <php echo $bankNumEnding?>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div> -->
|
||||
<div class="col-md-12 mt-3">
|
||||
<h5 class='m-0'><strong>Payout History</strong></h5>
|
||||
<div class="table-responsive px-4">
|
||||
<table id='payoutsTableContent' class="table ec-table">
|
||||
<thead>
|
||||
<tr>
|
||||
<th scope="col">Amount</th>
|
||||
<th scope="col">Bank</th>
|
||||
<th scope="col">Account Number</th>
|
||||
<th scope="col">Payout Generation</th>
|
||||
<th scope="col">Status</th>
|
||||
<th scope="col">Action</th>
|
||||
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody class='table-group-divider'>
|
||||
<?php
|
||||
foreach ($vendorPayoutData as $x => $val) {
|
||||
$vendorIdCheck = $val['vendor_details'][0]['vendor_id'];
|
||||
$status = ucfirst(strtolower($val['status']));
|
||||
$payoutDate = date("F d, Y", strtotime($val['createdAt']));
|
||||
$payoutId = $val['_id'];
|
||||
if ((empty($vendorIdCheck) == false) && ($vendorIdCheck == $vendorId) && ($status == "Deposited")) { ?>
|
||||
<tr>
|
||||
<td> <?php echo "₱ " . $val['net_amount'] ?> </td>
|
||||
<?php if (empty($val['bank_information'][0]['bank_name']) == false) {
|
||||
?>
|
||||
<td> <?php echo $val['bank_information'][0]['bank_name'] ?> </td>
|
||||
<?php } else { ?>
|
||||
<td> N/A </td>
|
||||
<?php }
|
||||
if (empty($val['bank_information'][0]['bank_account_number']) == false) {
|
||||
$accNum = $val['bank_information'][0]['bank_account_number'];
|
||||
// Replace characters with asterisks for all characters except the last three segments
|
||||
$maskedAccNum = substr_replace($accNum, str_repeat('*', strlen($accNum) - 3), 0, -3); ?>
|
||||
<td> <?php echo $maskedAccNum ?> </td>
|
||||
<?php } else { ?>
|
||||
<td> N/A </td>
|
||||
<?php } ?>
|
||||
<td> <?php echo $payoutDate ?> </td>
|
||||
<td> <?php echo $status ?> </td>
|
||||
<td>
|
||||
<button type="button" class="btn btn-primary btn-sm showSinglePayoutBtn" data-order-id="<?php echo $payoutId; ?>" data-bs-toggle="modal" data-bs-target="#payoutsModal">View</button>
|
||||
</td>
|
||||
</tr>
|
||||
<?php
|
||||
}
|
||||
} ?>
|
||||
</tbody>
|
||||
</table>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
@ -635,7 +595,6 @@ $vendorPayoutData = json_decode($response, true);
|
|||
<script src="assets/js/plugins/jquery.sticky-sidebar.js"></script>
|
||||
<script src="assets/js/plugins/nouislider.js"></script>
|
||||
<script src="https://cdn.datatables.net/v/bs5/dt-2.0.3/r-3.0.0/sp-2.3.0/datatables.min.js"></script>
|
||||
<!-- <script src="https://cdn.metroui.org.ua/current/metro.js"></script> -->
|
||||
|
||||
<!-- <script>
|
||||
const tooltipTriggerList = document.querySelectorAll('[data-bs-toggle="tooltip"]')
|
||||
|
@ -714,9 +673,8 @@ $vendorPayoutData = json_decode($response, true);
|
|||
<div>
|
||||
<h6><strong>Payout Information</strong></h6>
|
||||
</div>
|
||||
<div>
|
||||
<button disabled style="border: 2px solid #198754; color: #198754 !important; border-radius: 5px;">${payoutStatus}</button>
|
||||
</div>
|
||||
|
||||
<button class="fw-bold border border-success border-2 btn-outline-success btn-sm" disabled>${payoutStatus}</button>
|
||||
</div>
|
||||
<div class="d-flex justify-content-between p-2">
|
||||
<div class="fw-bold">Gross Amount</div>
|
||||
|
@ -735,7 +693,7 @@ $vendorPayoutData = json_decode($response, true);
|
|||
</div>
|
||||
</div>
|
||||
<div class="col-md-5 mb-4">
|
||||
<div class="d-flex flex-column" >
|
||||
<div class="d-flex flex-column" style="border-bottom: 1px solid #000;">
|
||||
<div class="d-flex justify-content-between p-2">
|
||||
<h6><strong>Bank Information</strong></h6>
|
||||
</div>
|
||||
|
@ -786,6 +744,11 @@ $vendorPayoutData = json_decode($response, true);
|
|||
});
|
||||
});
|
||||
</script>
|
||||
<script>
|
||||
$(document).ready( function () {
|
||||
$('#payoutsTableContent').DataTable();
|
||||
} );
|
||||
</script>
|
||||
|
||||
</body>
|
||||
|
||||
|
|
|
@ -419,7 +419,7 @@ if ($_SESSION["isCustomer"] == true) {
|
|||
</div>
|
||||
<div class="form-group">
|
||||
<label for="addressContact" class="text-dark font-weight-medium pt-3 mb-2">Contact Number</label>
|
||||
<input type="text" class="form-control" id="addressContact" value="+63 " oninput="preventErasePrefix(this)">
|
||||
<input type="number" class="form-control" id="addressContact">
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<label for="addressBuilding" class="text-dark font-weight-medium pt-3 mb-2"> Building,Number </label>
|
||||
|
@ -449,7 +449,7 @@ if ($_SESSION["isCustomer"] == true) {
|
|||
</div>
|
||||
<div class="form-group">
|
||||
<label for="addressCountry" class="text-dark font-weight-medium pt-3 mb-2">Country</label>
|
||||
<input type="text" class="form-control" id="addressCountry" value="Philippines">
|
||||
<input type="text" class="form-control" id="addressCountry">
|
||||
</div>
|
||||
<button type="button" class="btn btn-primary mt-4" id="submitBtn">Submit</button>
|
||||
|
||||
|
@ -486,7 +486,7 @@ if ($_SESSION["isCustomer"] == true) {
|
|||
<div class="form-group">
|
||||
|
||||
<label for="addressContact" class="text-dark font-weight-medium pt-3 mb-2">Contact Number</label>
|
||||
<input type="text" class="form-control" id="addressContact2" value="<?php echo $address['phone']; ?>" oninput="preventEraseThePrefix(this)">
|
||||
<input type="text" class="form-control" id="addressContact2" value="<?php echo $address['phone']; ?>">
|
||||
|
||||
|
||||
<!-- <label for="addressContact" class="text-dark font-weight-medium pt-3 mb-2">Contact Number</label>
|
||||
|
@ -597,7 +597,7 @@ if ($_SESSION["isCustomer"] == true) {
|
|||
</div>
|
||||
<div class="form-group">
|
||||
<label for="bankAccountNumber" class="text-dark font-weight-medium pt-3 mb-2">Bank Account Number</label>
|
||||
<input type="number" class="form-control" id="bankAccountNumber">
|
||||
<input type="text" class="form-control" id="bankAccountNumber">
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<label for="bankAccountName" class="text-dark font-weight-medium pt-3 mb-2">Bank Account Name</label>
|
||||
|
@ -612,55 +612,6 @@ if ($_SESSION["isCustomer"] == true) {
|
|||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<script>
|
||||
function preventErasePrefix(input) { /* secondmodal */
|
||||
|
||||
var numericValue = input.value.replace(/\D/g, '');
|
||||
if (numericValue.startsWith('63')) {
|
||||
input.value = "+63 " + numericValue.substring(2);
|
||||
} else {
|
||||
input.value = "+63 " + numericValue;
|
||||
}
|
||||
|
||||
if (input.value.length > 14) {
|
||||
input.value = input.value.slice(0, 14);
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
function preventEraseThePrefix(input) { /* thirdmodal */
|
||||
|
||||
var numericValue = input.value.replace(/\D/g, '');
|
||||
if (numericValue.startsWith('63')) {
|
||||
input.value = "+63 " + numericValue.substring(2);
|
||||
} else {
|
||||
input.value = "+63 " + numericValue;
|
||||
}
|
||||
|
||||
if (input.value.length > 14) {
|
||||
input.value = input.value.slice(0, 14);
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
function preventEraseInPrefix(input) { /* edit details */
|
||||
|
||||
var numericValue = input.value.replace(/\D/g, '');
|
||||
if (numericValue.startsWith('63')) {
|
||||
input.value = "+63 " + numericValue.substring(2);
|
||||
} else {
|
||||
input.value = "+63 " + numericValue;
|
||||
}
|
||||
|
||||
if (input.value.length > 14) {
|
||||
input.value = input.value.slice(0, 14);
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
</script>
|
||||
|
||||
<script>
|
||||
function editUser() {
|
||||
// var fileInput = document.getElementById('fileInput' + vendorId);
|
||||
|
@ -1674,7 +1625,7 @@ if ($_SESSION["isCustomer"] == true) {
|
|||
</div>
|
||||
<div class="form-group">
|
||||
<label for="cphone-" class="text-dark font-weight-medium pt-3 mb-2">Contact Number</label>
|
||||
<input type="text" class="form-control" id="cphone-" value="<?php echo $vendorData['phone'] ?>" oninput="preventEraseInPrefix(this)">
|
||||
<input type="text" class="form-control" id="cphone-" value="<?php echo $vendorData['phone'] ?>">
|
||||
</div>
|
||||
<!-- 02-23-2023 Jun Jihad Vendor Description Field-->
|
||||
<div class="form-group">
|
||||
|
@ -1700,7 +1651,7 @@ if ($_SESSION["isCustomer"] == true) {
|
|||
<!-- Modal end -->
|
||||
|
||||
<!-- Footer navigation panel for responsive display -->
|
||||
<!-- <div class="ec-nav-toolbar">
|
||||
<div class="ec-nav-toolbar">
|
||||
<div class="container">
|
||||
<div class="ec-nav-panel">
|
||||
<div class="ec-nav-panel-icons">
|
||||
|
@ -1721,7 +1672,7 @@ if ($_SESSION["isCustomer"] == true) {
|
|||
|
||||
</div>
|
||||
</div>
|
||||
</div> -->
|
||||
</div>
|
||||
<!-- Footer navigation panel for responsive display end -->
|
||||
|
||||
<!-- raymart remove popup feb 20 2024 -->
|
||||
|
|
|
@ -379,7 +379,7 @@ if ($_SESSION["isVendor"] == true) {
|
|||
xhr.setRequestHeader('Content-Type', 'application/json');
|
||||
xhr.onreadystatechange = function() {
|
||||
if (xhr.readyState === XMLHttpRequest.DONE) {
|
||||
if (xhr.status === 200) {
|
||||
if (xhr.status === 0) {
|
||||
console.log('Products removed successfully');
|
||||
location.reload();
|
||||
} else {
|
||||
|
@ -527,7 +527,7 @@ if ($_SESSION["isVendor"] == true) {
|
|||
|
||||
|
||||
<!-- Footer navigation panel for responsive display -->
|
||||
<!-- <div class="ec-nav-toolbar">
|
||||
<div class="ec-nav-toolbar">
|
||||
<div class="container">
|
||||
<div class="ec-nav-panel">
|
||||
<div class="ec-nav-panel-icons">
|
||||
|
@ -549,7 +549,7 @@ if ($_SESSION["isVendor"] == true) {
|
|||
|
||||
</div>
|
||||
</div>
|
||||
</div> -->
|
||||
</div>
|
||||
<!-- Footer navigation panel for responsive display end -->
|
||||
|
||||
|
||||
|
|
Loading…
Reference in New Issue