fix no open form
This commit is contained in:
@@ -124,6 +124,14 @@ function openModal(productHref) {
|
|||||||
const modal = document.getElementById("buyNowModal");
|
const modal = document.getElementById("buyNowModal");
|
||||||
modal.style.display = "flex";
|
modal.style.display = "flex";
|
||||||
|
|
||||||
|
// Reset form display for repeated orders
|
||||||
|
const form = modal.querySelector("#buyForm");
|
||||||
|
const confirmation = modal.querySelector("#confirmation");
|
||||||
|
form.style.display = "flex"; // show form
|
||||||
|
confirmation.style.display = "none"; // hide confirmation
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
let product = productHref;
|
let product = productHref;
|
||||||
let price = "";
|
let price = "";
|
||||||
if (productHref.includes("/")) {
|
if (productHref.includes("/")) {
|
||||||
|
|||||||
Reference in New Issue
Block a user