- How do I install promethys/revive in a Laravel application?
- Run composer require promethys/revive followed by php artisan revive:install, which publishes and runs the package migrations. The active V3 line requires PHP 8.2+, Laravel 11+ and Filament v5. Re-running the install command is safe and will not duplicate migrations, provided spatie/laravel-package-tools is at version 1.93.1 or higher. If you prefer manual control, publish the migrations with vendor:publish --tag=revive-migrations and run php artisan migrate yourself.
- Which Filament and Laravel versions does Revive support?
- Revive tracks three Filament majors across three package versions. V3.x is the active line for Filament v5 on PHP 8.2+ and Laravel 11+, V2.x is in maintenance mode for Filament v4, and V1.x targets Filament v3 with critical bug fixes only. Pin the matching constraint: promethys/revive:^3.0, ^2.0 or ^1.0. Because the package release cadence follows Filament's, budget for a breaking upgrade whenever a new Filament major ships.
- How do I make an Eloquent model show up in the Recycle Bin?
- Add the Recyclable trait to any model that already uses Laravel's SoftDeletes trait, and the model becomes visible on the Recycle Bin page. No base model changes or event listeners are required beyond the trait. If your schema does not match the package defaults, override getDeletedByUser() and getTenantId() on the model so Revive can attribute each deleted record correctly.
- Does Revive support multi-tenancy and per-user scoping?
- Yes, user and tenant scoping were introduced in V2 and are available in V3. The plugin exposes enableUserScoping(), enableTenantScoping(), showAllRecords() and an authorize() closure so you can control who sees which trashed records. User scoping is enabled by default, so misconfiguration is the main way to leak another tenant's deleted data. Map your tenancy columns onto the getTenantId() and getDeletedByUser() overrides before going live.
- What are state snapshots and do they increase database size?
- State snapshots store a copy of the model's data at the moment of deletion, which is useful for auditing and for showing context in the Recycle Bin listing. The trade-off is duplicated row data, so storage growth and PII retention need an explicit policy. Decide how long snapshots are kept and purge them alongside permanent deletes to stay compliant with your data-retention rules.
- Can Revive find records that were soft-deleted before I installed it?
- Yes. The package ships an artisan command, php artisan revive:discover-soft-deleted, that scans your registered recyclable models for existing trashed rows and backfills them into the Recycle Bin. Run it once after installation and again after registering new models. On large tables, run it in a queue worker or off-peak window because it queries every registered model.
- How do I register the Revive plugin on a Filament panel?
- Call RevivePlugin::make() inside the panel configuration in your panel provider, for example AdminPanelProvider. From there you configure the scoping posture: enableUserScoping() for customer-facing panels, or showAllRecords() plus an authorize() closure for admin panels. If you run several panels, register the plugin in each one with the appropriate configuration.
- Can I use Revive without the Filament page?
- You can embed the underlying Livewire component in a Blade view with @livewire(\Promethys\Revive\Tables\RecycleBin::class), but the package is designed as a Filament panel plugin. Without the Filament page chrome you lose the navigation entry, filters and layout integration, so the value proposition weakens considerably. If your admin surface is not Filament-based, evaluate a simpler Laravel-only recycle bin instead.
- Is promethys/revive safe to use in production and what are the risks?
- It is a low-signal dependency: a small star count, few dependents and a single maintainer namespace, with an MIT licence but unproven long-term patch velocity. The main technical risks are version-lock churn against Filament majors and bus-factor exposure if the maintainer stops publishing. Mitigate by pinning the constraint, locking the composer version, and keeping a fork or manual migration path as an escape hatch.
- Does Revive's permanent delete satisfy GDPR erasure requests?
- Force-deleting from the Recycle Bin removes the soft-deleted record, but any state snapshots captured at deletion time may still hold personal data. You need a retention policy that also purges snapshots and a documented process for handling erasure requests end to end. If you have hard audit or compliance obligations, verify that permanent delete plus snapshot purging meets them before adopting the package.