mirror of
https://github.com/invoiceninja/invoiceninja.git
synced 2025-06-23 20:00:33 -04:00
Added early_access field
This commit is contained in:
parent
4549643fdc
commit
ecaf31ec95
@ -1,10 +1,9 @@
|
||||
<?php
|
||||
|
||||
use Illuminate\Database\Schema\Blueprint;
|
||||
use Illuminate\Database\Migrations\Migration;
|
||||
|
||||
class AddInvoiceFontSupport extends Migration {
|
||||
|
||||
class AddInvoiceFontSupport extends Migration
|
||||
{
|
||||
/**
|
||||
* Run the migrations.
|
||||
*
|
||||
@ -14,8 +13,7 @@ class AddInvoiceFontSupport extends Migration {
|
||||
{
|
||||
Schema::dropIfExists('fonts');
|
||||
|
||||
Schema::create('fonts', function($t)
|
||||
{
|
||||
Schema::create('fonts', function ($t) {
|
||||
$t->increments('id');
|
||||
|
||||
$t->string('name');
|
||||
@ -27,6 +25,7 @@ class AddInvoiceFontSupport extends Migration {
|
||||
$t->string('bold');
|
||||
$t->string('italics');
|
||||
$t->string('bolditalics');
|
||||
$t->boolean('early_access');
|
||||
$t->unsignedInteger('sort_order')->default(10000);
|
||||
});
|
||||
|
||||
@ -34,14 +33,12 @@ class AddInvoiceFontSupport extends Migration {
|
||||
$seeder = new FontsSeeder();
|
||||
$seeder->run();
|
||||
|
||||
Schema::table('accounts', function($table)
|
||||
{
|
||||
Schema::table('accounts', function ($table) {
|
||||
$table->unsignedInteger('header_font_id')->default(1);
|
||||
$table->unsignedInteger('body_font_id')->default(1);
|
||||
});
|
||||
|
||||
Schema::table('accounts', function($table)
|
||||
{
|
||||
Schema::table('accounts', function ($table) {
|
||||
$table->foreign('header_font_id')->references('id')->on('fonts');
|
||||
$table->foreign('body_font_id')->references('id')->on('fonts');
|
||||
});
|
||||
@ -54,19 +51,15 @@ class AddInvoiceFontSupport extends Migration {
|
||||
*/
|
||||
public function down()
|
||||
{
|
||||
if (Schema::hasColumn('accounts', 'header_font_id'))
|
||||
{
|
||||
Schema::table('accounts', function($table)
|
||||
{
|
||||
if (Schema::hasColumn('accounts', 'header_font_id')) {
|
||||
Schema::table('accounts', function ($table) {
|
||||
$table->dropForeign('accounts_header_font_foreign');
|
||||
$table->dropColumn('header_font_id');
|
||||
});
|
||||
}
|
||||
|
||||
if (Schema::hasColumn('accounts', 'body_font_id'))
|
||||
{
|
||||
Schema::table('accounts', function($table)
|
||||
{
|
||||
if (Schema::hasColumn('accounts', 'body_font_id')) {
|
||||
Schema::table('accounts', function ($table) {
|
||||
$table->dropForeign('accounts_body_font_foreign');
|
||||
$table->dropColumn('body_font_id');
|
||||
});
|
||||
@ -74,5 +67,4 @@ class AddInvoiceFontSupport extends Migration {
|
||||
|
||||
Schema::dropIfExists('fonts');
|
||||
}
|
||||
|
||||
}
|
4
public/css/built.css
vendored
4
public/css/built.css
vendored
File diff suppressed because one or more lines are too long
4
public/css/built.public.css
vendored
4
public/css/built.public.css
vendored
File diff suppressed because one or more lines are too long
Loading…
x
Reference in New Issue
Block a user