fix: Update import logic to skip combinations without EAN and adjust file size in sync cache
This commit is contained in:
6
.vscode/ftp-kr.sync.cache.json
vendored
6
.vscode/ftp-kr.sync.cache.json
vendored
@@ -11786,9 +11786,9 @@
|
||||
},
|
||||
"import-product.php": {
|
||||
"type": "-",
|
||||
"size": 31409,
|
||||
"lmtime": 1749162646583,
|
||||
"modified": true
|
||||
"size": 32611,
|
||||
"lmtime": 1749496748331,
|
||||
"modified": false
|
||||
},
|
||||
"index.php": {
|
||||
"type": "-",
|
||||
|
||||
@@ -78,6 +78,9 @@ foreach ( $products_array as $product )
|
||||
|
||||
foreach ( $product['combinations'] as $combination )
|
||||
{
|
||||
if ( empty( $combination['ean'] ) )
|
||||
continue;
|
||||
|
||||
$sql_combination = 'UPDATE `' . _DB_PREFIX_ . 'product_attribute` SET `price` = ' . (float)$combination['price'] . ' WHERE `reference` = \'' . pSQL($combination['ean']) . '\'';
|
||||
$result_combination = Db::getInstance()->execute($sql_combination);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user