Merge pull request #7494 from CirkaN/Cirkovic/INA-5-migration

INA-5 | Push alter migration fix for schedulers table
This commit is contained in:
David Bomba 2022-06-01 15:16:12 +10:00 committed by GitHub
commit 20157a82c3
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 42 additions and 3 deletions

View File

@ -30,9 +30,6 @@ class CreateSchedulersTable extends Migration
$table->timestamp('start_from');
$table->timestamp('scheduled_run');
$table->foreignIdFor(\App\Models\Company::class);
$table->string('action_name')->index();
$table->string('action_class');
$table->json('parameters')->nullable();
$table->timestamps();
$table->softDeletes();
});

View File

@ -0,0 +1,42 @@
<?php
/**
* Invoice Ninja (https://invoiceninja.com).
*
* @link https://github.com/invoiceninja/invoiceninja source repository
*
* @copyright Copyright (c) 2021. Invoice Ninja LLC (https://invoiceninja.com)
*
* @license https://opensource.org/licenses/AAL
*/
use Illuminate\Database\Migrations\Migration;
use Illuminate\Database\Schema\Blueprint;
use Illuminate\Support\Facades\Schema;
class AddJobRelatedFieldsToSchedulersTable extends Migration
{
/**
* Run the migrations.
*
* @return void
*/
public function up()
{
Schema::table('schedulers', function (Blueprint $table) {
$table->string('action_name')->index();
$table->string('action_class');
$table->json('parameters')->nullable();
});
}
/**
* Reverse the migrations.
*
* @return void
*/
public function down()
{
Schema::table('schedulers', function (Blueprint $table) {
//
});
}
}