Closed elysiopires closed 5 years ago
Hi @elysiopires,
Create a local versions for CompanyForm.php
and CompanyTable.php
that can extend the ones in laravel-enso/companies
and customize exactly what you need.
For instance since the TemplatePath
constant is protected, you can only override that if you only need a different template.
Then make sure that in the local AppServiceProvider
you add to the bindings prop the local classes
public $bindings = [
CoreCompanyForm::class => CompanyForm::class, //(CompanyForm is the local class)
CoreCompanyTable::class => CompanyTable::class, //(CompanyTable is the local class)
]
Since in the controllers we resolve the builder class from Laravel's service container this should be everything.
Hello @aocneanu !
Worked like a charm!
Thx for your support... You could add this to Enso Documentation!
Thx, Elysio Pires
This is a question...
Prerequisites
Description
I was trying to do the same thing that I did before with a project using enso 3.3.5, replace the people form template and table template too.
On this version, I could only change the config/people.php and change the lines bellow pointing to my custom files:
Since version 3.4.0(people package people 2.2.*) this file goes away... and I saw the version 3.5.0 and still missing... so I checked the change backlog and I found:
So the question is: How can I use my custom form template for people, company or any enso package?
Sincerely, Elysio
Steps to Reproduce
Expected behavior
Use a custom form template on enso.
Actual behavior
Cannot use anymore file config/people.php to set my custom form to people.