<?php
 namespace Module\Feedback\Admin\Controller; use Illuminate\Routing\Controller; use ModStart\Admin\Concern\HasAdminQuickCRUD; use ModStart\Admin\Layout\AdminCRUDBuilder; use ModStart\Grid\GridFilter; use ModStart\Support\Concern\HasFields; class FeedbackController extends Controller { use HasAdminQuickCRUD; protected function crud(AdminCRUDBuilder $builder) { $builder ->init('feedback') ->field(function ($builder) { $builder->id('id', 'ID'); $builder->datetime('created_at', L('Created At')); $builder->text('contact', '联系方式'); $builder->text('title', '标题'); $builder->textarea('content', '内容'); }) ->gridFilder(function (GridFilter $filter) { $filter->like('title', '标题'); }) ->disableCUD() ->title('意见反馈'); } }