fix more modcomment

This commit is contained in:
xiaomlove
2025-02-06 22:32:36 +08:00
parent 076aeeb576
commit fd12d463b7
14 changed files with 179 additions and 31 deletions

View File

@@ -41,6 +41,12 @@ class IconResource extends Resource
{
return $form
->schema([
Forms\Components\Textarea::make('tip')
->default(nexus_trans('label.icon.desc'))
->disabled()
->columnSpanFull()
->rows(18)
,
Forms\Components\TextInput::make('name')
->label(__('label.name'))
->required()

View File

@@ -8,7 +8,7 @@ use Filament\Resources\Pages\CreateRecord;
class CreateIcon extends CreateRecord
{
protected static string $view = 'filament.resources.system.category-icon-resource.pages.create-record';
// protected static string $view = 'filament.resources.system.category-icon-resource.pages.create-record';
protected static string $resource = IconResource::class;

View File

@@ -13,7 +13,7 @@ class EditIcon extends EditRecord
protected static string $resource = IconResource::class;
protected static string $view = 'filament.resources.system.category-icon-resource.pages.edit-record';
// protected static string $view = 'filament.resources.system.category-icon-resource.pages.edit-record';
protected function getHeaderActions(): array
{
@@ -22,6 +22,12 @@ class EditIcon extends EditRecord
];
}
protected function mutateFormDataBeforeFill(array $data): array
{
$data['tip'] = nexus_trans('label.icon.desc');
return $data;
}
protected function getViewData(): array
{
return [