title; } public function handle(Request $request) { try { $id = $this->getKey(); // 查找原始记录 $original = FarmSeedOutput::findOrFail($id); // 创建新记录 $new = $original->replicate(); $new->save(); return $this->response() ->success("复制成功 [ID: {$new->id}]") ->refresh(); } catch (\Exception $e) { return $this->response() ->error('复制失败: '.$e->getMessage()); } } public function confirm() { return ['确定要复制此种子产出配置吗?', '复制操作将创建一个新的种子产出配置记录']; } }