企业🤖AI智能体构建引擎,智能编排和调试,一键部署,支持知识库和私有化部署方案 广告
\App\Http\Controllers\TargetController ``` <?php namespace App\Http\Controllers; use Illuminate\Http\Request; use \App\Target; class TargetController extends Controller { public function index() { // return view("index"); $targets = Target::orderBy('ranking', 'desc')->orderBy('created_at', 'desc')->paginate(10); return view("index", compact('targets')); } public function create() { $targets = Target::orderBy('ranking', 'desc')->orderBy('created_at', 'desc')->paginate(10); return view("create", compact('targets')); } public function edit() { $targets = Target::orderBy('ranking', 'desc')->orderBy('created_at', 'desc')->paginate(10); return view("edit", compact('targets')); } } ```