whitecube / nova-page

Static pages content management for Laravel Nova
https://whitecube.github.io/nova-page
MIT License
238 stars 41 forks source link

Update docs to registering options #54

Closed f-liva closed 4 years ago

f-liva commented 4 years ago

From AppServiceProvider

$pages->registerOption('general', GeneralOptions::class); don't works $pages->register('option', 'general', GeneralOptions::class); it works

voidgraphics commented 4 years ago

Took me a while but I finally got to it. Thank you very much for the report.

techguydev commented 4 years ago

How can we access this page information in a controller?, I need to use a select field to set the currency in the system.

voidgraphics commented 4 years ago

You can use the Page facade: https://whitecube.github.io/nova-page/#/?id=useful-facade-methods

More specifically the Page::option() method.

voidgraphics commented 4 years ago

You can use the Page facade: https://whitecube.github.io/nova-page/#/?id=useful-facade-methods

More specifically the Page::option() method.

voidgraphics commented 4 years ago

You can use the Page facade: https://whitecube.github.io/nova-page/#/?id=useful-facade-methods

More specifically the Page::option() method.

techguydev commented 4 years ago

Thanks

I tried to use it but it shows an error:

"Class 'Page' not found"

voidgraphics commented 4 years ago
use \Page;

// or

use Whitecube\NovaPage\NovaPageFacade as Page;