mirror of
https://github.com/tiennm99/coolify.git
synced 2026-10-03 05:19:37 +00:00
fix: always have download logs button on scheduled tasks
This commit is contained in:
1 parent
96f95f2ae5
commit
664b718ea3
2 files changed
+17
-8
No files matched your search
@@ -120,11 +120,16 @@ class Executions extends Component
|
||||
return $lines->take($this->currentPage * $this->logsPerPage);
|
||||
}
|
||||
|
||||
public function downloadLogs()
|
||||
public function downloadLogs(int $executionId)
|
||||
{
|
||||
return response()->streamDownload(function () {
|
||||
echo $this->selectedExecution->message;
|
||||
}, 'task-execution-'.$this->selectedExecution->id.'.log');
|
||||
$execution = $this->executions->firstWhere('id', $executionId);
|
||||
if (! $execution) {
|
||||
return;
|
||||
}
|
||||
|
||||
return response()->streamDownload(function () use ($execution) {
|
||||
echo $execution->message;
|
||||
}, 'task-execution-'.$execution->id.'.log');
|
||||
}
|
||||
|
||||
public function hasMoreLogs()
|
||||
|
||||
Reference in new issue
Block a user