mirror of
https://github.com/tiennm99/coolify.git
synced 2026-04-19 13:20:51 +00:00
Fix logs not loading for single container services and applications
- Initialize logsLoaded as false to ensure init() triggers log loading - Set logsLoaded=true after calling getLogs() in init() - Allow services/PRs to load logs automatically when expandByDefault=true (single container) - Previously, services would skip initial load unless refresh=true, now single containers work 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <noreply@anthropic.com>
This commit is contained in:
@@ -2,7 +2,7 @@
|
||||
<div id="screen" x-data="{
|
||||
collapsible: {{ $collapsible ? 'true' : 'false' }},
|
||||
expanded: {{ ($expandByDefault || !$collapsible) ? 'true' : 'false' }},
|
||||
logsLoaded: {{ ($expandByDefault || !$collapsible) ? 'true' : 'false' }},
|
||||
logsLoaded: false,
|
||||
fullscreen: false,
|
||||
alwaysScroll: false,
|
||||
intervalId: null,
|
||||
@@ -156,7 +156,10 @@
|
||||
URL.revokeObjectURL(url);
|
||||
},
|
||||
init() {
|
||||
if (this.expanded) { this.$wire.getLogs(); }
|
||||
if (this.expanded) {
|
||||
this.$wire.getLogs();
|
||||
this.logsLoaded = true;
|
||||
}
|
||||
// Re-render logs after Livewire updates
|
||||
Livewire.hook('commit', ({ succeed }) => {
|
||||
succeed(() => {
|
||||
|
||||
Reference in New Issue
Block a user