diff --git a/app/Http/Controllers/Users/BulkUsersController.php b/app/Http/Controllers/Users/BulkUsersController.php index fbf08c9820..5541f7a15d 100644 --- a/app/Http/Controllers/Users/BulkUsersController.php +++ b/app/Http/Controllers/Users/BulkUsersController.php @@ -323,7 +323,7 @@ class BulkUsersController extends Controller $logAction->item_type = $itemType; $logAction->target_id = $item->assigned_to; $logAction->target_type = User::class; - $logAction->created_at = auth()->id(); + $logAction->created_by = auth()->id(); $logAction->note = 'Bulk checkin items'; $logAction->logaction('checkin from'); } diff --git a/database/migrations/2023_08_01_174150_change_webhook_settings_variable_type.php b/database/migrations/2023_08_01_174150_change_webhook_settings_variable_type.php index 59c9728e2e..ddce33e903 100644 --- a/database/migrations/2023_08_01_174150_change_webhook_settings_variable_type.php +++ b/database/migrations/2023_08_01_174150_change_webhook_settings_variable_type.php @@ -26,7 +26,7 @@ class ChangeWebhookSettingsVariableType extends Migration public function down() { Schema::table('settings', function (Blueprint $table) { - $table->varchar('webhook_endpoint')->change(); + $table->string('webhook_endpoint')->change(); }); } diff --git a/database/migrations/2024_09_17_204302_change_user_id_to_created_by.php b/database/migrations/2024_09_17_204302_change_user_id_to_created_by.php index a57406ce10..3bef5948b6 100644 --- a/database/migrations/2024_09_17_204302_change_user_id_to_created_by.php +++ b/database/migrations/2024_09_17_204302_change_user_id_to_created_by.php @@ -42,7 +42,7 @@ return new class extends Migration } foreach ($this->existing_table_list() as $table) { - if (Schema::hasColumn($table, 'user_id')) { + if (Schema::hasColumn($table, 'created_by')) { Schema::table($table, function (Blueprint $table) { $table->renameColumn('created_by', 'user_id'); }); diff --git a/resources/views/hardware/bulk-delete.blade.php b/resources/views/hardware/bulk-delete.blade.php index 59ba82ff5c..37977ca1e2 100644 --- a/resources/views/hardware/bulk-delete.blade.php +++ b/resources/views/hardware/bulk-delete.blade.php @@ -43,14 +43,14 @@ {{ $asset->present()->name() }} @if ($asset->location) - {{ $asset->location->name }} + {{ $asset->location->present()->name() }} + @elseif($asset->rtd_location) + {{ $asset->defaultLoc->present()->name() }} @endif - - {{ $asset->assigned_to }} - @if ($asset->assignedTo) - {{ $asset->assignedTo->present()->name()}} + @if ($asset->assigned_to) + {{ $asset->assigned->present()->name() }} @endif