Open tiborsaas opened 9 years ago
There is an example repo.
Thanks. Do you have any idea what I'm not getting?
@BcTpe4HbIu example repo doesn't work with the admin/pass provided.
@sleeping-owl the only one who can help with this.
@sleeping-owl can you please provide some info on my question?
Hi! You need to create a model in the folder App\Models. Then you need to create a model in the folder App\Admin\Models and past this code:
Admin::model(\App\Models\Faculty::class)->title('Факультеты')->display(function ()
{
$display = AdminDisplay::datatables();
$display->columns([
Column::string('name')->label('Наименование'),
]);
return $display;
})->createAndEdit(function ()
{
$form = AdminForm::form();
$form->items([
FormItem::text('name', 'Наименование')->required(),
]);
return $form;
});
Hello,
I've just installed Sleeping Owl and after reading the docs, I'm still confused how to connect models to menu items. I assume if I create a model configuration like this
Add this to
menu.php
Then it would generate a list for me.
TestModel.php
looks like this:Also, where can I check out a working example?