This commit is contained in:
gholak tala
2026-02-05 07:55:13 +00:00
parent 1ffd86b0ef
commit fd3c9b0320
@@ -132,10 +132,10 @@ class ReportController extends Controller
try {
$taban_gohar = Http::timeout(2)->get('https://tabangohar.com/GheymatKhan/prices_in_table.html')->json();
$tgn = (int)$taban_gohar['c'];
$tgn = (int)$taban_gohar['c']*10;
}catch (\Exception $e){$tgn = 0;}
$priceValue = $tgn ==0 ? $pr_product['price'] + $pr_product['price_profit'] : $tgn;//$tala_ir;//4000
$priceValue = $tgn !== 0 ? $tgn : $pr_product['price'] + $pr_product['price_profit'];//$tala_ir;//4000
$lastPrice = Price::latest()->first();
if (!$lastPrice || $lastPrice->price != $priceValue and $priceValue > 30000000) {
$price = new Price();