table column dont display value from resource
Dear all, why column with values from table dont show in the column ? 2 hours its works, but something going wrong and i dont know what ... resurce is from user model,
name is displayed, but fullName, email etc. not.
public static function table(Table $table): Table
{
return $table
->columns([
TextColumn::make('name'),
TextColumn::make('fullName'),
TextColumn::make('email'),
Solution:Jump to solution
You have possibly toggled the columns off and removed the toggle code so they are hidden. add ->toggleable() to the columns and then you will see a toggle icon to the right of the top table.
6 Replies
Have you toggled the columns off?
Does the column display at all?
Do the values exist on the model
in the from its works, return $form
->schema([
Forms\Components\TextInput::make('fullName'),
Have you toggled the columns off? - how ?
Does the column display at all? - no column is displayed
Do the values exist on the model - yes values exists
Solution
You have possibly toggled the columns off and removed the toggle code so they are hidden. add ->toggleable() to the columns and then you will see a toggle icon to the right of the top table.
ok now it works, thanks, but how when i dont want to do it without togleable ? visible all time as default ?
You have previously toggled them off, you just need to clear your browser cache and remove togglebale.
Or if you enabled them now, just remove togglable.
Yes i toggled its before, and next remove this option. Acc you advice clear cahce and its works. bor thanks!