Code cleanup.

This commit is contained in:
James Cole
2017-11-22 21:12:27 +01:00
parent 4e6b782204
commit 781ca052d8
142 changed files with 213 additions and 859 deletions

View File

@@ -20,7 +20,6 @@ class CreateSupportTables extends Migration
{
/**
* Reverse the migrations.
*
*/
public function down()
{
@@ -124,8 +123,7 @@ class CreateSupportTables extends Migration
Schema::create(
'jobs',
function (Blueprint $table) {
// straight from Laravel
// straight from Laravel
$table->bigIncrements('id');
$table->string('queue');
$table->longText('payload');

View File

@@ -60,7 +60,6 @@ class CreateMainTables extends Migration
*/
public function up()
{
//
$this->createAccountTables();
$this->createPiggyBanksTable();
$this->createAttachmentsTable();
@@ -433,7 +432,6 @@ class CreateMainTables extends Migration
$table->boolean('active')->default(1);
$table->boolean('stop_processing')->default(0);
// link rule id to rules table
$table->foreign('rule_id')->references('id')->on('rules')->onDelete('cascade');
}
@@ -454,7 +452,6 @@ class CreateMainTables extends Migration
$table->boolean('active')->default(1);
$table->boolean('stop_processing')->default(0);
// link rule id to rules table
$table->foreign('rule_id')->references('id')->on('rules')->onDelete('cascade');
}
@@ -583,7 +580,6 @@ class CreateMainTables extends Migration
);
}
if (!Schema::hasTable('piggy_bank_events')) {
Schema::create(
'piggy_bank_events',

View File

@@ -23,7 +23,6 @@ class ChangesFor3101 extends Migration
*/
public function down()
{
//
}
/**

View File

@@ -18,7 +18,6 @@ use Illuminate\Database\Schema\Blueprint;
*/
class FixNullables extends Migration
{
/**
* Reverse the migrations.
*/

View File

@@ -8,7 +8,6 @@
*
* See the LICENSE file for details.
*/
declare(strict_types=1);
use Illuminate\Database\Migrations\Migration;
@@ -24,7 +23,6 @@ class ExpandTransactionsTable extends Migration
*/
public function down()
{
//
}
/**

View File

@@ -8,7 +8,6 @@
*
* See the LICENSE file for details.
*/
declare(strict_types=1);
use Illuminate\Database\Migrations\Migration;

View File

@@ -8,7 +8,6 @@
*
* See the LICENSE file for details.
*/
declare(strict_types=1);
use Illuminate\Database\Migrations\Migration;
@@ -24,7 +23,6 @@ class ChangesForV420 extends Migration
*/
public function down()
{
//
}
/**

View File

@@ -8,10 +8,8 @@
*
* See the LICENSE file for details.
*/
declare(strict_types=1);
use Illuminate\Database\Migrations\Migration;
use Illuminate\Database\Schema\Blueprint;
@@ -47,7 +45,6 @@ class ChangesForV430 extends Migration
$table->date('start_date');
$table->date('end_date');
$table->foreign('transaction_currency_id')->references('id')->on('transaction_currencies')->onDelete('cascade');
$table->foreign('user_id')->references('id')->on('users')->onDelete('cascade');
}

View File

@@ -8,7 +8,6 @@
*
* See the LICENSE file for details.
*/
declare(strict_types=1);
use Illuminate\Database\Migrations\Migration;
@@ -21,8 +20,6 @@ class ChangesForV431 extends Migration
{
/**
* Reverse the migrations.
*
* @return void
*/
public function down()
{
@@ -40,7 +37,6 @@ class ChangesForV431 extends Migration
}
);
// remove date field "end_date"
Schema::table(
'budget_limits',

View File

@@ -8,10 +8,8 @@
*
* See the LICENSE file for details.
*/
declare(strict_types=1);
use Illuminate\Database\Migrations\Migration;
use Illuminate\Database\Schema\Blueprint;
@@ -22,8 +20,6 @@ class ChangesForV440 extends Migration
{
/**
* Reverse the migrations.
*
* @return void
*/
public function down()
{
@@ -36,7 +32,6 @@ class ChangesForV440 extends Migration
* Run the migrations.
*
* @SuppressWarnings(PHPMD.ShortMethodName)
* @return void
*/
public function up()
{
@@ -60,7 +55,7 @@ class ChangesForV440 extends Migration
}
);
}
//
Schema::table(
'transactions',
function (Blueprint $table) {

View File

@@ -8,10 +8,8 @@
*
* See the LICENSE file for details.
*/
declare(strict_types=1);
use Illuminate\Database\Migrations\Migration;
use Illuminate\Database\Schema\Blueprint;
@@ -22,8 +20,6 @@ class ChangesForV450 extends Migration
{
/**
* Reverse the migrations.
*
* @return void
*/
public function down()
{
@@ -33,7 +29,6 @@ class ChangesForV450 extends Migration
* Run the migrations.
*
* @SuppressWarnings(PHPMD.ShortMethodName)
* @return void
*/
public function up()
{

View File

@@ -1,6 +1,6 @@
<?php
declare(strict_types=1);
declare(strict_types=1);
use Illuminate\Database\Migrations\Migration;
use Illuminate\Database\Schema\Blueprint;
@@ -13,8 +13,6 @@ class ChangesForV470 extends Migration
{
/**
* Reverse the migrations.
*
* @return void
*/
public function down()
{
@@ -26,7 +24,6 @@ class ChangesForV470 extends Migration
* Run the migrations.
*
* @SuppressWarnings(PHPMD.ShortMethodName)
* @return void
*/
public function up()
{
@@ -42,7 +39,7 @@ class ChangesForV470 extends Migration
$table->string('inward');
$table->boolean('editable');
$table->unique(['name', 'outward','inward']);
$table->unique(['name', 'outward', 'inward']);
}
);
}
@@ -62,7 +59,7 @@ class ChangesForV470 extends Migration
$table->foreign('source_id')->references('id')->on('transaction_journals')->onDelete('cascade');
$table->foreign('destination_id')->references('id')->on('transaction_journals')->onDelete('cascade');
$table->unique(['link_type_id','source_id','destination_id']);
$table->unique(['link_type_id', 'source_id', 'destination_id']);
}
);
}

View File

@@ -1,6 +1,6 @@
<?php
declare(strict_types=1);
declare(strict_types=1);
use Illuminate\Database\Migrations\Migration;
use Illuminate\Database\Schema\Blueprint;
@@ -10,19 +10,15 @@ class ChangesForV470a extends Migration
{
/**
* Reverse the migrations.
*
* @return void
*/
public function down()
{
//
}
/**
* Run the migrations.
*
* @SuppressWarnings(PHPMD.ShortMethodName)
* @return void
*/
public function up()
{