Add migration to enhance session_payments table with payment_method_uuid and reference fields for split-payment details

This commit is contained in:
hamed
2026-07-23 15:37:58 +03:30
parent 1d1c3d5f30
commit a0a2eb1799
23 changed files with 2257 additions and 1432 deletions
+30
View File
@@ -0,0 +1,30 @@
<?php
declare(strict_types=1);
namespace DoctrineMigrations;
use Doctrine\DBAL\Schema\Schema;
use Doctrine\Migrations\AbstractMigration;
/**
* Auto-generated Migration: Please modify to your needs!
*/
final class Version20260723120122 extends AbstractMigration
{
public function getDescription(): string
{
return 'Add payment_method_uuid + reference to session_payments for split-payment details (POS device / transaction id).';
}
public function up(Schema $schema): void
{
// پرداختِ چندروشیِ نوبت: جزئیاتِ هر پرداخت (کارت‌خوان/حساب بانکیِ ثبت‌شده + شناسه تراکنش).
$this->addSql('ALTER TABLE session_payments ADD payment_method_uuid VARCHAR(36) DEFAULT NULL, ADD reference VARCHAR(255) DEFAULT NULL');
}
public function down(Schema $schema): void
{
$this->addSql('ALTER TABLE session_payments DROP payment_method_uuid, DROP reference');
}
}