Skip to content

Commit

Permalink
Merge pull request #431 from xxl4/task-20240709
Browse files Browse the repository at this point in the history
fix miss sku id
  • Loading branch information
wangqian425 authored Jul 15, 2024
2 parents 800663a + 51fe600 commit 4e5f843
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -2653,7 +2653,6 @@ function gtag() {
$('.buy-select').hide()
$('#p2-select').show()
$('#product2').addClass('background-green')
initProuctData(0, '2')
}
var nprice = currencySymbol + data.package_products[0].new_price.toFixed(2)
$('#summary-total1').text(nprice)
Expand Down Expand Up @@ -2753,6 +2752,12 @@ function gtag() {
params.products = []
params.products.push(productL1, productL2)
getSkuListInfo();
if (data.attr.attributes.length == 0) {
params.products.forEach(function(item) {
item.product_sku = data.sku
item.variant_id = ''
})
}
$('#pc-banner').attr('src', data.ads.pc.img);
$('#mobile-banner').attr('src', data.ads.mobile.img);
$('.prod-name').text('<?php echo addslashes($data['product']['name']); ?>')
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -1561,7 +1561,6 @@ function gtag() {
$('.buy-select').hide()
$('#p2-select').show()
$('#product2').addClass('background-green')
initProuctData(0, '2')
}
var nprice = currencySymbol + data.package_products[0].new_price.toFixed(2)
$('#summary-total1').text(nprice)
Expand Down Expand Up @@ -1656,6 +1655,12 @@ function gtag() {
params.products = []
params.products.push(productL1, productL2)
getSkuListInfo();
if (data.attr.attributes.length == 0) {
params.products.forEach(function(item) {
item.product_sku = data.sku
item.variant_id = ''
})
}
$('.prod-name').text('<?php echo addslashes($data['product']['name']); ?>')
console.log('<?php echo addslashes($data['product']['name']); ?>', '123');
$('title').html('<?php echo addslashes($data['product']['name']); ?>')
Expand Down

0 comments on commit 4e5f843

Please sign in to comment.