Weave Code
Weaver
Helps Laravel developers discover, compare, and choose open-source packages. See popularity, security, maintainers, and scores at a glance to make better decisions.
Feedback
Share your thoughts, report bugs, or suggest improvements.
Subject
Message
Has Table Relation

Has Table Relation Laravel Package

shopapps/has-table-relation

Adds a hasTable relation to Laravel Eloquent models, letting you relate to and query any database table without writing a dedicated model class—handy for legacy, lookup, or auxiliary tables. Simple trait-based setup with no migrations required.

View on GitHub
Deep Wiki
Context7

shopapps/has-table-relation adds a HasTableRelation trait to Laravel Eloquent models, allowing relations to be defined against tables whose names are resolved at runtime. Instead of hard-coding a related model class, the trait builds the relationship from a table name stored on the model—ideal for dynamic, per-tenant, or user-defined schemas.

  • Runtime table-name resolution for hasOne/hasMany-style relations
  • Integrates with Eloquent query builder and eager loading
  • Configurable key columns and model resolution
  • Simple drop-in trait with no migrations required
Weaver

How can I help you explore Laravel packages today?

Conversation history is not saved when not logged in.
Prompt
Add packages to context
No packages found.
hotmeteor/eco-env
mvaliolahi/hydrate
wearede/tbcpay-php
parsnick/steak
thibaud-dauce/mattermost-php
multilinguals/apollo-client
antaresbr/collection
kr0lik/phpstan-rules
loco/loco
starfederation/datastar-php
yupmin/modern-phystrix
stephenjude/extended-artisan-commands
lumphp/laravel-macroable
lumphp/laravel-collections
lumphp/laravel-contracts
sermepa/sermepa
arkecosystem/fortify
arkecosystem/ui
owowagency/laravel-resources
gtjamesa/php-standards