qinzhipeng_v 5 жил өмнө
parent
commit
ccd3b6f9f9

+ 1 - 1
src/router/index.js

@@ -265,7 +265,7 @@ export const constantRoutes = [{
   component: Layout,
   name: '测试',
   redirect: '/Platform/useCase/test',
-  meta: { title: '测试', icon: '测试' },
+  meta: { title: '测试管理', icon: '测试' },
   children: [{
     path: 'useCasePage',
     name: '测试用例',

+ 9 - 4
src/views/Platform/presentation/Templates/TestReport.vue

@@ -26,7 +26,7 @@
         <el-button size="small" type="primary" @click="NextStep()">下一步</el-button>
       </div>
     </div>
-    <el-dialog :visible.sync="showClient" width="80%" top="4vh" :close-on-click-modal="false" append-to-body :before-close="handleClose1">
+    <el-dialog :visible.sync="showClient" width="80%" top="4vh" :close-on-click-modal="false" append-to-body :before-close="handleClose1()">
       <div class="flex_start titFont">
         <div class="titIcon" />
         <span style="margin-left: 1%; width: 100px;">提测报告</span>
@@ -40,10 +40,10 @@
       </div>
       <div class="descr" style=" margin-bottom: 2%; height: 440px; overflow:scroll; overflow-x: hidden">
         <Present v-if="Present1" ref="Present" />
-        <presentation v-if="presentation1" ref="presentation" />
+        <presentation v-if="presentation1" ref="presentationRef" />
       </div>
       <div align="center">
-        <el-button size="small" type="primary" @click="handleClose1()">上一步</el-button>
+        <el-button size="small" type="primary" @click="PreviousStep()">上一步</el-button>
         <el-button size="small" type="primary" @click="created_out()">保存,下一步</el-button>
       </div>
       <el-dialog :visible.sync="showClientYL" width="80%" top="4vh" :close-on-click-modal="false" append-to-body :before-close="handleClose2">
@@ -112,10 +112,14 @@ export default {
     init(e, id) {
       this.dialogVisible1 = true
     },
-    handleClose1() {
+    handleClose1(e) {
       this.showClient = false
       this.dialogVisible1 = false
     },
+    PreviousStep() {
+      this.showClient = false
+      this.dialogVisible1 = true
+    },
     handleClose2() {
       this.showClientYL = false
       this.showClient = false
@@ -125,6 +129,7 @@ export default {
       this.showClientYL = false
     },
     created_out() {
+      this.$refs.presentationRef.parentHandleclick()
       this.showClientYL = true
       // this.$nextTick(() => {
       //   this.$refs.acceptthe.int()

+ 5 - 13
src/views/Platform/presentation/presentationReport.vue

@@ -92,12 +92,8 @@
           <el-form-item label="其他"><el-input v-model="fromDev.others" style="padding-left: 25px; text-align: right; width: 85vw;" size="small" type="textarea" :rows="5" placeholder="请输入其他内容…" /></el-form-item>
         </el-col>
       </div>
-
-      <div class="double" align="center" style="margin: 5vw 0 3vw;">
-        <div><el-button @click="clickPreview(fromDev)"> 预 览 </el-button></div>
-        <div v-show="showButton"><el-button type="primary" @click="getCreateData(fromDev)"> 保 存 </el-button></div>
-        <div v-show="showButton1"><el-button type="primary" @click="getQueryData(fromDev)"> 更 新 </el-button></div>
-      </div>
+      <!-- <div v-show="showButton"><el-button type="primary" @click="getCreateData(fromDev)"> 保 存 </el-button></div> -->
+      <div v-show="showButton1"><el-button type="primary" @click="getQueryData(fromDev)"> 更 新 </el-button></div>
     </el-form>
   </div>
 </template>
@@ -136,7 +132,6 @@ export default {
       lateStatusBtn1: 'info',
       getInfoBtn: 'info',
       getInfoBtn1: 'info',
-      showButton: true,
       showButton1: false,
       userData: '',
       showDelay: false,
@@ -175,7 +170,6 @@ export default {
   },
   methods: {
     getRouterData() {
-      this.showButton = true
       this.showButton1 = false
       if (this.$route.query.task) { // 任务提测
         this.bizIdCode = this.$route.query.task.bizId
@@ -183,7 +177,6 @@ export default {
       }
       if (this.$route.query.data) {
         this.showButton1 = true
-        this.showButton = false
         launchTest({ id: this.$route.query.id }).then((res) => {
           this.fromDev = res.data
           if (this.fromDev.lateReason !== '') {
@@ -230,6 +223,9 @@ export default {
         }
       })
     },
+    parentHandleclick(e) {
+      this.getCreateData(this.fromDev)
+    },
     getCreateData(ele) {
       this.$refs['fromDev'].validate((valid) => {
         if (valid) {
@@ -284,10 +280,6 @@ export default {
         this.getInfoBtn = 'danger'
         this.showData = true
       }
-    },
-
-    clickPreview(ele) {
-      this.$router.push({ path: '/Platform/presentation/acceptTheReport', query: { id: this.$route.query.id }})
     }
   }
 }