abdielcs/expanded-collection-bundle
Symfony 2/3 bundle that renders entity collections as expanded selectable lists (checkboxes). Provides form types extending EntityType, supports OneToMany and ManyToMany relations, configurable displayed fields, and includes a Bootstrap 3 theme example.
FormBuilder) differs significantly from Symfony’s FormComponent, requiring abstraction layers or custom wrappers.EntityType field, which aligns with Laravel’s Eloquent relationships but may necessitate adapter patterns (e.g., converting Symfony’s QueryBuilder to Laravel’s Query builder).FormRequest/FormServiceProvider lacks Symfony’s FormBuilder API, demanding custom form types or middleware to bridge the gap.ContainerInterface) is incompatible with Laravel’s ServiceContainer, requiring facade wrappers or manual instantiation.spatie/laravel-twig).ExpandedEntityType for Laravel’s FormBuilder.QueryBuilder to Laravel’s Query or Builder.ManyToMany relationships) before full adoption.collective/html + custom Blade components for checkbox lists.ManyToMany expanded list) using:
FormBuilder (or Livewire for dynamic forms).QueryBuilder for data fetching.ExpandedCollectionService).// app/Services/ExpandedCollectionService.php
class ExpandedCollectionService {
public function renderCheckboxList($entities, $properties) {
// Custom logic using Laravel's Blade/JS
}
}
FormBuilder → Laravel’s FormBuilder/Livewire.QueryBuilder → Eloquent Query or raw SQL.ManyToMany relationships (most complex in Symfony bundle).OneToMany if simpler alternatives (e.g., nested forms) suffice.bind()) to mock Symfony services during PoC.FormBuilder exceptions) will require cross-framework debugging.QueryBuilder may need optimization for Laravel’s Cursor or Chunk methods.ManyToMany relationships may trigger N+1 queries; use Eloquent’s with() or load() methods.| Risk | Impact | Mitigation |
|---|---|---|
| Symfony API Changes | Wrapper breaks on Laravel upgrade | Use strict version constraints |
| Frontend Rendering Issues | UI breaks in production | Feature flag + A/B testing |
| Query Performance Degradation | Slow admin panels | Benchmark against native Eloquent |
| Team Burnout | High maintenance overhead | Limit scope to critical paths |
Livewire component examples.How can I help you explore Laravel packages today?