PHPackages                             tkuska/dashboard-bundle - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Admin Panels](/categories/admin)
4. /
5. tkuska/dashboard-bundle

ActiveSymfony-bundle[Admin Panels](/categories/admin)

tkuska/dashboard-bundle
=======================

Dashboard bundle, widgets

31065[1 issues](https://github.com/tkuska/dashboard/issues)PHP

Since Mar 2Pushed 5y ago1 watchersCompare

[ Source](https://github.com/tkuska/dashboard)[ Packagist](https://packagist.org/packages/tkuska/dashboard-bundle)[ RSS](/packages/tkuska-dashboard-bundle/feed)WikiDiscussions master Synced 1mo ago

READMEChangelogDependenciesVersions (1)Used By (0)

This bundle provides a dashboard with customizable widgets.

Install
-------

[](#install)

`composer require 2lenet/dashboard-bundle`

Setting up the bundle
---------------------

[](#setting-up-the-bundle)

Add this to services.yaml

```
App\Widgets\:
        resource: '../src/Widgets'
        tags: ['tkuska_dashboard.widget']
```

Add this to routes.yaml

```
dashboard_widgets:
    resource: "@TkuskaDashboardBundle/Resources/config/routes.yaml"
```

You also need to update your database to have widget table.

```
php bin/console make:migration
php bin/console doc:mi:mi

```

Making widgets
--------------

[](#making-widgets)

All your widget classes will lie in src/Widgets/.

They must extend AbstractWidget.

```
use Tkuska\DashboardBundle\Widgets\AbstractWidget;
```

Existing methods that can be overriden:

- \_\_construct: the constructor for usual services injection. You need at least a Twig\_Environment ($twig)
- getName: must return general name of the widget
- getJsonSchema: must return an array (that will be json encoded) that represents an Json Schema, for the widget configuration. (see also )
- getConfigForm: makes the configuration form. You shouldn't need to modify it, but it can happen in some cases (ex: bootstrap version)
- support: returns true if widget is supported. If not, user won't be able to add such widget nor render it
- supportsAjax: returns true if widget should be loaded asynchronously. If not, it will be loaded directly with the dashboard
- transformResponse: takes Response representing the widget as argument and returns response. By default, it caches widgets for 300 seconds.

You *must* implement the render() method.

This method returns simple HTML. You can use $twig-&gt;render("template.html.twig", array(...)). Your templates should extend the base widget template, because it has some interactions. Otherwise, make sure you implement those interactions.

```
{% extends '@TkuskaDashboard/widget/base_widget.html.twig' %}
```

Note that base template uses Bootstrap panels, which means it is better to put your widget body in a ``.

If you use the widget configuration (getJsonSchema) you must pass the form to the template with getConfigForm as 'form'.

This method renders the widget that is shown. All your logic should be in there.

cache
=====

[](#cache)

by default the cache is enable, you can change timeout and key with

```
public function getCacheKey():string{
    return $this->getId() . "_".md5($this->config);
}

public function getCacheTimeout():int {
    return 300;
}
```

above you see the default return.

If you want disable the cache for a widget getCacheTimeout have to return 0.

###  Health Score

19

—

LowBetter than 10% of packages

Maintenance13

Infrequent updates — may be unmaintained

Popularity16

Limited adoption so far

Community15

Small or concentrated contributor base

Maturity30

Early-stage or recently created project

 Bus Factor1

Top contributor holds 57.5% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

### Community

Maintainers

![](https://www.gravatar.com/avatar/91602f399a4f74c700aa530c9d9c25a0f7fdf7fa4f39ab36f35c26e96f52585a?d=identicon)[tkuska](/maintainers/tkuska)

---

Top Contributors

[![SpaghettiBolognaise](https://avatars.githubusercontent.com/u/31731763?v=4)](https://github.com/SpaghettiBolognaise "SpaghettiBolognaise (50 commits)")[![sebheitzmann](https://avatars.githubusercontent.com/u/2197902?v=4)](https://github.com/sebheitzmann "sebheitzmann (26 commits)")[![tkuska](https://avatars.githubusercontent.com/u/1619751?v=4)](https://github.com/tkuska "tkuska (7 commits)")[![QuentinHAETTEL](https://avatars.githubusercontent.com/u/55276836?v=4)](https://github.com/QuentinHAETTEL "QuentinHAETTEL (3 commits)")[![jperat](https://avatars.githubusercontent.com/u/15955170?v=4)](https://github.com/jperat "jperat (1 commits)")

### Embed Badge

![Health badge](/badges/tkuska-dashboard-bundle/health.svg)

```
[![Health](https://phpackages.com/badges/tkuska-dashboard-bundle/health.svg)](https://phpackages.com/packages/tkuska-dashboard-bundle)
```

###  Alternatives

[jeroennoten/laravel-adminlte

Easy AdminLTE integration with Laravel

4.0k4.8M43](/packages/jeroennoten-laravel-adminlte)[dmstr/yii2-adminlte-asset

AdminLTE backend theme asset bundle for Yii 2.0 Framework

1.1k1.8M67](/packages/dmstr-yii2-adminlte-asset)[dwij/laraadmin

LaraAdmin is a Open source Laravel Admin Panel / CMS which can be used as Admin Backend, Data Management Tool or CRM boilerplate for Laravel with features like CRUD Generation, Module Manager, Media, Menus, Backups and much more

1.6k68.7k](/packages/dwij-laraadmin)[filament/spatie-laravel-media-library-plugin

Filament support for `spatie/laravel-medialibrary`.

1764.8M125](/packages/filament-spatie-laravel-media-library-plugin)[bezhansalleh/filament-exceptions

A Simple &amp; Beautiful Pluggable Exception Viewer for FilamentPHP's Admin Panel

193195.9k13](/packages/bezhansalleh-filament-exceptions)[filament/infolists

Easily add beautiful read-only infolists to any Livewire component.

1220.8M36](/packages/filament-infolists)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
