before
This commit is contained in:
@@ -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();
|
||||
|
||||
Reference in New Issue
Block a user