class ViewApartment extends Component implements HasForms, HasTable
{
use InteractsWithTable;
use InteractsWithForms;
public function table(Table $table): Table
{
return $table
->query(function (\App\Models\Apartment $record) { \Log::debug($record); return \App\Models\Ownership::where("apartment_name", $record->name); })
->columns([
TextColumn::make('name'),
])
->filters([])
->actions([])
->bulkActions([]);
}
public function render()
{
return view('livewire.view-apartment');
}
}
class ViewApartment extends Component implements HasForms, HasTable
{
use InteractsWithTable;
use InteractsWithForms;
public function table(Table $table): Table
{
return $table
->query(function (\App\Models\Apartment $record) { \Log::debug($record); return \App\Models\Ownership::where("apartment_name", $record->name); })
->columns([
TextColumn::make('name'),
])
->filters([])
->actions([])
->bulkActions([]);
}
public function render()
{
return view('livewire.view-apartment');
}
}