Fix for rollback

This commit is contained in:
Hillel Coren 2016-05-29 17:36:36 +03:00
parent 8d0bed3754
commit 7af05c077a
2 changed files with 1 additions and 5 deletions

View File

@ -29,8 +29,8 @@ class AddQuotes extends Migration {
{ {
Schema::table('invoices', function($table) Schema::table('invoices', function($table)
{ {
$table->dropColumn('is_quote');
$table->dropColumn('invoice_type_id'); $table->dropColumn('invoice_type_id');
$table->dropColumn('quote_id');
$table->dropColumn('quote_invoice_id'); $table->dropColumn('quote_invoice_id');
}); });
} }

View File

@ -37,10 +37,6 @@ class AddInvoiceTypeSupport extends Migration
{ {
if (Schema::hasColumn('invoices', 'invoice_type_id')) { if (Schema::hasColumn('invoices', 'invoice_type_id')) {
DB::update('update invoices set invoice_type_id = invoice_type_id - 1'); DB::update('update invoices set invoice_type_id = invoice_type_id - 1');
Schema::table('invoices', function ($table) {
$table->renameColumn('invoice_type_id', 'is_quote');
});
} }
Schema::table('accounts', function($table) Schema::table('accounts', function($table)