This commit is contained in:
caozehui
2024-12-20 19:14:07 +08:00
parent 9b8765f001
commit dc3976f525
2 changed files with 57 additions and 18 deletions

View File

@@ -25,6 +25,7 @@
<el-button type="primary" :icon="DArrowRight" v-if="stepsActiveIndex < 2 && ActiveStatue != 'success'" :disabled="skipDisabled" @click="nextStep">跳过</el-button>
<el-button type="primary" :icon="VideoPlay" v-if="ActiveStatue === 'waiting'" @click="handleSubmit">开始检测</el-button>
<el-button type="danger" :icon="Close" v-if="ActiveStatue === 'process'" @click="handleSubmit">停止检测</el-button>
<el-button type="danger" :icon="Close" v-if="ActiveStatue === 'paused'" @click="handleSubmit">继续检测</el-button>
<el-button type="primary" :icon="Refresh" v-if="ActiveStatue === 'error'" @click="handleSubmit">重新检测</el-button>
<el-button type="primary" :icon="Right" v-if="ActiveStatue === 'success'" @click="nextStep">{{nextStepText}}</el-button>
</div>
@@ -35,18 +36,26 @@
</template>
<script lang="tsx" setup name="testPopup">
import { h } from 'vue';
import {ElLoading, ElMessage, ElMessageBox, ElSelectV2, FormInstance, FormItemRule} from 'element-plus'
import { defineProps, defineEmits, reactive,watch,ref, Ref } from 'vue';
import { dialogBig,dialogMiddle} from '@/utils/elementBind'
import {h, reactive, ref, watch} from 'vue';
import {ElMessage, ElMessageBox} from 'element-plus'
//import IndicatorTypeDialog from "@/views/machine/errorSystem/components/IndicatorTypeDialog.vue"; // 导入子组件
import {CirclePlus, Delete, EditPen,FolderOpened,CopyDocument,Edit, Picture, UploadFilled, SuccessFilled,VideoPlay,Right,Refresh,Close, Odometer,Coin,Key, DArrowRight} from '@element-plus/icons-vue'
import { useDictStore } from '@/stores/modules/dict'
import {
Close,
Coin,
DArrowRight,
Edit,
Key,
Odometer,
Refresh,
Right,
SuccessFilled,
UploadFilled,
VideoPlay
} from '@element-plus/icons-vue'
import preTest from './preTest.vue'
import timeTest from './timeTest.vue'
import socketClient from '@/utils/webSocketClient';
import {startTest} from '@/api/socket/socket'
import channelsTest from './channelsTest.vue'
//import SvgIcon from '@/components/SvgIcon.vue';
// import preTestIcon from '@/assets/icons/preTest.svg'
@@ -215,7 +224,13 @@ const detectionOptions = ref([
// channelsTestStatus.value = 'start'
// break;
case 2:
TestStatus.value = 'start'
if (TestStatus.value == "waiting") {
TestStatus.value = 'start'
} else if (TestStatus.value == 'process') {
TestStatus.value = 'paused'
} else if (TestStatus.value == 'paused') {
TestStatus.value = 'process'
}
break;
default:
break;