Import qqq-bom-pom 4.1.0-RC.21 unconditionally ahead of the parent's BOM and remove the opt-in qqq-snapshot profile and its Sonatype snapshot repository. State the minimum QQQ version as 4.1.0+ in the README. The development revision and the parent are unchanged. Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
4.7 KiB
QBit: Customizable Table Views
QBit Customizable Table Views provides table personalization capabilities for QQQ applications, allowing users to customize which fields and widgets they see based on their roles and permissions.
🚀 What Makes This QBit Different?
Role-Based Table Customization - This QBit enables fine-grained control over table presentation without modifying application code. Users see different fields and widgets based on their assigned roles, providing a personalized experience while maintaining security and data integrity.
🔓 Open Source & Full Control
This QBit is 100% open source - you have complete ownership and control:
User-defined saved views for QQQ dashboard tables.
For: QQQ developers who want users to save and share custom table configurations
Status: Stable
Why This Exists
Different users need different views of the same data. Sales wants to see orders by region. Operations wants orders by status. Each applies different filters, sorts columns differently, and hides irrelevant fields.
This QBit lets users save these configurations as named views. Create a view, adjust columns and filters, save it, and switch between views instantly. Views can be private or shared with the team.
Features
- Saved Views - Store filter, sort, and column configurations
- Column Visibility - Show/hide columns per view
- Column Order - Reorder columns with drag-and-drop
- Filter Presets - Save complex filter combinations
- View Sharing - Share views with roles or all users
- Default Views - Set a view as the default for a table
Quick Start
Prerequisites
- QQQ application (v4.1.0+)
- QQQ dashboard deployed
- Database backend configured
Installation
Add to your pom.xml:
<dependency>
<groupId>com.kingsrook.qbits</groupId>
<artifactId>qbit-customizable-table-views</artifactId>
<version>0.3.0</version>
</dependency>
Register the QBit
public class AppMetaProvider extends QMetaProvider {
@Override
public void configure(QInstance qInstance) {
new CustomizableTableViewsQBit().configure(qInstance);
}
}
Enable for Tables
new QTableMetaData()
.withName("order")
.withCustomViewsEnabled(true);
Usage
Dashboard Experience
Users interact with views through the dashboard:
- Navigate to a table
- Adjust columns, filters, and sorting
- Click "Save View"
- Name the view and set visibility (private/shared)
- Switch views from the dropdown
Programmatic View Creation
new QSavedViewMetaData()
.withName("pendingOrders")
.withTable("order")
.withLabel("Pending Orders")
.withFilter(new QQueryFilter()
.withCriteria("status", Operator.EQUALS, "pending"))
.withColumns("orderNumber", "customerName", "total", "createdDate")
.withSortBy("createdDate", SortOrder.DESC)
.withSharedWithRoles("sales", "operations");
Default Views
Set a view as the default for all users or specific roles:
new QSavedViewMetaData()
.withName("activeCustomers")
.withTable("customer")
.withIsDefault(true)
.withFilter(new QQueryFilter()
.withCriteria("status", Operator.EQUALS, "active"));
View Inheritance
Create views that extend others:
new QSavedViewMetaData()
.withName("myPendingOrders")
.withExtendsView("pendingOrders")
.withAdditionalFilter(new QQueryFilter()
.withCriteria("assignedToUserId", Operator.EQUALS, "${currentUserId}"));
Configuration
The QBit creates these tables:
| Table | Purpose |
|---|---|
saved_view |
View definitions |
saved_view_column |
Column configurations |
saved_view_share |
Sharing permissions |
View Limits
new CustomizableTableViewsQBit()
.withMaxViewsPerUser(50)
.withMaxSharedViewsPerTable(20);
Project Status
Stable and production-ready.
Roadmap
- View folders/categories
- View usage analytics
- Export/import view configurations
Contributing
- Fork the repository
- Create a feature branch
- Run tests:
mvn clean verify - Submit a pull request
License
Proprietary - QRun.IO