removed invoice/bill status tables

This commit is contained in:
denisdulici
2020-01-11 16:57:32 +03:00
parent b5519004a0
commit 08eb8e75fc
69 changed files with 250 additions and 470 deletions

View File

@ -556,7 +556,6 @@ class CoreV1 extends Migration
Schema::drop('bill_histories');
Schema::drop('bill_items');
Schema::drop('bill_item_taxes');
Schema::drop('bill_statuses');
Schema::drop('bill_totals');
Schema::drop('categories');
Schema::drop('companies');
@ -565,7 +564,6 @@ class CoreV1 extends Migration
Schema::drop('invoice_histories');
Schema::drop('invoice_items');
Schema::drop('invoice_item_taxes');
Schema::drop('invoice_statuses');
Schema::drop('invoice_totals');
Schema::drop('items');
Schema::drop('jobs');

View File

@ -41,6 +41,7 @@ class CoreV200 extends Migration
});
$rename_bills = [
'bill_status_code' => 'status',
'vendor_id' => 'contact_id',
'vendor_name' => 'contact_name',
'vendor_email' => 'contact_email',
@ -55,7 +56,14 @@ class CoreV200 extends Migration
});
}
Schema::table('bill_histories', function (Blueprint $table) {
$table->renameColumn('status_code', 'status');
});
Schema::drop('bill_statuses');
$rename_invoices = [
'invoice_status_code' => 'status',
'customer_id' => 'contact_id',
'customer_name' => 'contact_name',
'customer_email' => 'contact_email',
@ -70,6 +78,12 @@ class CoreV200 extends Migration
});
}
Schema::table('invoice_histories', function (Blueprint $table) {
$table->renameColumn('status_code', 'status');
});
Schema::drop('invoice_statuses');
// Dashboards
Schema::create('dashboards', function (Blueprint $table) {
$table->increments('id');
@ -129,7 +143,7 @@ class CoreV200 extends Migration
$table->boolean('blocked')->default(1);
$table->timestamps();
$table->softDeletes();
$table->index('ip');
$table->unique(['ip', 'deleted_at']);
});
@ -145,7 +159,7 @@ class CoreV200 extends Migration
$table->text('request')->nullable();
$table->timestamps();
$table->softDeletes();
$table->index('ip');
});