|
|
@@ -108,7 +108,7 @@
|
|
|
<span :class="{ 'danger-color': timeConverts(row.lastReportTime).indexOf('秒') == -1 }">{{ row.lastReportTime ? timeConverts(row.lastReportTime) : "未通讯" }}</span>
|
|
|
</template>
|
|
|
<template v-slot:posNum="{ row }">
|
|
|
- <span :class="{ 'danger-color': row.posNum != 0 }">{{row.posNum }}</span>
|
|
|
+ <span :class="{ 'danger-color': row.posNum != 0 }">{{ row.posNum }}</span>
|
|
|
</template>
|
|
|
<template v-slot:updateTime="{ row }">
|
|
|
<span>{{ timeConverts(row.updateTime) }}</span>
|
|
|
@@ -202,10 +202,12 @@ const apiList = ref(window.sessionStorage.getItem("_4L_API_LIST"));
|
|
|
|
|
|
interface PageConfig {
|
|
|
loading: boolean;
|
|
|
+ requestLoading: boolean;
|
|
|
}
|
|
|
|
|
|
let pageConfig: PageConfig = reactive({
|
|
|
loading: false,
|
|
|
+ requestLoading: false,
|
|
|
});
|
|
|
|
|
|
interface FormItem {
|
|
|
@@ -260,10 +262,14 @@ const getPageInfo = (isSearch?: boolean, isRefresh?: boolean) => {
|
|
|
if (isSearch) {
|
|
|
pageParams.pageNum = 1;
|
|
|
selectedKeys.value = [];
|
|
|
+ pageConfig.requestLoading = false;
|
|
|
}
|
|
|
+ if (pageConfig.requestLoading) return;
|
|
|
+ pageConfig.requestLoading = true;
|
|
|
pageConfig.loading = true && !isRefresh;
|
|
|
get_robot_list(pageParams, (data: any) => {
|
|
|
pageConfig.loading = false && !isRefresh;
|
|
|
+ pageConfig.requestLoading = false;
|
|
|
if (data.code == 200) {
|
|
|
dataSource.value = data.data.list;
|
|
|
tablePage.total = data.data.total;
|
|
|
@@ -319,7 +325,7 @@ const handleCopyRobot = async (ids: any) => {
|
|
|
// 批量修改
|
|
|
const handleBatchUpdate = async (ids: any) => {
|
|
|
if (ids.length == 0) return proxy.$message(`请先选择要设置机器!`, 7);
|
|
|
- const botList:any = dataSource.value.filter((item: any) => ids.includes(item.id));
|
|
|
+ const botList: any = dataSource.value.filter((item: any) => ids.includes(item.id));
|
|
|
const strategyProgramId = botList[0].strategyProgramId;
|
|
|
const strategyProgramIdList = botList.filter((item: any) => item.strategyProgramId != strategyProgramId);
|
|
|
if (strategyProgramIdList.length > 0) return proxy.$message(`请先选择同一策略、策略版本机器!`, 7);
|