1
0
Fork 0
mirror of https://github.com/archtechx/virtualcolumn.git synced 2025-12-12 19:34:05 +00:00

Add test for generating the column name

This commit is contained in:
lukinovec 2022-10-21 11:49:10 +02:00
parent 43f0b2c30f
commit c0cd839acc
2 changed files with 71 additions and 0 deletions

View file

@ -0,0 +1,32 @@
<?php
declare(strict_types=1);
use Illuminate\Database\Migrations\Migration;
use Illuminate\Database\Schema\Blueprint;
use Illuminate\Support\Facades\Schema;
class CreateFooModelsTable extends Migration
{
/**
* Run the migrations.
*
* @return void
*/
public function up()
{
Schema::create('foo_models', function (Blueprint $table) {
$table->increments('id');
$table->string('custom1')->nullable();
$table->string('custom2')->nullable();
$table->json('virtual');
});
}
public function down()
{
Schema::dropIfExists('foo_models');
}
}