Varbase Total Control Dashboard

An enhanced administration dashboard built on Total Control Admin Dashboard, integrating Google Analytics Reports and customizable widgets for an intuitive site management experience.

varbase_total_control
480 sites
40
drupal.org

Install

Drupal 11, 10 v9.1.7
composer require 'drupal/varbase_total_control:^9.1'

Overview

Varbase Total Control Dashboard provides a comprehensive administration dashboard that enhances the Drupal site management experience. Built on top of the Total Control Admin Dashboard module, it leverages Panels for flexible layout management and integrates Google Analytics Reports to display website statistics directly on the dashboard.

The module provides several specialized dashboard blocks including user welcome panels, content creation shortcuts, quick administration links, site content overview with comment counts, and Google Analytics integration showing sessions, pageviews, top pages, and traffic sources. All blocks are fully customizable through the Panels interface.

This module is designed as part of the Varbase distribution but can be used independently with any Drupal installation that meets the dependency requirements.

Features

  • Pre-configured administration dashboard with two-column layout using Panels
  • User welcome block displaying current user information with quick account edit link
  • Create New Content block with configurable content type shortcuts based on user permissions
  • Quick Links block providing shortcuts to menus, taxonomy, and user management
  • My Site Overview block showing content counts and comment statistics per content type with spam detection
  • Google Analytics integration displaying sessions and pageviews over 30 days with C3 charts
  • Top Pages block showing most viewed pages from Google Analytics data
  • Top Sources block displaying traffic source breakdown
  • Module Enabled condition plugin for conditional block visibility based on module installation status
  • Route subscriber ensuring proper permission enforcement for dashboard access
  • Custom templates for consistent dashboard panel styling
  • Automatic permission assignment to site_admin and content_admin roles during installation

Use Cases

Site Administrator Dashboard

Site administrators can access a centralized dashboard at /admin/dashboard to get an at-a-glance view of their site including content counts by type, recent content, and website traffic statistics from Google Analytics. The welcome block provides quick access to account settings.

Content Editor Quick Access

Content editors with the 'have total control' permission can use the Create New Content block to quickly add content of any type they have permission to create, without navigating through the admin menu hierarchy.

Traffic Monitoring

After configuring Google Analytics API authentication, administrators can monitor website traffic directly from the Drupal dashboard without logging into Google Analytics. The Sessions and Pageviews chart shows trends over 30 days, while Top Pages and Top Sources tables identify popular content and traffic sources.

Content Overview and Moderation

The My Site Overview block allows administrators to see content distribution across content types and monitor comment activity including potential spam. Clicking on content type counts links directly to filtered content administration views.

Custom Dashboard Configuration

Site builders can customize the dashboard layout by editing the Panels variant at Admin > Structure > Pages. Blocks can be rearranged, removed, or additional blocks can be added to create a tailored administration experience.

Tips

  • The dashboard can be set as the default admin landing page by configuring user role permissions and redirect rules
  • Block configurations persist independently - customize which content types appear in the Create Content and Site Overview blocks through their respective settings
  • Google Analytics data is cached - allow time for newly configured analytics to populate
  • Use the Module Enabled condition plugin to show/hide blocks based on which modules are installed on your site
  • The dashboard layout uses layout_twocol from Panels - custom layouts can be applied through Page Manager

Technical Details

Admin Pages 1
Dashboard /admin/dashboard

The main administration dashboard providing a comprehensive overview of site content, Google Analytics statistics, and quick access to common administrative tasks. The dashboard uses a two-column Panels layout with customizable blocks.

Permissions 1
Have total control

Grants access to the administration dashboard and all included view pages. This permission is provided by the Total Control module and used by Varbase Total Control Dashboard. Automatically assigned to site_admin and content_admin roles during installation.

Hooks 2
hook_page_attachments

Attaches the varbase_total_control/vtc library CSS to dashboard pages when viewing either of the Total Control Dashboard panel variants.

hook_theme

Registers custom block templates for dashboard blocks including Google Analytics views blocks and Varbase-specific blocks.

Troubleshooting 4
Google Analytics data not displaying on dashboard

Ensure Google Analytics API is authenticated at /admin/config/services/google-analytics-reports-api. You must have administrator permissions on both Google Analytics and the Drupal site to complete authentication.

Dashboard not accessible or 403 error

Verify that your user role has the 'have total control' permission. This permission is automatically assigned to site_admin and content_admin roles during installation but may need manual assignment to other roles.

Charts not rendering

Ensure the C3 and D3 JavaScript libraries are installed in the libraries folder. Install via Composer using the asset-packagist repository or manually download bower-asset/c3 and bower-asset/d3.

Create Content block showing wrong content types

Edit the block configuration through the Panels interface (use the cog wheel on the block or visit Admin > Structure > Pages) to select which content types should display create links.

Security Notes 3
  • The 'have total control' permission grants broad administrative visibility - assign carefully to trusted roles only
  • Google Analytics API credentials should be configured by administrators only and stored securely
  • Content counts and comment data are retrieved via direct database queries - ensure database user permissions are appropriately restricted