Update file size and modification time for class.Cron.php; adjust product history count threshold in cron logic

This commit is contained in:
2025-05-03 00:59:39 +02:00
parent 1aa3c3a390
commit e1574a3730
2 changed files with 3 additions and 3 deletions

View File

@@ -35,8 +35,8 @@
},
"class.Cron.php": {
"type": "-",
"size": 20797,
"lmtime": 1745446362787,
"size": 20896,
"lmtime": 1745745807850,
"modified": false
},
"class.Products.php": {

View File

@@ -259,7 +259,7 @@ class Cron
$conversions_value = $offer['conversions_value'];
$roas = ( $conversions_value > 0 and $cost ) ? round( $conversions_value / $cost, 2 ) * 100 : 0;
if ( $mdb -> count( 'products_history', [ 'AND' => [ 'product_id' => $product_id, 'date_add[<=]' => $date_to ] ] ) >= 30 )
if ( $mdb -> count( 'products_history', [ 'AND' => [ 'product_id' => $product_id, 'date_add[<=]' => $date_to ] ] ) >= 14 )
{
if ( $mdb -> count( 'products_history_30', [ 'AND' => [ 'product_id' => $product_id, 'date_add' => $date_to ] ] ) > 0 )
{