| @@ -1,9 +1,8 @@ | ||
| 1 | 1 | <?php |
| 2 | 2 | |
| 3 | 3 | namespace FluentSupport\App\Http\Controllers; |
| 4 | 4 | |
| 5 | -use FluentSupport\App\Models\Ticket; | |
| 6 | 5 | use FluentSupport\App\Services\FluentBoardsService; |
| 7 | 6 | use FluentSupport\App\Services\Helper; |
| 8 | 7 | use FluentSupport\Framework\Http\Request\Request; |
| 9 | 8 | |
| @@ -63,16 +62,10 @@ | ||
| 63 | 62 | ], 400); |
| 64 | 63 | } |
| 65 | 64 | |
| 66 | 65 | try { |
| 67 | - $sourceId = $request->getSafe('source_id', 'intval'); | |
| 68 | - | |
| 69 | - $ticket = Ticket::findOrFail($sourceId); | |
| 70 | - | |
| 71 | - $this->ensureCanAccessTicket($ticket); | |
| 72 | - | |
| 73 | 66 | $taskData = [ |
| 74 | - 'source_id' => $sourceId, | |
| 67 | + 'source_id' => $request->getSafe('source_id', 'intval'), | |
| 75 | 68 | 'board_id' => $request->getSafe('board_id', 'intval'), |
| 76 | 69 | 'stage_id' => $request->getSafe('stage_id', 'intval'), |
| 77 | 70 | 'crm_contact_id' => $request->getSafe('crm_contact_id', 'intval') ?: null, |
| 78 | 71 | 'title' => $request->getSafe('title', 'sanitize_text_field'), |