Define Settings-Views inside a package>capsule

Is there a way to configure a settings related view inside a package capsule? I couldn't find something about that one. For example a "registerSettingsViewPath" or a property/method returning an explicit view for the related settings.
C
_crp87337d ago
The problem is AppSetting class which has this code:
public function getFormBlocks(): array
{
$directory = resource_path('views/twill/settings/' . $this->getSettingGroup()->getName());
public function getFormBlocks(): array
{
$directory = resource_path('views/twill/settings/' . $this->getSettingGroup()->getName());
means, there is no way to use a settings view from within a package>capsule. @ifox.dev I would suggest to read the path from a separate method like getSettingsDir which can be updated by a static setter for example: useSettingsDir(string $directory) or even better: addSettingsDir(string $directory) So fallback would be to read settings classes from resource path but every package can add its own paths to read additional settings from alternative could be a config to read the path(s) from which can be extended through package service providers
I
ifox336d ago
yes, that makes sense thanks for submitting an issue
Want results from more Discord servers?
Add your server
More Posts
DatePicker not updating or incorrectly updating fieldHaving a weird issue with the DatePicker field which seems to have popped up in the last few weeks ofileparams in ModelIs there any documentation on fileparams. For instance how to add file types parameter to itThird Level CategoriesHow do we set our model to cater a third level category or parent->child->child? Currently it only cSelect FieldHi, is there a way to search an item in a select block? Just like autocompleteHow to create multiple navigations with multiple levels based on the navigation GuideFollowing the Guide at https://twillcms.com/guides/page-builder-with-blade/adding-navigation.html itadding a custom link in the dashboardIs there any way to add a link to a custom page in the dashboard? like adding the link in dashbord.m->getRelated for menu didnt work.I follow this manual https://twillcms.com/guides/page-builder-with-blade/adding-navigation.html I doTwill + Spatie permissionsHow would someone go about implementing spatie permissions in Twill. The spatie permissions are pretv3 package resources / blade templatesI created a fresh v3 package but inside the documentation I can’t find a description on how to add bv3 Package creation - version mismatchHey, I started installing twill 3 n a fresh Jetstream based laravel App. I could also create my firHi, do you know where I can add another link?Aligned with All Items, Published, Draft and Trashed. I just want to add new linkTwill advanced permissionsI've followed the documentation with regard to adding the enabled and permission key to config/twill