📜  yajra laravel datatables rawcolumn - PHP 代码示例

📅  最后修改于: 2022-03-11 14:54:09.705000             🧑  作者: Mango

代码示例1
use DataTables;

Route::get('user-data', function() {
    $model = App\User::query();

    return DataTables::eloquent($model)
                ->addColumn('link', 'Html Column')
                ->addColumn('action', 'path.to.view')
                ->rawColumns(['link', 'action'])
                ->toJson();
});