mirror of
https://github.com/1Panel-dev/1Panel.git
synced 2025-10-18 11:26:10 +08:00
parent
7f7465b383
commit
a4ee16cf1f
3 changed files with 8 additions and 2 deletions
|
@ -701,7 +701,7 @@ func (u *ContainerService) ContainerLogs(wsConn *websocket.Conn, containerType,
|
|||
return
|
||||
}
|
||||
global.LOG.Errorf("read bytes from log failed, err: %v", err)
|
||||
continue
|
||||
return
|
||||
}
|
||||
if !utf8.Valid(buffer[:n]) {
|
||||
continue
|
||||
|
|
|
@ -53,7 +53,7 @@
|
|||
<script lang="ts" setup>
|
||||
import i18n from '@/lang';
|
||||
import { dateFormatForName, downloadWithContent } from '@/utils/util';
|
||||
import { computed, reactive, ref, shallowRef, watch } from 'vue';
|
||||
import { computed, onBeforeUnmount, reactive, ref, shallowRef, watch } from 'vue';
|
||||
import { Codemirror } from 'vue-codemirror';
|
||||
import { javascript } from '@codemirror/lang-javascript';
|
||||
import { oneDark } from '@codemirror/theme-one-dark';
|
||||
|
@ -128,6 +128,7 @@ const searchLogs = async () => {
|
|||
MsgError(i18n.global.t('container.linesHelper'));
|
||||
return;
|
||||
}
|
||||
terminalSocket.value?.send('close conn');
|
||||
terminalSocket.value?.close();
|
||||
logInfo.value = '';
|
||||
const href = window.location.href;
|
||||
|
@ -180,6 +181,10 @@ const acceptParams = (props: DialogProps): void => {
|
|||
}
|
||||
};
|
||||
|
||||
onBeforeUnmount(() => {
|
||||
handleClose();
|
||||
});
|
||||
|
||||
defineExpose({
|
||||
acceptParams,
|
||||
});
|
||||
|
|
|
@ -102,6 +102,7 @@ const searchLogs = async () => {
|
|||
MsgError(i18n.global.t('container.linesHelper'));
|
||||
return;
|
||||
}
|
||||
terminalSocket.value?.send('close conn');
|
||||
terminalSocket.value?.close();
|
||||
logInfo.value = '';
|
||||
const href = window.location.href;
|
||||
|
|
Loading…
Add table
Reference in a new issue