fix: 修复工具ps/net资源列表

This commit is contained in:
TsMask
2024-10-11 09:53:13 +08:00
parent 78bcde9ef2
commit eb5fdfb635
4 changed files with 248 additions and 227 deletions

View File

@@ -50,6 +50,9 @@ function wsMessage(res: Record<string, any>) {
if (requestId.startsWith('ps_')) {
// 将数据填入表格
if (Array.isArray(data)) {
if (tableState.loading) {
tableState.loading = false;
}
tableState.data = data;
} else {
tableState.data = [];
@@ -97,10 +100,9 @@ function fnGetList() {
ws.send(msg);
// 定时刷新数据
state.interval = setInterval(() => {
msg.data = state.query;
msg.data = JSON.parse(JSON.stringify(state.query));
ws.send(msg);
}, state.intervalTime);
tableState.loading = false;
}
/**查询参数传入 */
@@ -320,8 +322,6 @@ onBeforeUnmount(() => {
</a-col>
</a-row>
</a-form>
<div>{{ state.query }}</div>
<div>{{ queryParams }}</div>
</a-card>
<a-card :bordered="false" :body-style="{ padding: '0px' }">