This commit is contained in:
Tokumeikoi 2020-04-07 00:40:52 +08:00
parent e73cbe9597
commit 7c69e19304

View File

@ -51,6 +51,9 @@ class TicketController extends Controller
public function save(TicketSave $request)
{
DB::beginTransaction();
if ((int)Ticket::where('status', 0)->count()) {
abort(500, '存在其他工单尚未处理');
}
$ticket = Ticket::create(array_merge($request->only([
'subject',
'level'