mirror of
https://github.com/1Panel-dev/1Panel.git
synced 2025-10-08 22:46:51 +08:00
feat: refreshTask when open task log (#8489)
This commit is contained in:
parent
cad4ee824a
commit
3fc4d9557d
3 changed files with 5 additions and 0 deletions
|
@ -154,6 +154,7 @@ var WebUrlMap = map[string]struct{}{
|
||||||
"/xpack/setting": {},
|
"/xpack/setting": {},
|
||||||
"/xpack/node": {},
|
"/xpack/node": {},
|
||||||
"/xpack/waf/stat": {},
|
"/xpack/waf/stat": {},
|
||||||
|
"/xpack/exchange/file": {},
|
||||||
}
|
}
|
||||||
|
|
||||||
var DynamicRoutes = []string{
|
var DynamicRoutes = []string{
|
||||||
|
|
|
@ -49,6 +49,7 @@ import { searchTasks } from '@/api/modules/log';
|
||||||
import { reactive, ref } from '@vue/runtime-core';
|
import { reactive, ref } from '@vue/runtime-core';
|
||||||
import { Log } from '@/api/interface/log';
|
import { Log } from '@/api/interface/log';
|
||||||
import TaskLog from '@/components/log/task/index.vue';
|
import TaskLog from '@/components/log/task/index.vue';
|
||||||
|
import bus from '@/global/bus';
|
||||||
|
|
||||||
const open = ref(false);
|
const open = ref(false);
|
||||||
const handleClose = () => {
|
const handleClose = () => {
|
||||||
|
@ -72,6 +73,7 @@ const req = reactive({
|
||||||
});
|
});
|
||||||
|
|
||||||
const search = async () => {
|
const search = async () => {
|
||||||
|
bus.emit('refreshTask', true);
|
||||||
req.page = paginationConfig.currentPage;
|
req.page = paginationConfig.currentPage;
|
||||||
req.pageSize = paginationConfig.pageSize;
|
req.pageSize = paginationConfig.pageSize;
|
||||||
loading.value = true;
|
loading.value = true;
|
||||||
|
|
|
@ -51,6 +51,7 @@ import { searchTasks } from '@/api/modules/log';
|
||||||
import { onMounted, reactive, ref } from '@vue/runtime-core';
|
import { onMounted, reactive, ref } from '@vue/runtime-core';
|
||||||
import { Log } from '@/api/interface/log';
|
import { Log } from '@/api/interface/log';
|
||||||
import TaskLog from '@/components/log/task/index.vue';
|
import TaskLog from '@/components/log/task/index.vue';
|
||||||
|
import bus from '@/global/bus';
|
||||||
|
|
||||||
const loading = ref();
|
const loading = ref();
|
||||||
const data = ref();
|
const data = ref();
|
||||||
|
@ -79,6 +80,7 @@ const search = async () => {
|
||||||
paginationConfig.total = res.data.total;
|
paginationConfig.total = res.data.total;
|
||||||
} catch (error) {
|
} catch (error) {
|
||||||
} finally {
|
} finally {
|
||||||
|
bus.emit('refreshTask', true);
|
||||||
loading.value = false;
|
loading.value = false;
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
Loading…
Add table
Reference in a new issue