MedicOneSystems / MedicOneSystems/livewire-datatables
Dynamic table name
Nobody has claimed this yet.
- Dominant language
- PHP
- Stars
- 1.2k
- Forks
- 257
- PR merge metrics
- No merged PRs in 30d
Description
Hi, maybe I am doing something wrong but is any solution to use a model with dynamic table name? I use a scope
public function scopeFromTable($query, $tableName)
{
$query->from($tableName);
}
in my model but it won't work with this
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
The issue mentions a model scope named scopeFromTable that calls from($tableName), but it names no repository files or tests. Start by reproducing the reported failure with a model using that scope and trace how table names are handled; done means the supported behavior and its expected constraints are documented or implemented with a reproducible test.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- laravel, php
- Domain
- database
- Issue type
- Feature
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 20/100