added modal inser lesson maually by teacher
This commit is contained in:
@@ -0,0 +1,35 @@
|
||||
<?php
|
||||
|
||||
declare(strict_types=1);
|
||||
|
||||
use Phinx\Migration\AbstractMigration;
|
||||
|
||||
/**
|
||||
* Aggiunge la colonna is_gift a bookingclass.
|
||||
*
|
||||
* is_gift = 'Y' indica una lezione OMAGGIO inserita dall'insegnante:
|
||||
* - non consuma ticket dell'ordine (esclusa dai conteggi residui)
|
||||
* - non è riprogrammabile (legata alla data della classe)
|
||||
* - tipicamente ha idorder = NULL
|
||||
*
|
||||
* Default 'N' = prenotazione normale.
|
||||
*/
|
||||
final class AddIsGiftToBookingclass extends AbstractMigration
|
||||
{
|
||||
public function up(): void
|
||||
{
|
||||
$table = $this->table('bookingclass');
|
||||
$table->addColumn('is_gift', 'char', [
|
||||
'limit' => 1,
|
||||
'null' => false,
|
||||
'default' => 'N',
|
||||
'after' => 'is_reprogrammed',
|
||||
])->update();
|
||||
}
|
||||
|
||||
public function down(): void
|
||||
{
|
||||
$table = $this->table('bookingclass');
|
||||
$table->removeColumn('is_gift')->update();
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user