style: 调整数据统计方位、增加确认框
调整接口数量统计、接口用力数量统计的不同接口数量统计显示区域的位置;在关闭定时任务时增加确认框防止误操作
This commit is contained in:
parent
642de28841
commit
f905aa62cb
|
@ -18,7 +18,22 @@
|
|||
</el-aside>
|
||||
<el-main style="padding-left: 0px;padding-right: 0px;">
|
||||
<div style="width: 200px;margin:0 auto">
|
||||
<el-row align="center">
|
||||
|
||||
<el-row align="center" class="hidden-lg-and-down">
|
||||
<el-col :span="6" style="padding: 5px;border-right-style: solid;border-right-width: 1px;border-right-color: #ECEEF4;">
|
||||
<div class="count-info-div" v-html="apiCountData.httpCountStr"></div>
|
||||
</el-col>
|
||||
<el-col :span="6" style="padding: 5px;border-right-style: solid;border-right-width: 1px;border-right-color: #ECEEF4;">
|
||||
<div class="count-info-div" v-html="apiCountData.rpcCountStr"></div>
|
||||
</el-col>
|
||||
<el-col :span="6" style="padding: 5px;border-right-style: solid;border-right-width: 1px;border-right-color: #ECEEF4;">
|
||||
<div class="count-info-div" v-html="apiCountData.tcpCountStr"></div>
|
||||
</el-col>
|
||||
<el-col :span="6" style="padding: 5px;">
|
||||
<div class="count-info-div" v-html="apiCountData.sqlCountStr"></div>
|
||||
</el-col>
|
||||
</el-row>
|
||||
<el-row align="right" style="margin-left: 20px" class="hidden-xl-only">
|
||||
<el-col :span="6" style="padding: 5px;border-right-style: solid;border-right-width: 1px;border-right-color: #ECEEF4;">
|
||||
<div class="count-info-div" v-html="apiCountData.httpCountStr"></div>
|
||||
</el-col>
|
||||
|
|
|
@ -11,8 +11,16 @@
|
|||
<el-table-column prop="rule" :label="$t('api_test.home_page.running_task_list.table_coloum.run_rule')" width="120" show-overflow-tooltip/>
|
||||
<el-table-column width="100" :label="$t('api_test.home_page.running_task_list.table_coloum.task_status')">
|
||||
<template v-slot:default="scope">
|
||||
<el-switch @click.stop.native v-model="scope.row.taskStatus" @change="updateTask(scope.row)"/>
|
||||
<div>
|
||||
<el-switch
|
||||
v-model="scope.row.taskStatus"
|
||||
class="captcha-img"
|
||||
@click.native="closeTaskConfirm(scope.row)"
|
||||
></el-switch>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
|
||||
</el-table-column>
|
||||
<el-table-column width="170" :label="$t('api_test.home_page.running_task_list.table_coloum.next_execution_time')">
|
||||
<template v-slot:default="scope">
|
||||
|
@ -41,6 +49,7 @@ export default {
|
|||
value: '100',
|
||||
result: {},
|
||||
tableData: [],
|
||||
visible: false,
|
||||
loading: false
|
||||
}
|
||||
},
|
||||
|
@ -53,6 +62,19 @@ export default {
|
|||
});
|
||||
},
|
||||
|
||||
closeTaskConfirm(row){
|
||||
let flag = row.taskStatus;
|
||||
row.taskStatus = !flag; //保持switch点击前的状态
|
||||
this.$confirm(this.$t('api_test.home_page.running_task_list.confirm.close_title'), this.$t('commons.prompt'), {
|
||||
confirmButtonText: this.$t('commons.confirm'),
|
||||
cancelButtonText: this.$t('commons.cancel'),
|
||||
type: 'warning'
|
||||
}).then(() => {
|
||||
this.updateTask(row);
|
||||
}).catch(() => {
|
||||
});
|
||||
},
|
||||
|
||||
updateTask(taskRow){
|
||||
|
||||
this.result = this.$post('/api/schedule/updateEnableByPrimyKey', taskRow, response => {
|
||||
|
@ -66,8 +88,11 @@ export default {
|
|||
},
|
||||
activated() {
|
||||
this.search();
|
||||
},
|
||||
handleStatus(scope) {
|
||||
console.log(scope.row.userId)
|
||||
}
|
||||
}
|
||||
}
|
||||
</script>
|
||||
|
||||
<style scoped>
|
||||
|
|
|
@ -18,7 +18,21 @@
|
|||
</el-aside>
|
||||
<el-main style="padding-left: 0px;padding-right: 0px">
|
||||
<div style="width: 200px;margin:0 auto">
|
||||
<el-row align="center">
|
||||
<el-row align="center" class="hidden-lg-and-down">
|
||||
<el-col :span="6" style="padding: 5px;border-right-style: solid;border-right-width: 1px;border-right-color: #ECEEF4;">
|
||||
<div class="count-info-div" v-html="testCaseCountData.httpCountStr"></div>
|
||||
</el-col>
|
||||
<el-col :span="6" style="padding: 5px;border-right-style: solid;border-right-width: 1px;border-right-color: #ECEEF4;">
|
||||
<div class="count-info-div" v-html="testCaseCountData.rpcCountStr"></div>
|
||||
</el-col>
|
||||
<el-col :span="6" style="padding: 5px;border-right-style: solid;border-right-width: 1px;border-right-color: #ECEEF4;">
|
||||
<div class="count-info-div" v-html="testCaseCountData.tcpCountStr"></div>
|
||||
</el-col>
|
||||
<el-col :span="6" style="padding: 5px;">
|
||||
<div class="count-info-div" v-html="testCaseCountData.sqlCountStr"></div>
|
||||
</el-col>
|
||||
</el-row>
|
||||
<el-row align="right" style="margin-left: 20px" class="hidden-xl-only">
|
||||
<el-col :span="6" style="padding: 5px;border-right-style: solid;border-right-width: 1px;border-right-color: #ECEEF4;">
|
||||
<div class="count-info-div" v-html="testCaseCountData.httpCountStr"></div>
|
||||
</el-col>
|
||||
|
|
|
@ -885,6 +885,9 @@ export default {
|
|||
create_user: "Creator",
|
||||
update_time: "Update time",
|
||||
},
|
||||
confirm:{
|
||||
close_title: "Do you want to close this scheduled task?",
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
|
|
|
@ -886,6 +886,9 @@ export default {
|
|||
create_user: "创建人",
|
||||
update_time: "更新时间",
|
||||
},
|
||||
confirm:{
|
||||
close_title: "要关闭这条定时任务吗?",
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
|
|
|
@ -885,6 +885,9 @@ export default {
|
|||
create_user: "創建人",
|
||||
update_time: "更新時間",
|
||||
},
|
||||
confirm:{
|
||||
close_title: "要關閉這條定時任務嗎?",
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
|
|
Loading…
Reference in New Issue