https://github.com/filaforge/database-viewer
https://github.com/filaforge/database-viewer
Last synced: 9 months ago
JSON representation
- Host: GitHub
- URL: https://github.com/filaforge/database-viewer
- Owner: filaforge
- License: mit
- Created: 2025-08-13T08:35:20.000Z (11 months ago)
- Default Branch: main
- Last Pushed: 2025-08-13T09:31:58.000Z (11 months ago)
- Last Synced: 2025-08-13T10:32:51.810Z (11 months ago)
- Language: PHP
- Size: 21.5 KB
- Stars: 0
- Watchers: 0
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- Changelog: CHANGELOG.md
- Contributing: CONTRIBUTING.md
- License: LICENSE
- Code of conduct: CODE_OF_CONDUCT.md
Awesome Lists containing this project
README
# Filaforge Database Viewer
A Filament v4 panel plugin that provides a database browser and data## Usage
After installation and registration, you'll find the "Database Viewer" page in your Filament panel navigation. The page provides:
- **Table Browser**: View all database tables with metadata
- **Schema Inspector**: Examine table structure, columns, and relationships
- **Data Preview**: Browse table records with pagination
- **Search & Filter**: Find specific records quickly
- **Column Details**: View data types, constraints, and indexes
- **Relationship Mapping**: Visualize foreign key relationships
Navigate to your Filament panel and look for "Database Viewer" in the sidebar to start exploring your database structure and data.
## Configuration
The plugin works with your default database connection. You can customize the viewer behavior by publishing the configuration:
```bash
php artisan vendor:publish --tag="database-viewer-config"
```
This will create a `config/database-viewer.php` file where you can modify display options and access controls.
## Security Notes
- **Read-Only Access**: The viewer provides read-only access to your database
- **Permission Integration**: Works with Filament's built-in authorization system
- **Safe Exploration**: No data modification capabilities
## Features
- ✅ Browse all database tables and views
- ✅ Inspect table schemas and relationships
- ✅ Preview table data with pagination
- ✅ Search and filter capabilities
- ✅ Column metadata display
- ✅ Foreign key relationship visualization
- ✅ Responsive design matching Filament's theme
---
**Package**: `filaforge/database-viewer`
**License**: MIT
**Requirements**: PHP ^8.1, Laravel ^12, Filament ^4.0for quick inspection of tables and records.

## Requirements
- PHP >= 8.1
- Laravel 12 (illuminate/support ^12)
- Filament ^4.0
## Installation
### Step 1: Install via Composer
```bash
composer require filaforge/database-viewer
```
### Publish (optional)
```bash
php artisan vendor:publish --provider="Filaforge\\DatabaseViewer\\Providers\\DatabaseViewerServiceProvider"
```
### Step 2: Service Provider Registration
The service provider is auto-discovered, so no manual registration is required.
### Step 3: Register the Plugin in Your Panel
Add the plugin to your Filament panel configuration in `app/Providers/Filament/AdminPanelProvider.php` (or your custom panel provider):
```php
default()
->id('admin')
->path('admin')
->login()
->colors([
'primary' => Color::Amber,
])
->discoverResources(in: app_path('Filament/Resources'), for: 'App\\Filament\\Resources')
->discoverPages(in: app_path('Filament/Pages'), for: 'App\\Filament\\Pages')
->pages([
Pages\Dashboard::class,
])
->discoverWidgets(in: app_path('Filament/Widgets'), for: 'App\\Filament\\Widgets')
->widgets([
Widgets\AccountWidget::class,
Widgets\FilamentInfoWidget::class,
])
->middleware([
EncryptCookies::class,
AddQueuedCookiesToResponse::class,
StartSession::class,
AuthenticateSession::class,
ShareErrorsFromSession::class,
VerifyCsrfToken::class,
SubstituteBindings::class,
DisableBladeIconComponents::class,
DispatchServingFilamentEvent::class,
])
->authMiddleware([
Authenticate::class,
])
// Add the plugin here
->plugin(DatabaseViewerPlugin::make());
}
}
```
### Step 4: Clear Cache and Discover Assets
```bash
php artisan config:clear
php artisan route:clear
php artisan view:clear
```
## Usage
Navigate to the “Database Viewer” page. Select a table to browse columns and preview data.
---
Package: `filaforge/database-viewer`## Filaforge Database Viewer
Browse tables and explore data from a Filament page.
Usage:
```php
->plugin(\Filaforge\DatabaseViewer\DatabaseViewerPlugin::make())
```
The page appears as "Database Viewer" in the admin navigation.