diff --git a/migrations/2016_01_01_000000_add_voyager_user_fields.php b/migrations/2016_01_01_000000_add_voyager_user_fields.php index c88dc5c276..db03395151 100644 --- a/migrations/2016_01_01_000000_add_voyager_user_fields.php +++ b/migrations/2016_01_01_000000_add_voyager_user_fields.php @@ -1,17 +1,20 @@ string('avatar')->nullable()->after('email')->default('users/default.png'); + $table->string('test')->nullable()->after('email')->default('users/default.png'); } $table->bigInteger('role_id')->nullable()->after('id'); }); @@ -23,14 +26,14 @@ public function up() public function down() { if (Schema::hasColumn('users', 'avatar')) { - Schema::table('users', function ($table) { + Schema::table('users', function (Blueprint $table) { $table->dropColumn('avatar'); }); } if (Schema::hasColumn('users', 'role_id')) { - Schema::table('users', function ($table) { + Schema::table('users', function (Blueprint $table) { $table->dropColumn('role_id'); }); } } -} +}; diff --git a/migrations/2016_01_01_000000_create_data_types_table.php b/migrations/2016_01_01_000000_create_data_types_table.php index a5af697626..1c82148b7c 100644 --- a/migrations/2016_01_01_000000_create_data_types_table.php +++ b/migrations/2016_01_01_000000_create_data_types_table.php @@ -2,8 +2,9 @@ use Illuminate\Database\Migrations\Migration; use Illuminate\Database\Schema\Blueprint; +use Illuminate\Support\Facades\Schema; -class CreateDataTypesTable extends Migration +return new class extends Migration { /** * Run the migrations. @@ -56,4 +57,4 @@ public function down() Schema::drop('data_rows'); Schema::drop('data_types'); } -} +}; diff --git a/migrations/2016_05_19_173453_create_menu_table.php b/migrations/2016_05_19_173453_create_menu_table.php index 8ac60e89a5..5c1b414fb2 100644 --- a/migrations/2016_05_19_173453_create_menu_table.php +++ b/migrations/2016_05_19_173453_create_menu_table.php @@ -2,8 +2,9 @@ use Illuminate\Database\Migrations\Migration; use Illuminate\Database\Schema\Blueprint; +use Illuminate\Support\Facades\Schema; -class CreateMenuTable extends Migration +return new class extends Migration { /** * Run the migrations. @@ -46,4 +47,4 @@ public function down() Schema::drop('menu_items'); Schema::drop('menus'); } -} +}; diff --git a/migrations/2016_10_21_190000_create_roles_table.php b/migrations/2016_10_21_190000_create_roles_table.php index b3650f5e2d..90ee2e31ff 100644 --- a/migrations/2016_10_21_190000_create_roles_table.php +++ b/migrations/2016_10_21_190000_create_roles_table.php @@ -4,7 +4,7 @@ use Illuminate\Database\Schema\Blueprint; use Illuminate\Support\Facades\Schema; -class CreateRolesTable extends Migration +return new class extends Migration { /** * Run the migrations. @@ -30,4 +30,4 @@ public function down() { Schema::drop('roles'); } -} +}; diff --git a/migrations/2016_10_21_190000_create_settings_table.php b/migrations/2016_10_21_190000_create_settings_table.php index 15e9f901a0..7f0632ad70 100644 --- a/migrations/2016_10_21_190000_create_settings_table.php +++ b/migrations/2016_10_21_190000_create_settings_table.php @@ -4,7 +4,7 @@ use Illuminate\Database\Schema\Blueprint; use Illuminate\Support\Facades\Schema; -class CreateSettingsTable extends Migration +return new class extends Migration { /** * Run the migrations. @@ -33,4 +33,4 @@ public function down() { Schema::dropIfExists('settings'); } -} +}; diff --git a/migrations/2016_11_30_135954_create_permission_table.php b/migrations/2016_11_30_135954_create_permission_table.php index ff2464d10c..83d8c8358d 100644 --- a/migrations/2016_11_30_135954_create_permission_table.php +++ b/migrations/2016_11_30_135954_create_permission_table.php @@ -4,7 +4,7 @@ use Illuminate\Database\Schema\Blueprint; use Illuminate\Support\Facades\Schema; -class CreatePermissionTable extends Migration +return new class extends Migration { /** * Run the migrations. @@ -30,4 +30,4 @@ public function down() { Schema::dropIfExists('permissions'); } -} +}; diff --git a/migrations/2016_11_30_141208_create_permission_role_table.php b/migrations/2016_11_30_141208_create_permission_role_table.php index 9bde6c3451..b9315774b8 100644 --- a/migrations/2016_11_30_141208_create_permission_role_table.php +++ b/migrations/2016_11_30_141208_create_permission_role_table.php @@ -4,7 +4,7 @@ use Illuminate\Database\Schema\Blueprint; use Illuminate\Support\Facades\Schema; -class CreatePermissionRoleTable extends Migration +return new class extends Migration { /** * Run the migrations. @@ -31,4 +31,4 @@ public function down() { Schema::dropIfExists('permission_role'); } -} +}; diff --git a/migrations/2016_12_26_201236_data_types__add__server_side.php b/migrations/2016_12_26_201236_data_types__add__server_side.php index d945b73d9c..1d1150258d 100644 --- a/migrations/2016_12_26_201236_data_types__add__server_side.php +++ b/migrations/2016_12_26_201236_data_types__add__server_side.php @@ -4,7 +4,7 @@ use Illuminate\Database\Schema\Blueprint; use Illuminate\Support\Facades\Schema; -class DataTypesAddServerSide extends Migration +return new class extends Migration { /** * Run the migrations. @@ -29,4 +29,4 @@ public function down() $table->dropColumn('server_side'); }); } -} +}; diff --git a/migrations/2017_01_13_000000_add_route_to_menu_items_table.php b/migrations/2017_01_13_000000_add_route_to_menu_items_table.php index dbb0fab9c0..72a08fb1c7 100644 --- a/migrations/2017_01_13_000000_add_route_to_menu_items_table.php +++ b/migrations/2017_01_13_000000_add_route_to_menu_items_table.php @@ -4,7 +4,7 @@ use Illuminate\Database\Schema\Blueprint; use Illuminate\Support\Facades\Schema; -class AddRouteToMenuItemsTable extends Migration +return new class extends Migration { /** * Run the migrations. @@ -38,4 +38,4 @@ public function down() }); } } -} +}; diff --git a/migrations/2017_01_14_005015_create_translations_table.php b/migrations/2017_01_14_005015_create_translations_table.php index c9887a87e5..3997a89e03 100644 --- a/migrations/2017_01_14_005015_create_translations_table.php +++ b/migrations/2017_01_14_005015_create_translations_table.php @@ -4,7 +4,7 @@ use Illuminate\Database\Schema\Blueprint; use Illuminate\Support\Facades\Schema; -class CreateTranslationsTable extends Migration +return new class extends Migration { /** * Run the migrations. @@ -38,4 +38,4 @@ public function down() { Schema::dropIfExists('translations'); } -} +}; diff --git a/migrations/2017_01_15_000000_make_table_name_nullable_in_permissions_table.php b/migrations/2017_01_15_000000_make_table_name_nullable_in_permissions_table.php index 5c133a21cf..bccab53f2a 100644 --- a/migrations/2017_01_15_000000_make_table_name_nullable_in_permissions_table.php +++ b/migrations/2017_01_15_000000_make_table_name_nullable_in_permissions_table.php @@ -4,7 +4,7 @@ use Illuminate\Database\Schema\Blueprint; use Illuminate\Support\Facades\Schema; -class MakeTableNameNullableInPermissionsTable extends Migration +return new class extends Migration { /** * Run the migrations. @@ -27,4 +27,4 @@ public function down() { // } -} +}; diff --git a/migrations/2017_03_06_000000_add_controller_to_data_types_table.php b/migrations/2017_03_06_000000_add_controller_to_data_types_table.php index 1ccce96dbd..a8733d0a89 100644 --- a/migrations/2017_03_06_000000_add_controller_to_data_types_table.php +++ b/migrations/2017_03_06_000000_add_controller_to_data_types_table.php @@ -4,7 +4,7 @@ use Illuminate\Database\Schema\Blueprint; use Illuminate\Support\Facades\Schema; -class AddControllerToDataTypesTable extends Migration +return new class extends Migration { /** * Run the migrations. @@ -29,4 +29,4 @@ public function down() $table->dropColumn('controller'); }); } -} +}; diff --git a/migrations/2017_04_21_000000_add_order_to_data_rows_table.php b/migrations/2017_04_21_000000_add_order_to_data_rows_table.php index 420bfe131d..d8f509b04c 100644 --- a/migrations/2017_04_21_000000_add_order_to_data_rows_table.php +++ b/migrations/2017_04_21_000000_add_order_to_data_rows_table.php @@ -4,7 +4,7 @@ use Illuminate\Database\Schema\Blueprint; use Illuminate\Support\Facades\Schema; -class AddOrderToDataRowsTable extends Migration +return new class extends Migration { /** * Run the migrations. @@ -29,4 +29,4 @@ public function down() $table->dropColumn('order'); }); } -} +}; diff --git a/migrations/2017_07_05_210000_add_policyname_to_data_types_table.php b/migrations/2017_07_05_210000_add_policyname_to_data_types_table.php index 469e0e79b0..509873c34e 100644 --- a/migrations/2017_07_05_210000_add_policyname_to_data_types_table.php +++ b/migrations/2017_07_05_210000_add_policyname_to_data_types_table.php @@ -2,8 +2,9 @@ use Illuminate\Database\Migrations\Migration; use Illuminate\Database\Schema\Blueprint; +use Illuminate\Support\Facades\Schema; -class AddPolicyNameToDataTypesTable extends Migration +return new class extends Migration { /** * Run the migrations. @@ -28,4 +29,4 @@ public function down() $table->dropColumn('policy_name'); }); } -} +}; diff --git a/migrations/2017_08_05_000000_add_group_to_settings_table.php b/migrations/2017_08_05_000000_add_group_to_settings_table.php index 6c8c68f8c2..b419f4b555 100644 --- a/migrations/2017_08_05_000000_add_group_to_settings_table.php +++ b/migrations/2017_08_05_000000_add_group_to_settings_table.php @@ -4,7 +4,7 @@ use Illuminate\Database\Schema\Blueprint; use Illuminate\Support\Facades\Schema; -class AddGroupToSettingsTable extends Migration +return new class extends Migration { /** * Run the migrations. @@ -29,4 +29,4 @@ public function down() $table->dropColumn('group'); }); } -} +}; diff --git a/migrations/2017_11_26_013050_add_user_role_relationship.php b/migrations/2017_11_26_013050_add_user_role_relationship.php index 93956d7670..4953d43660 100644 --- a/migrations/2017_11_26_013050_add_user_role_relationship.php +++ b/migrations/2017_11_26_013050_add_user_role_relationship.php @@ -4,7 +4,7 @@ use Illuminate\Database\Schema\Blueprint; use Illuminate\Support\Facades\Schema; -class AddUserRoleRelationship extends Migration +return new class extends Migration { /** * Run the migrations. @@ -34,4 +34,4 @@ public function down() $table->bigInteger('role_id')->change(); }); } -} +}; diff --git a/migrations/2017_11_26_015000_create_user_roles_table.php b/migrations/2017_11_26_015000_create_user_roles_table.php index 08af586771..d84bf53700 100644 --- a/migrations/2017_11_26_015000_create_user_roles_table.php +++ b/migrations/2017_11_26_015000_create_user_roles_table.php @@ -2,9 +2,10 @@ use Illuminate\Database\Migrations\Migration; use Illuminate\Database\Schema\Blueprint; +use Illuminate\Support\Facades\DB; use Illuminate\Support\Facades\Schema; -class CreateUserRolesTable extends Migration +return new class extends Migration { /** * Run the migrations. @@ -37,4 +38,4 @@ public function down() { Schema::dropIfExists('user_roles'); } -} +}; diff --git a/migrations/2018_03_11_000000_add_user_settings.php b/migrations/2018_03_11_000000_add_user_settings.php index ed99502436..82e13e0b83 100644 --- a/migrations/2018_03_11_000000_add_user_settings.php +++ b/migrations/2018_03_11_000000_add_user_settings.php @@ -4,7 +4,7 @@ use Illuminate\Database\Schema\Blueprint; use Illuminate\Support\Facades\Schema; -class AddUserSettings extends Migration +return new class extends Migration { /** * Run the migrations. @@ -29,4 +29,4 @@ public function down() $table->dropColumn('settings'); }); } -} +}; diff --git a/migrations/2018_03_14_000000_add_details_to_data_types_table.php b/migrations/2018_03_14_000000_add_details_to_data_types_table.php index 895d4e7781..c62aaeea21 100644 --- a/migrations/2018_03_14_000000_add_details_to_data_types_table.php +++ b/migrations/2018_03_14_000000_add_details_to_data_types_table.php @@ -4,7 +4,7 @@ use Illuminate\Database\Schema\Blueprint; use Illuminate\Support\Facades\Schema; -class AddDetailsToDatatypesTable extends Migration +return new class extends Migration { /** * Run the migrations. @@ -29,4 +29,4 @@ public function down() $table->dropColumn('details'); }); } -} +}; diff --git a/migrations/2018_03_16_000000_make_settings_value_nullable.php b/migrations/2018_03_16_000000_make_settings_value_nullable.php index 1a779558aa..50ee8c42a7 100644 --- a/migrations/2018_03_16_000000_make_settings_value_nullable.php +++ b/migrations/2018_03_16_000000_make_settings_value_nullable.php @@ -5,7 +5,7 @@ use Illuminate\Support\Facades\DB; use Illuminate\Support\Facades\Schema; -class MakeSettingsValueNullable extends Migration +return new class extends Migration { /** * Run the migrations. @@ -32,4 +32,4 @@ public function down() $table->text('value')->nullable(false)->change(); }); } -} +}; diff --git a/resources/views/bread/browse.blade.php b/resources/views/bread/browse.blade.php index 3498a56443..d48d773562 100644 --- a/resources/views/bread/browse.blade.php +++ b/resources/views/bread/browse.blade.php @@ -181,7 +181,11 @@ {{ $data->{$row->field} }} @elseif($row->type == 'text') @include('voyager::multilingual.input-hidden-bread-browse') + @if (!in_array(gettype($data->{$row->field}),['object','array']))