[Bug]: flatfile_documentations create table issue
Closed this issue · 4 comments
What happened?
It happens after I install the plugin to my filament.
"php": "^8.1",
"blade-ui-kit/blade-icons": "^1.5",
"doctrine/dbal": "^3.7",
"eightynine/filament-excel-import": "^3.0",
"filament/filament": "^3.2-stable",
"guava/filament-knowledge-base": "^1.9",
"guzzlehttp/guzzle": "^7.2",
"laravel/framework": "^10.10",
"laravel/horizon": "^5.22",
"laravel/octane": "^2.0",
"laravel/sanctum": "^3.2",
"laravel/tinker": "^2.8",
"livewire/livewire": "^3.0@beta",
"pxlrbt/filament-excel": "^2.3",
"sentry/sentry-laravel": "^3.6",
"spatie/laravel-activitylog": "^4.7",
"spatie/laravel-data": "^3.6",
"spatie/laravel-google-cloud-storage": "^2.3",
"spatie/laravel-permission": "^5.10",
"tapp/filament-timezone-field": "^3.0"
How to reproduce the bug
It happens after I install the plugin to my filament.
Illuminate
\
Database
\
QueryException
PHP 8.2.12
10.48.18
SQLSTATE[HY000]: General error: 1 near ")": syntax error
CREATE TABLE "flatfile_documentations" ()
@component($layout->view, $layout->params)
@slot($layout->slotOrSection)
{!! $content !!}
@endslot
<?php
// Manually forward slots defined in the Livewire template into the layout component...
foreach ($layout->viewContext->slots[-1] ?? [] as $name => $slot) {
$__env->slot($name, attributes: $slot->attributes->getAttributes());
echo $slot->toHtml();
$__env->endSlot();
}
?>
@endcomponent
Package Version
1.9.2
PHP Version
8.1
Laravel Version
10.10
Which operating systems does with happen with?
macOS
Notes
No response
I just resolved the issue by modifying the actual vendor file by adding a protected $schema function .
protected $schema = [
'id' => 'string',
'slug' => 'string',
'path' => 'string',
'content' => 'text',
'title' => 'string',
'group' => 'string',
'icon' => 'string',
'parent' => 'string',
'order' => 'integer',
];
Thanks for the info. I haven't tested it with L10, maybe Laravel or Sushi behaves differently there, since it seems to work in L11 without the schema array.
I'll check and add it if necessary in the next release.
Thanks.
Thanks for the info. I haven't tested it with L10, maybe Laravel or Sushi behaves differently there, since it seems to work in L11 without the schema array.
I'll check and add it if necessary in the next release.
I get the same error on fresh install with laravel 11