${function() {
if (data === undefined || typeof data !== 'string' || data == '') return '';
const searchEmpty = ("Your search for \"{test}\" did not yield any results.").replace('{test}', data);
return `
/**
* Custom discount code component that handles displaying and managing discount codes
* @extends {SPZ.BaseElement}
*/
class SpzCustomDiscountCode extends SPZ.BaseElement {
constructor(element) {
super(element);
// API endpoint for fetching discount codes
this.getDiscountCodeApi = "\/api\/storefront\/promotion\/code\/list";
// Debounce timer for resize events
this.timer = null;
// Current variant ID
this.variantId = "95696d7c-8dbc-4b7a-8821-71afda1b2303";
// Store discount code data
this.discountCodeData = {}
}
/**
* Check if layout is supported
* @param {string} layout - Layout type
* @return {boolean}
*/
isLayoutSupported(layout) {
return layout == SPZCore.Layout.LOGIC;
}
/**
* Initialize component after build
*/
buildCallback() {
this.templates_ = SPZServices.templatesForDoc();
this.viewport_ = this.getViewport();
// Bind methods to maintain context
this.render = this.render.bind(this);
this.resize = this.resize.bind(this);
this.switchVariant = this.switchVariant.bind(this);
}
/**
* Setup component when mounted
*/
mountCallback() {
this.getData();
// Add event listeners
this.viewport_.onResize(this.resize);
this.win.document.addEventListener('dj.variantChange', this.switchVariant);
}
/**
* Cleanup when component is unmounted
*/
unmountCallback() {
this.viewport_.removeResize(this.resize);
this.win.document.removeEventListener('dj.variantChange', this.switchVariant);
// 清除定时器
if (this.timer) {
clearTimeout(this.timer);
this.timer = null;
}
}
/**
* Handle resize events with debouncing
*/
resize() {
if (this.timer) {
clearTimeout(this.timer)
this.timer = null;
}
this.timer = setTimeout(() => {
if (appDiscountUtils.inProductBody(this.element)) {
this.render();
} else {
this.renderSkeleton();
}
}, 200);
}
/**
* Handle variant changes
* @param {Event} event - Variant change event
*/
switchVariant(event) {
const variant = event.detail.selected;
if (variant.product_id == '1fa82193-f9d0-4db5-b690-622a4bb4156b' && variant.id != this.variantId) {
this.variantId = variant.id;
this.getData();
}
}
/**
* Fetch discount code data from API
*/
getData() {
if (appDiscountUtils.inProductBody(this.element)) {
const reqBody = {
product_id: "1fa82193-f9d0-4db5-b690-622a4bb4156b",
variant_id: this.variantId,
product_type: "",
}
if (!reqBody.product_id || !reqBody.variant_id) return;
this.discountCodeData = {};
this.win.fetch(this.getDiscountCodeApi, {
method: "POST",
body: JSON.stringify(reqBody),
headers: {
"Content-Type": "application/json"
}
}).then(async (response) => {
if (response.ok) {
let data = await response.json();
if (data.list && data.list.length > 0) {
data.list[0].product_setting.template_config = JSON.parse(data.list[0].product_setting.template_config);
// Format timestamps to local timezone
const zone = this.win.SHOPLAZZA.shop.time_zone;
data.list = data.list.map(item => {
if(+item.ends_at !== -1) {
item.ends_at = appDiscountUtils.convertTimestampToFormat(+item.ends_at, zone);
}
item.starts_at = appDiscountUtils.convertTimestampToFormat(+item.starts_at, zone);
return item;
});
}
this.discountCodeData = data;
this.render();
} else {
this.clearDom();
}
}).catch(err => {
console.error("discount_code", err)
this.clearDom();
});
} else {
this.renderSkeleton();
}
}
/**
* Clear component DOM except template
*/
clearDom() {
const children = this.element.querySelector('*:not(template)');
children && SPZCore.Dom.removeElement(children);
}
/**
* Render discount codes with formatted dates
*/
render() {
// Render using discount code model
SPZ.whenApiDefined(document.querySelector('#spz_custom_discount_code_model')).then(renderApi => {
renderApi.doRender_({
discountCodeData: this.discountCodeData
})
}).catch(err => {
this.clearDom();
})
}
renderSkeleton() {
// Render template for non-product pages
this.templates_
.findAndRenderTemplate(this.element, {
isMobile: appDiscountUtils.judgeMobile()
})
.then((el) => {
this.clearDom();
this.element.appendChild(el);
})
.catch(err => {
this.clearDom();
});
}
}
// Register custom element
SPZ.defineElement('spz-custom-discount-code', SpzCustomDiscountCode);
Size:
${data.value}
Color: Pink
${data.targetOption}
Quantity
Made to Order
SKU : ws1913411-3
SKU : ${data.variant && data.variant.sku}
Share the love
Description
Multicolor Women's Oxfords Tassels Lace Up Wingtip Shoes. Their trendy multicolor design, lace-up closure, and charming tassel detailing make them the perfect addition to your wardrobe. These flat-heeled oxfords provide comfort for all-day wear, while the cushioned insole ensures a pleasant experience.
Handcrafted
US sizing. Fits true to size.
These women's oxfords feature a trendy and eye-catching multicolor design, adding a pop of color to your outfit.
The lace-up design provides a secure and adjustable fit, ensuring comfort and support during long walks or daily activities.
These shoes are adorned with tassel detailing, adding a touch of sophistication and a hint of playfulness to your style.
With a flat heel, these shoes offer all-day comfort and are perfect for those looking for a blend of fashion and practicality.
The shoes come with a comfortable insole, making them ideal for extended wear and suitable for various occasions.
Refund and Exchange Policy
Refund and Exchange Policy
Exchange
Refund
Condition
1. Within 30 days from the delivered date. 2. Original New
1. Before returning the package to us for any reason, please email your request to support@fsjshoes.com. In the email please include 1/ order number 2/ items requesting to be returned and 3/ reason for return.
2. When your return request has been approved, please write your order number on a piece of white paper and put it inside the shipping package.
3. Please retain a receipt/proof of postage from your local post office and email the tracking number to us.
The Shipping Fee
Borne by us
Borne by buyer
Processing Time
We will prepare the new items that you exchange and deliver them within 3 days after we receive you exchange parcel.
Within 3 working days after we receive your returning parcel
Address
No.516 5th Floor,Ist Build.,No.666, Middle Section of Tianfu Avenue, High-tech Zone, Chengdu, China
Note: This address is not a return address, please contact customer service to obtain the return address.
Size Chart
Measuring Guide
1. Measure your foot and legs
2. Measure your boots
Recently viewed
${data.map(data => `
`).join('')}
${data.map(data => `
`).join('')}
Reviews
No reviews yet, why don't you leave the first review?