© 2026 Hedgehog Software, LLC

TwitterGitHubDiscord
More
CommunitiesDocsAboutTermsPrivacy
Search
Star
Setup for Free
FilamentF
Filament•16mo ago•
1 reply
Xavi

Polling step wizard

I'm making a wizard to connect to Google Analytics, and the first step contains the connect button. The authorization screen to obtain the analytics accounts opens, and what I want is that when I close this screen, I want to automatically go to step 2, which is a select to select which analytics account will be used, and for this I have thought about the first step having a poll. Is this possible?

I attach steps image, and this is the code

Tables\Actions\Action::make('connect_analytics')
  ->icon('heroicon-o-chart-bar')
  ->label(__('Conectar Google Analytics'))
  ->steps([
      Step::make('step1')
          ->label(__('Paso 1'))
          ->description(__('Conecta tu cuenta de Google Analytics'))
          ->schema([
              Actions::make([
                  Action::make('actionName')
                      ->label(__('Conectar'))
                      ->size('xl')
                      ->extraAttributes([
                          'class' => 'm-0 auto',
                      ])
                      ->action(function (Media $record, $livewire) {
                          $url = route('google.auth.redirect', $record);
                          $livewire->js("window.open('$url', '_blank', 'popup=yes', 'width=350', 'height=250').focus();");
                      })
                  //->openUrlInNewTab()
                  //->url(fn(Media $record) => route('google.auth.redirect', $record))
              ]),
          ]),
      Step::make('step2')
          ->label(__('Paso 2'))
          ->description(__('Selecciona la cuenta de Google Analytics'))
          ->visible(fn(Media $record) => $record->analyticsAccount)
          ->schema([
              Select::make('analyticsAccount.account_selected')
                  ->options(function (Media $record) {
                      return Arr::pluck($record->analyticsAccount->accounts, 'name', 'account_id');
                  })
          ]),
  ])
Tables\Actions\Action::make('connect_analytics')
  ->icon('heroicon-o-chart-bar')
  ->label(__('Conectar Google Analytics'))
  ->steps([
      Step::make('step1')
          ->label(__('Paso 1'))
          ->description(__('Conecta tu cuenta de Google Analytics'))
          ->schema([
              Actions::make([
                  Action::make('actionName')
                      ->label(__('Conectar'))
                      ->size('xl')
                      ->extraAttributes([
                          'class' => 'm-0 auto',
                      ])
                      ->action(function (Media $record, $livewire) {
                          $url = route('google.auth.redirect', $record);
                          $livewire->js("window.open('$url', '_blank', 'popup=yes', 'width=350', 'height=250').focus();");
                      })
                  //->openUrlInNewTab()
                  //->url(fn(Media $record) => route('google.auth.redirect', $record))
              ]),
          ]),
      Step::make('step2')
          ->label(__('Paso 2'))
          ->description(__('Selecciona la cuenta de Google Analytics'))
          ->visible(fn(Media $record) => $record->analyticsAccount)
          ->schema([
              Select::make('analyticsAccount.account_selected')
                  ->options(function (Media $record) {
                      return Arr::pluck($record->analyticsAccount->accounts, 'name', 'account_id');
                  })
          ]),
  ])


Thanks!
Filament banner
FilamentJoin
A powerful open source UI framework for Laravel • Build and ship admin panels & apps fast with Livewire
20,307Members
Resources
Was this page helpful?

Similar Threads

Recent Announcements

Similar Threads

wizard step label
FilamentFFilament / ❓┊help
8mo ago
Completed Wizard step
FilamentFFilament / ❓┊help
2y ago
Wizard step validation
FilamentFFilament / ❓┊help
2y ago
Dynamic Wizard Step
FilamentFFilament / ❓┊help
3y ago