Merge branch 'master' of http://192.168.1.22:3000/frontend/pqs-9100_client
This commit is contained in:
@@ -10,10 +10,10 @@
|
||||
type="primary"
|
||||
v-if="testStatus=='process' && percentage < 100"
|
||||
:icon="VideoPause"
|
||||
@click="emit('sendPause')">停止检测
|
||||
@click="handlePause()">停止检测
|
||||
</el-button>
|
||||
<el-button type="warning" v-if="testStatus === 'paused_ing'" disabled>
|
||||
<el-icon class="loading-box" style="margin-right: 8px;">
|
||||
<el-button type="warning" v-if="testStatus === 'paused_ing' && percentage < 100" disabled>
|
||||
<el-icon class="loading-box">
|
||||
<component :is="Refresh"/>
|
||||
</el-icon>
|
||||
暂停中
|
||||
@@ -433,7 +433,7 @@ watch(webMsgSend, function (newValue, oldValue) {
|
||||
if(newValue.operateCode == 'stop'){
|
||||
ElMessage.success('暂停成功')
|
||||
emit('update:testStatus', 'paused')
|
||||
handlePauseTest()
|
||||
pauseSuccessCallback()
|
||||
}
|
||||
break;
|
||||
// case 'Pause_Fail':
|
||||
@@ -1276,8 +1276,12 @@ const startTimer = () => {
|
||||
break;
|
||||
}
|
||||
};
|
||||
const handlePause = () => {
|
||||
emit('sendPause')
|
||||
testLogList.push({type: 'error', log: `${new Date().toLocaleString()}:当前测试小项正在执行中,将在该小项执行结束后暂停...`})
|
||||
}
|
||||
|
||||
const handlePauseTest = () => {
|
||||
const pauseSuccessCallback = () => {
|
||||
endData.value = new Date();
|
||||
let diffTime = endData.value.getTime() - startData.value.getTime();
|
||||
timeDifference.value += diffTime
|
||||
|
||||
@@ -28,21 +28,21 @@
|
||||
@click="nextStep">跳过
|
||||
</el-button>
|
||||
<el-button type="primary" :icon="VideoPlay" v-if="ActiveStatue === 'waiting'" @click="handleSubmit">开始检测</el-button>
|
||||
<el-button type="primary" v-if="ActiveStatue === 'process'" @click="handleSubmit" disabled>
|
||||
<el-button type="primary" v-if="TestStatus === 'process'" @click="handleSubmit" disabled>
|
||||
<el-icon class="loading-box" style="color: #fff;margin-right: 8px;">
|
||||
<component :is="Refresh"/>
|
||||
</el-icon>
|
||||
检测中
|
||||
</el-button>
|
||||
<el-button type="warning" :icon="VideoPlay" v-if="ActiveStatue === 'paused'" @click="handleSubmit">继续检测</el-button>
|
||||
<el-button type="primary" :icon="RefreshLeft" v-if="ActiveStatue === 'test_recheck'" @click="handleSubmit">重新检测</el-button>
|
||||
<el-button type="primary" v-if="ActiveStatue === 'test_init'" disabled>
|
||||
<el-button type="warning" :icon="VideoPlay" v-if="TestStatus === 'paused'" @click="handleSubmit">继续检测</el-button>
|
||||
<el-button type="primary" :icon="RefreshLeft" v-if="TestStatus === 'test_recheck'" @click="handleSubmit">重新检测</el-button>
|
||||
<el-button type="primary" v-if="TestStatus === 'test_init'" disabled>
|
||||
<el-icon class="loading-box" style="color: #fff;margin-right: 8px;">
|
||||
<component :is="Refresh"/>
|
||||
</el-icon>
|
||||
初始化中
|
||||
</el-button>
|
||||
<el-button type="warning" v-if="ActiveStatue === 'paused_ing'" disabled>
|
||||
<el-button type="warning" v-if="TestStatus === 'paused_ing'" disabled>
|
||||
<el-icon class="loading-box" style="color: #fff;margin-right: 8px;">
|
||||
<component :is="Refresh"/>
|
||||
</el-icon>
|
||||
@@ -377,7 +377,7 @@ watch(ActiveStatue, function (newValue, oldValue) {
|
||||
const sendPause = () => {
|
||||
console.log('发起暂停请求')
|
||||
|
||||
ActiveStatue.value = 'paused_ing'
|
||||
TestStatus.value = 'paused_ing'
|
||||
pauseTest()
|
||||
}
|
||||
const sendResume = () => {
|
||||
|
||||
Reference in New Issue
Block a user