schema([ Forms\Components\TextInput::make('title')->label('标题')->disabled(), Forms\Components\TextInput::make('full_title')->label('完整标题')->disabled(), Forms\Components\TextInput::make('chapter')->label('章节')->disabled(), Forms\Components\TextInput::make('grade')->label('年级')->disabled(), Forms\Components\TextInput::make('term')->label('学期')->disabled(), Forms\Components\Textarea::make('raw_markdown') ->label('卷子原始 Markdown') ->rows(12) ->disabled(), ]); } public static function table(Table $table): Table { return $table ->columns([ Tables\Columns\TextColumn::make('order')->label('顺序')->sortable(), Tables\Columns\TextColumn::make('title')->label('卷标题')->searchable(), Tables\Columns\TextColumn::make('grade')->label('年级'), Tables\Columns\TextColumn::make('term')->label('学期'), Tables\Columns\TextColumn::make('source_type')->label('类型'), ]) ->actions([ ViewAction::make(), ]); } public static function getRelations(): array { return [ PaperPartsRelationManager::class, ]; } public static function getPages(): array { return [ 'index' => Pages\ListSourcePapers::route('/'), 'view' => Pages\ViewSourcePaper::route('/{record}'), ]; } }