Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Sugestion - Show providers config tab #37

Open
lincolnbrito opened this issue May 13, 2017 · 3 comments
Open

Sugestion - Show providers config tab #37

lincolnbrito opened this issue May 13, 2017 · 3 comments

Comments

@lincolnbrito
Copy link

It would be interesting if the provider config tab appears only if the plugin is installed

@tobias-kuendig
Copy link
Member

I like the idea. The settings page got pretty crowded with all the plugin additions lately.

The question is how easy it would be to implement such a feature since to my knowledge you cannot bind the yaml fields to any kind of logic.

@lincolnbrito
Copy link
Author

The Behavior "System.Behaviors.SettingsModel" uses the trait \System\Traits\ConfigMaker that fires the event system.extendConfigFile

            /*
             * Extensibility
             */
            $publicFile = File::localToPublic($configFile);
            if ($results = Event::fire('system.extendConfigFile', [$publicFile, $config])) {
                foreach ($results as $result) {
                    if (!is_array($result)) {
                        continue;
                    }
                    $config = array_merge($config, $result);
                }
            }

I don't test it yet, but maybe we can get the list of supported plugins and listen that event to add plugins in config. I think that is the intent as we can see the comment line.

@damsfx
Copy link
Contributor

damsfx commented Nov 22, 2022

It would be interesting if the provider config tab appears only if the plugin is installed

Done in #124 .

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants