panxiandiao_i 5 жил өмнө
parent
commit
837c9df35c

+ 47 - 0
src/api/HMvehicle.js

@@ -0,0 +1,47 @@
+import request from '@/utils/request'
+import { HMvehicleUrl } from '@/apiConfig/api'
+
+// 创建设备/激活设备
+export function createHmVirtualDevice(data) {
+  return request({
+    url: HMvehicleUrl + '/virtual-devices/hm/createDevice',
+    method: 'post',
+    data
+  })
+}
+
+// 查询设备信息
+export function queryDeviceInfo(params) {
+  return request({
+    url: HMvehicleUrl + '/virtual-devices/hm/queryDeviceInfo',
+    method: 'get',
+    params
+  })
+}
+
+// 删除设备
+export function delHmVirtualDevice(params) {
+  return request({
+    url: HMvehicleUrl + '/virtual-devices/hm/delDevice',
+    method: 'get',
+    params
+  })
+}
+
+// 下线设备
+export function offHmvirtualDevice(params) {
+  return request({
+    url: HMvehicleUrl + '/virtual-devices/hm/offDevice',
+    method: 'get',
+    params
+  })
+}
+
+// 更新锁状态
+export function updateLockStatus(params) {
+  return request({
+    url: HMvehicleUrl + '/virtual-devices/hm/updateLockStatus',
+    method: 'get',
+    params
+  })
+}

+ 1 - 0
src/api/httprule.js

@@ -3,6 +3,7 @@ import { mockUrl } from '@/apiConfig/mock'
 // ================================== Rule ======================================
 // const mockUrl = 'http://mock.Intra.xiaojukeji.com'
 // const mockUrl = 'http://10.179.88.110:8089'
+// const mockUrl = 'http://172.23.160.90:8089'
 
 export function fetchRuleById(data) {
   return request({

+ 1 - 1
src/api/qualityCenter.js

@@ -49,7 +49,7 @@ export function getOnlineProblem(params) {
 // 线上缺陷
 export function getOnlineVitium(params) {
   return request({
-    url: qualityUrl + '/api/off-line-defects/data-all-count',
+    url: qualityUrl + '/api/off-line-defects/data-count',
     method: 'get',
     params
   })

+ 2 - 0
src/apiConfig/api.js

@@ -5,3 +5,5 @@ export const mockUrl = 'http://10.179.24.123:8980' // 线上
 // export const mockUrl = 'http://172.23.162.48:8980' // 美双姐本地
 
 export const qualityUrl = 'http://10.179.209.19:8898' // 质量度量
+
+export const HMvehicleUrl = 'http://172.23.161.143:9999' // 电单车

+ 0 - 1
src/router/index.js

@@ -94,7 +94,6 @@ export const constantRoutes = [
       {
         path: 'useCasePage',
         name: 'useCasePage',
-        hidden: true,
         component: () => import('@/views/Platform/useCasePage'),
         meta: { title: '用例管理' }
       },

+ 12 - 15
src/views/Platform/bugManage/bugCreate.vue

@@ -230,7 +230,6 @@ export default {
       formLabelWidth: '11%',
       formLabelWidth1: '22%',
       userData: '',
-      submitMissionJudge: '',
       businessTypeShow: false,
       moduleTypeShow: false,
       userInformation: localStorage.getItem('username'),
@@ -257,7 +256,7 @@ export default {
         this.clientTypeEnumList = res.data.clientTypeEnumList
         this.serviceTypeEnumList = res.data.serviceTypeEnumList
       })
-      await taskListCreate({ statusList: [6, 7] }).then(res => { // 获取任务数据 (后期用this.taskStatus)
+      await taskListCreate({ statusList: [5, 6, 7, 8, 9, 10] }).then(res => { // 获取任务数据 (后期用this.taskStatus)
         this.taskIdStr = res.data
       })
       if (this.$route.query.id) {
@@ -278,6 +277,8 @@ export default {
             this.businessTypeStr = this.platformTypeStr.filter(value => value.name === res.data.typeString)[0].child
           }
         })
+      } else {
+        this.form.creator = this.userNames
       }
     },
     forkDown() {
@@ -285,12 +286,13 @@ export default {
         if (res.code === 200) {
           this.bizOptions = res.data
         } else {
-          this.errorFun()
+          this.errorFun('业务线数据获取失败')
         }
       })
     },
     // 业务线取子数据
     clickChangePlatform(e) {
+      console.log(this.form.taskId)
       this.platformTypeStr = this.bizOptions.filter(value => value.code === e)[0].child
       this.businessTypeStr = []
       this.moduleStr = []
@@ -320,9 +322,6 @@ export default {
       }
       this.$set(this.form, 'moduleId', '')
     },
-    submitJudge(e) {
-      this.submitMissionJudge = e
-    },
     // 提交表单并且返回刷新
     createFormData(form) {
       this.$refs.form.validate((valid) => {
@@ -330,26 +329,24 @@ export default {
           if (this.$route.query.id && typeof this.form.bizId === 'string') {
             form.bizId = this.bizOptions.filter(value => value.name === form.bizId)[0].code
           }
-          if (this.$route.query.id && !this.submitMissionJudge) {
-            form.taskId = this.taskIdStr.filter(value => value.name === form.taskId)[0].id
-          }
           form.reopenTimes = parseInt(form.reopenTimes)
           form.projectId = this.taskIdStr.filter(value => value.id === this.form.taskId)[0].projectId
           this.userData = { id: '', ename: this.userInformation, name: this.userNames }
           this.objData = { bugBaseInfo: form, user: this.userData }
           bugCreate(this.objData).then(res => {
-            res.code === 200 ? this.successFun() : this.errorFun()
-            this.submitMissionJudge = ''
+            res.code === 200 ? this.successFun('create') : this.errorFun('create Failed')
             this.$router.go(-1)
           })
+        } else {
+          this.errorFun('还有未填写的信息')
         }
       })
     },
-    successFun() {
-      this.$notify({ title: 'Success', message: 'Created Successfully', type: 'success', duration: 2000 })
+    successFun(successText) {
+      this.$notify({ title: 'Success', message: `${successText} Successfully`, type: 'success', duration: 2000 })
     },
-    errorFun() {
-      this.$notify({ title: 'Failed', message: 'Created Failed', type: 'error', duration: 2000 })
+    errorFun(errorText) {
+      this.$notify({ title: 'Failed', message: `${errorText}`, type: 'error', duration: 2000 })
     }
   }
 }

+ 0 - 1
src/views/Platform/bugManage/bugQuery.vue

@@ -153,7 +153,6 @@ export default {
     // 先后获取
     async _initBegin() {
       await bugGetEnum().then(res => {
-        console.log(res.data.reasonEnumList)
         this.bugStatusStr = res.data.bugEnumList
         this.bugLevelStr = res.data.priorityEnumList
         this.bizIdEnumList = res.data.bizIdEnumList

+ 1 - 3
src/views/Platform/bugManage/bugUpdate.vue

@@ -237,7 +237,6 @@ export default {
   methods: {
     handleChange(file, fileList) {
       this.fileList = fileList.slice(-3)
-      console.log(this.fileList)
     },
     async _initBegin() {
       await bugGetEnum().then(res => {
@@ -272,7 +271,7 @@ export default {
     },
     // 获取任务数据
     taskIdGet() {
-      taskListCreate({ statusList: [6, 7] }).then(res => {
+      taskListCreate({ statusList: [5, 6, 7, 8, 9, 10] }).then(res => {
         this.taskIdStr = res.data
       })
     },
@@ -310,7 +309,6 @@ export default {
     // 提交表单并且返回刷新
     createFormData(form) {
       this.$refs.form.validate((valid) => {
-        console.log(form)
         if (valid) {
           form.reopenTimes = parseInt(form.reopenTimes)
           this.userData = { id: '', ename: this.userInformation, name: this.userNames }

+ 2 - 2
src/views/Platform/defectManagement.vue

@@ -13,7 +13,7 @@
           </el-select>
           <el-input v-model="queryCode.currentHandler" clearable filterable placeholder="处理人" style="width:12%;margin-right:5px;" />
           <el-input v-model="queryCode.creator" clearable filterable placeholder="创建人" style="width:12%;margin-right:5px;" />
-          <el-date-picker v-model="queryCode.gmtCreateBegin" style="width:12%;margin-right:5px;" type="datetime" placeholder="创建时间" /> -
+          <el-date-picker v-model="queryCode.gmtCreateBegin" style="width:12%;margin-right:5px;" type="datetime" placeholder="创建时间" />
           <el-date-picker v-model="queryCode.gmtCreateEnd" style="width:12%;margin-right:5px;" type="datetime" placeholder="截止时间" />
           <el-input v-model="queryCode.bugName" clearable filterable placeholder="主题" style="width:12%;margin-right:5px;" />
           <el-button type="primary" @click="dataQuery(queryCode)">查询</el-button>
@@ -270,7 +270,7 @@ export default {
       userInformation: localStorage.getItem('username'),
       userNames: localStorage.getItem('realname'),
       bizJson: localStorage.getItem('key'),
-      pageSize: 5,
+      pageSize: 20,
       curIndex: 0,
       total: 0,
       show2: '',

+ 2 - 2
src/views/Platform/presentation/Acceptance.vue

@@ -17,7 +17,7 @@
             <el-button :type="tagBtn" style="margin: 0 2vw;" class="tag" @click="changeStatus(1)"> 通过 </el-button>
             <el-button :type="tagBtn1" class="tag" @click="changeStatus(2)"> 不通过 </el-button>
           </el-form-item>
-          <el-form-item label="准入结果" prop="smokeTestResult" style="flex: 2;text-align:right;"><el-input v-model="ClientData.launchInfo" style="width: 50vw;" placeholder="准入次数/通过次数/失败次数" /></el-form-item>
+          <el-form-item label="准入结果" prop="smokeTestResult" style="flex: 2;text-align:right;"><el-input v-model="ClientData.smokeTestResult" style="width: 50vw;" placeholder="准入次数/通过次数/失败次数" /></el-form-item>
         </div>
         <div style="display: flex; white-space: nowrap;">
           <el-form-item label="* 准出延期" style="flex: 1;" prop="taskLateStatus">
@@ -481,7 +481,7 @@ export default {
 
     getBugData(e) {
       bugFinishList(e).then(res => {
-        this.$set(this.ClientData, 'launchInfo', res.data.launchInfo)
+        this.$set(this.ClientData, 'smokeTestResult', res.data.launchInfo)
         this.tableData = [res.data]
         this.formatData()
       })

+ 3 - 3
src/views/Platform/presentation/ClientAcceptance.vue

@@ -18,7 +18,7 @@
             <el-tag :type="tagBtn" effect="dark" style="margin: 0 2vw;" class="tag" @click="changeStatus(1)"> 通过 </el-tag>
             <el-tag :type="tagBtn1" effect="dark" class="tag" @click="changeStatus(2)"> 不通过 </el-tag>
           </el-form-item>
-          <el-form-item label="准入结果" prop="smokeTestResult" style="flex: 2;text-align:right;"><el-input v-model="ClientData.launchInfo" style="width: 50vw;" placeholder="准入次数/通过次数/失败次数" /></el-form-item>
+          <el-form-item label="准入结果" prop="smokeTestResult" style="flex: 2;text-align:right;"><el-input v-model="ClientData.smokeTestResult" style="width: 50vw;" placeholder="准入次数/通过次数/失败次数" /></el-form-item>
         </div>
         <div style="display: flex; white-space: nowrap;">
           <el-form-item label="* 准出延期" style="flex: 1;" prop="taskLateStatus">
@@ -90,7 +90,7 @@
 
         <div style="margin: 2% 0 2% 0;" class="backStyle">五. bug指标</div>
 
-        <el-table :data="tableData" border @cell-dblclick="celledit">
+        <el-table :data="tableData" border>
           <el-table-column prop="totalBug" label="bug总数" min-width="200" align="center" edit="false">
             <template slot-scope="scope">
               <el-input v-if="scope.row.totalBug.edit" ref="totalBug" v-model="scope.row.totalBug.value" style="width: 100%" @blur="scope.row.totalBug.edit = false" />
@@ -447,7 +447,7 @@ export default {
     },
     getBugData(e) {
       bugFinishList(e).then(res => {
-        this.$set(this.ClientData, 'launchInfo', res.data.launchInfo)
+        this.$set(this.ClientData, 'smokeTestResult', res.data.launchInfo)
         this.tableData = [res.data]
         this.formatData()
       })

+ 3 - 3
src/views/Platform/presentation/DailyNewsAdded.vue

@@ -174,7 +174,7 @@ export default {
         this.projectId = this.$route.query.state1.projectId
         this.taskId = this.$route.query.state1.taskId
         this.bizIdCode = this.$route.query.state1.bizId
-        this.pro = { projectId: this.projectId, bizId: this.bizIdCode, taskId: this.taskId }
+        this.pro = { projectId: this.projectId, taskId: this.taskId }
       }
       if (this.$route.query.task) { // 任务页面
         this.fromCreateData = {}
@@ -182,7 +182,7 @@ export default {
         this.showButton = true
         this.bizIdCode = this.$route.query.task.bizId
         this.idCode = this.$route.query.task.id
-        this.pro = { taskId: this.idCode, bizId: this.bizIdCode }
+        this.pro = { taskId: this.idCode }
       }
       if (this.$route.query.projectId) { // 项目页面
         this.fromCreateData = {}
@@ -190,7 +190,7 @@ export default {
         this.showButton = true
         this.bizIdCode = this.$route.query.projectId.bizId
         this.idCode = this.$route.query.projectId.id
-        this.pro = { projectId: this.idCode, bizId: this.bizIdCode }
+        this.pro = { projectId: this.idCode }
       }
 
       bugDailyList(this.pro).then(res => {

+ 1 - 1
src/views/Platform/projectPage.vue

@@ -300,7 +300,7 @@ export default {
       formLabelWidths: '160px',
       formLabelWidth: '150px',
       curIndex: 1, // 初始页
-      pageSize: 5, // 每页的数据
+      pageSize: 20, // 每页的数据
       total: 0,
       noTestString: [{ name: '测试', value: 0 }, { name: '自测', value: 1 }],
       typeString: [{ name: '服务端', value: 1 }, { name: '客户端', value: 2 }],

+ 6 - 3
src/views/Platform/projectQuery/taskQuery.vue

@@ -109,8 +109,8 @@
               <el-tab-pane label="bug报告">
                 <el-table :data="projectBug" max-height="390" style="width: 100%" @row-click="queryBugData">
                   <el-table-column label="ID" align="center" min-width="60"><template slot-scope="scope">{{ scope.row.id }}</template></el-table-column>
-                  <el-table-column label="标题" align="center" min-width="100"><template slot-scope="scope">{{ scope.row.bugName }}</template></el-table-column>
-                  <el-table-column label="状态" align="center" min-width="80"><template slot-scope="scope">{{ scope.row.status }}</template></el-table-column>
+                  <el-table-column label="标题" align="center" min-width="100"><template slot-scope="scope"><el-tag style="cursor: pointer;" @click="turnToBugCreate(scope.row.id)">{{ scope.row.bugName }}</el-tag></template></el-table-column>
+                  <el-table-column label="状态" align="center" min-width="80"><template slot-scope="scope">{{ scope.row.bugStatusName }}</template></el-table-column>
                   <el-table-column label="当前处理人" align="center" min-width="100"><template slot-scope="scope">{{ scope.row.currentHandler }}</template></el-table-column>
                   <el-table-column label="创建时间" align="center" min-width="150"><template slot-scope="scope">{{ scope.row.gmtCreate }}</template></el-table-column>
                 </el-table>
@@ -566,7 +566,10 @@ export default {
       // this.osTypeShow === false ? this.$set(this.fromCode, 'osType', '') : ''
       this.getList()
     },
-
+    // bug报告跳转
+    turnToBugCreate(e) {
+      this.$router.push({ path: '/Platform/defectManagement/bugQuery', query: { id: e }}) // 缺陷报告
+    },
     // 所有下拉菜单数据
     bugListSelect() {
       bugGetEnum().then(res => {

+ 3 - 4
src/views/mock/httprule.vue

@@ -127,7 +127,7 @@
         </el-form-item>
       </el-form>
       <div slot="footer" class="dialog-footer">
-        <el-button @click="dialogFormVisible = false">
+        <el-button @click="clear(), dialogFormVisible = false">
           取消
         </el-button>
         <el-button v-if="showSubmit" type="primary" @click="dialogStatus==='create'?createData():updateData()">
@@ -417,12 +417,12 @@ export default {
         if (response.code === 200) {
           row.status = status
           this.$message({
-            message: row.id.toString() + ' 操作成功!',
+            message: '规则ID:' + row.id.toString() + ' 操作成功!',
             type: 'success'
           })
         } else {
           this.$message({
-            message: row.id.toString() + ' 操作失败!',
+            message: '规则ID:' + row.id.toString() + ' 操作失败!',
             type: 'danger'
           })
         }
@@ -518,4 +518,3 @@ export default {
   right: 38.5%;
 }
 </style>
-

+ 47 - 27
src/views/quality/qualityMeasurement.vue

@@ -4,7 +4,7 @@
     <el-header class="header">
       <el-menu :default-active="activeIndex" active-text-color="#409EFF" mode="horizontal" @select="handleSelect">
         <el-menu-item index="0">业务线数据</el-menu-item>
-        <el-menu-item index="2">部门数据</el-menu-item>
+        <el-menu-item index="3">部门数据</el-menu-item>
       </el-menu>
       <el-date-picker
         v-model="timeInterval"
@@ -13,11 +13,12 @@
         start-placeholder="开始日期"
         end-placeholder="结束日期"
         value-format="timestamp"
+        @change="dataSearch"
       />
     </el-header>
     <el-container style="height:calc(100vh - 140px);">
       <el-aside class="aside">
-        <el-tree ref="treeBox" :data="dealWithBusinessDate" :expand-on-click-node="false" node-key="id" highlight-current :props="defaultProps" style="margin-top:20px" @node-click="handleNodeClick" />
+        <el-tree ref="treeBox" :data="dealWithBusinessDate" node-key="id" highlight-current :props="defaultProps" style="margin-top:20px" @node-click="handleNodeClick" />
       </el-aside>
       <el-main class="combine-table">
         <el-menu :default-active="activeIndexSecondary" active-text-color="#409EFF" mode="horizontal" @select="handleSelectSecondary">
@@ -37,14 +38,14 @@
             style="width:50%;"
             align="center"
           >
-            <template slot-scope="scope"><a href="javascript:void(0)" style="color:#20a0ff" @click="toReportView(0)">{{ scope.row.totalOnlineNum }}</a></template>
+            <template slot-scope="scope"><a href="javascript:void(0)" style="color:#20a0ff" @click="toReportView('0')">{{ scope.row.totalOnlineNum }}</a></template>
           </el-table-column>
           <el-table-column
             label="免提测上线数"
             style="width:50%;"
             align="center"
           >
-            <template slot-scope="scope"><a href="javascript:void(0)" style="color:#20a0ff" @click="toReportView(1)">{{ scope.row.noTestNum }}</a></template>
+            <template slot-scope="scope"><a href="javascript:void(0)" style="color:#20a0ff" @click="toReportView('1')">{{ scope.row.noTestNum }}</a></template>
           </el-table-column>
         </el-table>
         <el-table
@@ -64,7 +65,7 @@
               style="width:20%;"
               align="center"
             >
-              <template slot-scope="scope"><a href="javascript:void(0)" style="color:#20a0ff" @click="toReportView(2)">{{ scope.row.rollbackNum }}</a></template>
+              <template slot-scope="scope"><a href="javascript:void(0)" style="color:#20a0ff" @click="toReportView('2')">{{ scope.row.rollbackNum }}</a></template>
             </el-table-column>
             <el-table-column
               prop="name"
@@ -77,21 +78,21 @@
               style="width:20%;"
               align="center"
             >
-              <template slot-scope="scope"><a href="javascript:void(0)" style="color:#20a0ff" @click="toReportView(3)">{{ scope.row.preRollbackNum }}</a></template>
+              <template slot-scope="scope"><a href="javascript:void(0)" style="color:#20a0ff" @click="toReportView('3')">{{ scope.row.preRollbackNum }}</a></template>
             </el-table-column>
             <el-table-column
               label="小流量回滚数"
               style="width:20%;"
               align="center"
             >
-              <template slot-scope="scope"><a href="javascript:void(0)" style="color:#20a0ff" @click="toReportView(4)">{{ scope.row.preLess5Min }}</a></template>
+              <template slot-scope="scope"><a href="javascript:void(0)" style="color:#20a0ff" @click="toReportView('4')">{{ scope.row.preLess5Min }}</a></template>
             </el-table-column>
             <el-table-column
               label="全量回滚数"
               style="width:20%;"
               align="center"
             >
-              <template slot-scope="scope"><a href="javascript:void(0)" style="color:#20a0ff" @click="toReportView(5)">{{ scope.row.allRollbackNum }}</a></template>
+              <template slot-scope="scope"><a href="javascript:void(0)" style="color:#20a0ff" @click="toReportView('5')">{{ scope.row.allRollbackNum }}</a></template>
             </el-table-column>
           </el-table-column>
         </el-table>
@@ -298,10 +299,11 @@
           size="mini"
         >
           <el-table-column
-            prop="totalBugNum"
             label="提报bug数"
             align="center"
-          />
+          >
+            <template slot-scope="scope"><a href="javascript:void(0)" style="color:#20a0ff" @click="toDefectView()">{{ scope.row.totalBugNum }}</a></template>
+          </el-table-column>
           <el-table-column
             label="缺陷分级"
             align="center"
@@ -402,8 +404,8 @@ import { getBusiness, getDepartment, getOnlineProblem, getOnlineAllCount, getOnl
 export default {
   filters: {
     toPercent(value) {
-      if (value === 0) {
-        return 0
+      if (!value) {
+        return
       } else {
         return Number(value * 100).toFixed(2) + '%'
       }
@@ -422,11 +424,11 @@ export default {
       loadingOnlineProcess: true,
       activeIndex: '0',
       activeIndexSecondary: '3',
-      timeInterval: '',
+      // timeInterval: '',
       pauseTreeNode: {},
       pauseKey: '',
-      dealWithBusinessDate: []
-      // timeInterval: [new Date().getTime() - 15 * 24 * 60 * 60 * 1000, new Date().getTime()]
+      dealWithBusinessDate: [],
+      timeInterval: [new Date().getTime() - 365 * 24 * 60 * 60 * 1000, new Date().getTime()]
     }
   },
   created() {
@@ -438,10 +440,10 @@ export default {
       this.loadingOnlineProcess = true
       await getBusiness().then(res => {
         this.businessData = res.code === 0 ? res.data : ''
-        const processFunc = (arr) => { // models和child
+        const processFunc = (arr) => { // modules和child
           arr.forEach((each) => {
-            if (each.models.length !== 0) {
-              each.child = each.models
+            if (each.modules) {
+              each.child = each.modules
             } else {
               each.child = processFunc(each.child)
             }
@@ -461,9 +463,18 @@ export default {
       await getDepartment().then(res => {
         this.dealWithBusinessDate = res.code === 0 ? res.data : ''
         this.pauseTreeNode = this.dealWithBusinessDate[0] ? this.dealWithBusinessDate[0] : ''
-        this.pauseKey = 2
+        this.pauseKey = 3
       })
-      this.allCountAndProlemGet()
+      this.deleteAfter()
+    },
+    deleteAfter() {
+      const pretermitSearch = { id: this.pauseTreeNode.id, type: this.pauseKey, startTime: this.timeInterval[0], endTime: this.timeInterval[1] }
+      axios.all([getOnlineAllCount(pretermitSearch), getOnlineProblem({ id: this.pauseTreeNode.id })]).then(axios.spread((resAllCount, resProblem) => {
+        this.onlineProcess = resAllCount.code === 0 ? resAllCount.data : ''
+        this.problemData = resProblem.code === 0 ? resProblem.data : ''
+        // Object.assign(this.onlineProcess, this.toPercent([this.onlineProcess.allRollbackPercent, this.onlineProcess.preLess5MinPercent, this.onlineProcess.preRollbackPercent, this.onlineProcess.rollbackPercent, this.onlineProcess.noTestPercent]))
+        this.loadingOnlineProcess = false
+      }))
     },
     allCountAndProlemGet() {
       const pretermitSearch = { id: this.pauseTreeNode.id, type: this.pauseKey, startTime: this.timeInterval[0], endTime: this.timeInterval[1] }
@@ -475,11 +486,18 @@ export default {
         this.loadingOnlineProcess = false
       }))
     },
+    dataSearch() {
+      if (this.pauseKey === 0) {
+        this._initBusinessTreeAndBeginInfo()
+      } else if (this.pauseKey === 3) {
+        this.initDepartmentTree()
+      }
+    },
     handleSelect(key) {
       if (key === '0') {
         this.pauseKey = key
         this._initBusinessTreeAndBeginInfo()
-      } else if (key === '2') {
+      } else if (key === '3') {
         this.pauseKey = key
         this.initDepartmentTree()
       } else {
@@ -489,17 +507,19 @@ export default {
     toReportView(e) {
       this.$router.push({ name: '上线过程', query: { id: this.pauseTreeNode.id, type: this.pauseKey, dataType: e, startTime: this.timeInterval[0], endTime: this.timeInterval[1] }})
     },
+    toDefectView() {
+      this.$router.push({ name: '上线过程', query: { id: this.pauseTreeNode.id, type: this.pauseKey, startTime: this.timeInterval[0], endTime: this.timeInterval[1] }})
+    },
     handleSelectSecondary(key) {
       console.log(key)
     },
     handleNodeClick(data) {
       this.loadingOnlineProcess = true
       this.pauseTreeNode = data
-      if (!this.pauseTreeNode.child) {
-        this.pauseKey = 1
-      }
-      if (this.pauseTreeNode.models) {
-        this.pauseKey = 0
+      this.pauseKey = data.type
+      if (this.pauseKey === 3) {
+        this.deleteAfter()
+        return
       }
       this.allCountAndProlemGet()
     },
@@ -560,7 +580,7 @@ export default {
     .combine-table >>> .is-active
       font-weight bold
     .combine-table >>> th
-      background-color #F0F7FF !important
+      background-color #F1F4F7 !important
       font-size 10px
     .combine-table >>> .move-border-top
       border-top 0px

+ 12 - 5
src/views/quality/qualityProcess.vue

@@ -115,8 +115,9 @@ export default {
       tableData: [],
       input: '',
       curIndex: 1,
-      pageSize: 5,
-      total: 0
+      pageSize: 10,
+      total: 0,
+      processSerach: {}
     }
   },
   created() {
@@ -124,8 +125,14 @@ export default {
   },
   methods: {
     _initProcess() {
-      const processSerach = { id: this.$route.query.id, type: this.$route.query.type, dataType: this.$route.query.dataType, page: this.curIndex, perPage: this.pageSize }
-      getOnlineInfo(processSerach).then(res => {
+      if (!this.$route.query.dataType) {
+        console.log(this.$route.query.dataType)
+        this.processSerach = { id: this.$route.query.id, type: this.$route.query.type, page: this.curIndex, perPage: this.pageSize, startTime: this.$route.query.startTime, endTime: this.$route.query.endTime }
+      } else {
+        console.log(this.$route.query.dataType)
+        this.processSerach = { id: this.$route.query.id, type: this.$route.query.type, dataType: this.$route.query.dataType, page: this.curIndex, perPage: this.pageSize, startTime: this.$route.query.startTime, endTime: this.$route.query.endTime }
+      }
+      getOnlineInfo(this.processSerach).then(res => {
         this.tableData = res.data.data
         this.total = res.data.total
       })
@@ -165,7 +172,7 @@ export default {
           display flex
           justify-content space-around
     .block >>> th
-      background-color #F0F7FF !important
+      background-color #F1F4F7 !important
       font-size 10px
     .block >>> .el-table__body-wrapper  .cell
       font-size 10px