added banks logos

This commit is contained in:
2026-07-06 13:39:05 +03:30
parent 2f48b88cf6
commit 0f775d20e8
3 changed files with 16 additions and 4 deletions
+6 -1
View File
@@ -71,12 +71,17 @@ class LivePriceTickService
$liquidGold = app(ProductDisplayPriceService::class)->resolveHistoricalBasePrice();
}
$tickSource = (string) ($payload['price_source'] ?? $source);
if ($tickSource === '') {
$tickSource = $source;
}
$activeProducts = Product::query()
->where('active', 1)
->whereNotNull('reading_method')
->count();
$syncLog = app(PriceSyncLogService::class)->recordTick($source, $sourceUrl, $liquidGold, $activeProducts);
$syncLog = app(PriceSyncLogService::class)->recordTick($tickSource, $sourceUrl, $liquidGold, $activeProducts);
app(LivePriceCacheService::class)->markTick();
+1 -1
View File
@@ -102,7 +102,7 @@ class PriceSyncLogService
/** فقط وقتی قیمت مرجع آبشده نسبت به آخرین رکورد عوض شده باشد */
public function recordTick(string $source, ?string $sourceUrl, int $liquidGoldPrice, int $productsSynced): ?PriceSyncLog
{
if (! $this->isAvailable() || $liquidGoldPrice <= 0) {
if (! $this->isAvailable() || $liquidGoldPrice <= 0 || $source === 'database_last') {
return null;
}