FilamentF
Filament2y ago
Wim

Use of variables inside a Field

I want to display information inside a Field. I have used a Text Input below because there is no label Field. Ideally I just want to display the plan name into a Form.

Can this be done?

public function form(Form $form): Form {
    $plan = $organisation->getPlan();
    $plan_name= $plan->name; 

    return $form
        ->schema([
            TextInput::make($plan_name)  //this line
              ->label('Name')
          ]);
}
Was this page helpful?