protected function setupAuthDriver(Fieldset $fieldset, AuthProviderService $authProviderService, AuthProviderContract $availableAuthDriver)
    {


        $attributes = [
            'id'    => 'api-configuration-' . $availableAuthDriver->getName() . '-driver',
            'class' => 'api-auths'
        ];

        $isEnabled = $authProviderService->isDriverEnabled($availableAuthDriver->getName());

        if ($isEnabled) {
            $attributes['checked'] = 'checked';
        }

        $fieldset->control('input:checkbox', '')
                ->label('<p><b>' . $availableAuthDriver->getLabel() . '</b> - &nbsp;' . $availableAuthDriver->getDescription() . '</p>')
                ->value($availableAuthDriver->getName())
                ->attributes($attributes);
    }
protected function setupAuthDriver(Fieldset $fieldset, AuthProviderService $authProviderService, AuthProviderContract $availableAuthDriver)
    {


        $attributes = [
            'id'    => 'api-configuration-' . $availableAuthDriver->getName() . '-driver',
            'class' => 'api-auths'
        ];

        $isEnabled = $authProviderService->isDriverEnabled($availableAuthDriver->getName());

        if ($isEnabled) {
            $attributes['checked'] = 'checked';
        }

        $fieldset->control('input:checkbox', '')
                ->label('<p><b>' . $availableAuthDriver->getLabel() . '</b> - &nbsp;' . $availableAuthDriver->getDescription() . '</p>')
                ->value($availableAuthDriver->getName())
                ->attributes($attributes);
    }
protected function setupAuthDriver ( Fieldset $ fieldset , AuthProviderService $ authProviderService , AuthProviderContract $ availableAuthDriver ) { $ attributes = [ 'id' => 'api-configuration-' . $ availableAuthDriver -> getName ( ) . '-driver' , 'class' => 'api-auths' ] ; $ isEnabled = $ authProviderService -> isDriverEnabled ( $ availableAuthDriver -> getName ( ) ) ; if ( $ isEnabled ) { $ attributes [ 'checked' ] = 'checked' ; } $ fieldset -> control ( 'input:checkbox' , '' ) -> label ( '<p><b>' . $ availableAuthDriver -> getLabel ( ) . '</b> - &nbsp;' . $ availableAuthDriver -> getDescription ( ) . '</p>' ) -> value ( $ availableAuthDriver -> getName ( ) ) -> attributes ( $ attributes ) ; }
Creates form controls for every api provider

@param Fieldset $fieldset
@param AuthProviderService $authProviderService
@param AuthProviderContract $availableAuthDriver
Creates form controls for every api provider