Download the PHP package parabellumkoval/backpack-settings without Composer
On this page you can find all versions of the php package parabellumkoval/backpack-settings. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Download parabellumkoval/backpack-settings
More information about parabellumkoval/backpack-settings
Files in parabellumkoval/backpack-settings
Package backpack-settings
Short Description Settings UI & Service for Laravel 8 + Backpack 4.1 (config/DB drivers, tabs, registry, aliases).
License MIT
Informations about the package backpack-settings
parabellumkoval/backpack-settings
Settings UI & Service for Laravel 8 + Backpack 4.1.
- Use base Backpack fields and add custom fields.
- Define settings via a Class Registrar (separate from providers).
- Tabs support per page (and per field via
tab()). - DB + Config drivers, with DB override.
- Simple facade:
Settings::get('some.key')/Settings::set(...).
Install
Register your settings via Class Registrar
Create a class in your package/app, e.g. App\Settings\StoreSettingsRegistrar.php:
Then reference it in config/backpack-settings.php:
Alternatively, in your package service provider: resolve and call your registrar manually
(still keeps your settings definition in a dedicated class).
Admin UI
Visit: /admin/settings/store
- The page is split into tabs by pages (Общее, Оплата).
- Inside a page, you can further segment fields by setting
->tab('...').
Access values in code
Add custom fields
Put blade views under resources/views/vendor/backpack-settings/fields/yourtype.blade.php
or ship them within this package's resources/views/fields.
Then, in your registrar, use Field::make('key', 'yourtype').
Locale & Region aware settings
Settings can now be scoped by locale (language) and/or region.
- Mark a field as locale-specific with
->translatable(true). - Mark a field as region-specific with
->regionable(true). - Combine both for values that depend on country and language.
The admin UI shows switchers for the configured locales/regions, so editors can toggle between variations. Values are stored per combination and fall back automatically: region + locale → region → locale → default.
Expose available options via config/backpack-settings.php:
The public API endpoints automatically respect the context:
GET /api/settings/nested?country=dewill prefer region-specific values.- The
Accept-Languageheader (or explicit?locale=) drives the locale fallback chain.
License
MIT