- upload recording of call in chunks - recordings are merged on server side in jobs - improve UI of the recording tab
39 lines
902 B
PHP
39 lines
902 B
PHP
<?php
|
|
|
|
namespace App\Actions\Interview;
|
|
|
|
use App\Jobs\MergeRecordingChunksJob;
|
|
use App\Models\Interview;
|
|
|
|
class FinalizeRecordingAction
|
|
{
|
|
/**
|
|
* Finalize the recording session by dispatching the background merge job.
|
|
*
|
|
* @param Interview $interview
|
|
* @param string $sessionId
|
|
* @param int $totalChunks
|
|
* @param string|null $tempDir
|
|
* @param string|null $folderName
|
|
* @param int|null $duration
|
|
* @return void
|
|
*/
|
|
public function execute(
|
|
Interview $interview,
|
|
string $sessionId,
|
|
int $totalChunks = 0,
|
|
?string $tempDir = null,
|
|
?string $folderName = null,
|
|
?int $duration = null
|
|
): void {
|
|
MergeRecordingChunksJob::dispatch(
|
|
$interview->id,
|
|
$sessionId,
|
|
$tempDir,
|
|
$folderName,
|
|
$totalChunks,
|
|
$duration
|
|
);
|
|
}
|
|
}
|