36 lines
1.1 KiB
PHP
36 lines
1.1 KiB
PHP
<?php
|
|
// =========================================================
|
|
// backend/bot/update_jordan_kazan.php
|
|
// Updates the base pricing for Jordan based on the agreed strategy
|
|
// =========================================================
|
|
|
|
require_once __DIR__ . '/../core/bootstrap.php';
|
|
require_once __DIR__ . '/../functions.php';
|
|
|
|
try {
|
|
$con = Database::get('main');
|
|
} catch (Exception $e) {
|
|
die("Database connection failed: " . $e->getMessage() . "\n");
|
|
}
|
|
|
|
echo "Updating Kazan pricing for Jordan...\n";
|
|
|
|
// Update the kazan table where country is Jordan
|
|
$sql = "UPDATE kazan
|
|
SET speedPrice = '0.25',
|
|
naturePrice = '0.05',
|
|
heavyPrice = '0.06',
|
|
latePrice = '0.05'
|
|
WHERE country = 'Jordan' OR country = 'JO'";
|
|
|
|
$stmt = $con->prepare($sql);
|
|
$result = $stmt->execute();
|
|
|
|
if ($result) {
|
|
$rowCount = $stmt->rowCount();
|
|
echo "Successfully updated $rowCount row(s) for Jordan in the kazan table.\n";
|
|
echo "New Pricing: Base=0.35 JOD, Per Km=0.22 JOD, Per Min=0.05 JOD\n";
|
|
} else {
|
|
echo "Failed to update kazan table.\n";
|
|
}
|