Эх сурвалжийг харах

Merge branch 'usecase_daily_0.0.2' of https://git.xiaojukeji.com/pu_qa_tool/thoth-frontend into usecase_daily_0.0.2

wenbobowen 4 жил өмнө
parent
commit
ffd5e1fa66

+ 6 - 1
src/components/searchHeader/index.vue

@@ -1,7 +1,7 @@
 <template>
   <div class="searchHeader">
     <div class="defaultBox Layout">
-      <div class="content mt5">
+      <div class="content" :class="{mt5: isMt5}">
         <searchBox
           :list="data.default"
           @change="$emit('search')"
@@ -58,6 +58,11 @@ export default {
       required: false,
       default: () => {}
     },
+    isMt5: {
+      type: Boolean,
+      required: false,
+      default: () => true
+    },
     isHiddenTime: {
       type: Boolean,
       required: false,

+ 1 - 1
src/components/searchHeader/searchForm.vue

@@ -1,7 +1,7 @@
 <template>
   <div class="searchForm">
     <div v-for="l in data" :key="l.key" class="Layout" style="display: inline-flex;padding-left: 15px; width:270px;" :style="l.styles">
-      <div class="name">{{ l.name }}</div>
+      <div class="name" :style="l.nameStyles">{{ l.name }}</div>
       <el-select
         v-if="l.type === 'select'"
         v-model="l.value"

+ 3 - 0
src/styles/index.less

@@ -144,6 +144,9 @@ div:focus {
 .mb25 {
   margin-bottom: 25px;
 }
+.mb20 {
+  margin-bottom: 20px;
+}
 .mb10 {
   margin-bottom: 10px;
 }

+ 6 - 3
src/views/dataBigManage/components/dataItem/index.vue

@@ -19,7 +19,7 @@
             {{ item.subTitle }}%
           </span>
         </span>
-        <span v-else v-html="item.subTitle" />
+        <span v-else style="font-weight: 600" v-html="item.subTitle" />
       </div>
     </div>
   </div>
@@ -69,10 +69,13 @@ export default {
       color: #999;
       font-size: 12px;
      .item-up {
-        color:#F32850
+       color:#F32850;
+       font-weight: 600;
       }
       .item-down {
-        color:#9FFF39
+        //color:#9FFF39
+        color:#7Ed321;
+        font-weight: 600;
       }
     }
   }

+ 6 - 0
src/views/dataBigManage/components/drawerModal/components/table.vue

@@ -4,7 +4,9 @@
       :data="tableList"
       class="bug_tableHeader"
       :header-cell-style="{ color: '#4A4A4A', fontSize: '14px', fontWeight: '500' }"
+      :cell-style="{ 'font-size':'14px','color':'rgba(102,102,102,1)' }"
       row-key="id"
+      size="mini"
       style="width: auto;"
       :height="tableHeight"
     >
@@ -46,6 +48,10 @@
             <div class="drawer-id">{{ `${columnItem.topName} - ${scope.row[columnItem.topKey]}` }}</div>
             <div class="drawer-name" @click.stop="columnItemChange(columnItem, scope.row)">{{ scope.row[columnItem.key] }}</div>
           </div>
+          <!-- 链接点击跳转 -->
+          <div v-else-if="columnItem.type === 'link'">
+            <div class="drawer-name" @click.stop="columnItemChange(columnItem, scope.row)">{{ scope.row[columnItem.key] }}</div>
+          </div>
           <!-- 插槽 -->
           <div v-else-if="columnItem.type === 'slot'">
             <slot :name="columnItem.slotName" :scope="scope" />

+ 7 - 4
src/views/dataBigManage/components/drawerModal/drawerModalData.js

@@ -36,8 +36,9 @@ export const columns = {
     {
       label: '问题名称',
       key: 'title',
-      minWidth: 100,
-      align: 'center'
+      minWidth: 360,
+      type: 'link',
+      align: 'left'
     },
     {
       label: '不可用时长',
@@ -49,7 +50,9 @@ export const columns = {
       label: '改进方案',
       key: 'type',
       minWidth: 100,
-      align: 'center'
+      type: 'slot',
+      align: 'center',
+      slotName: 'starFlowerDoneSlot'
     },
     {
       label: '发生时间',
@@ -155,7 +158,7 @@ export const columns = {
     },
     {
       label: '状态',
-      key: 'status',
+      key: 'statusString',
       minWidth: 90,
       align: 'left'
     }

+ 52 - 13
src/views/dataBigManage/components/drawerModal/index.vue

@@ -37,6 +37,14 @@
       <template #creatorObjectSlot="{scope}">
         <div v-if="scope && scope.row && scope.row.creatorObject" @click.stop>{{ scope.row.creatorObject.name }}</div>
       </template>
+      <!-- 质量:线上问题_改进方案 -->
+      <template #starFlowerDoneSlot="{scope}">
+        <div @click.stop>
+          <div>{{ scope.row.done + scope.row.undone }}项任务</div>
+          <div v-if="scope.row.done === scope.row.done + scope.row.undone" class="antdv3-tag antdv3-tag-green">已完成:{{ scope.row.done }}项</div>
+          <div v-else class="antdv3-tag antdv3-tag-orange">已完成:{{ scope.row.done }}项</div>
+        </div>
+      </template>
     </dmTable>
     <!-- 下拉 -->
     <div class="qz-footer-laout" @click.stop>
@@ -505,11 +513,11 @@ export default {
         pageSize: this.paging.pageSize
       })
       if (res.code === 200) {
-        this.tableList = res.data
-        this.paging.pageTotal = this.ids.length
+        this.tableList = res.data.result
+        this.paging.pageTotal = res.data.total
         this.paging = { ...paging }
         this.loading = false
-        console.log(491, this.tableList)
+        // console.log(491, this.tableList)
       }
     },
     // getProjectList // 需求任务项目列表: 半浮层
@@ -522,8 +530,8 @@ export default {
         pageSize: 15
       })
       if (res.code === 200) {
-        this.tableList = res.data
-        this.paging.pageTotal = res.total
+        this.tableList = res.data.result
+        this.paging.pageTotal = res.data.total
         this.paging = { ...paging }
         this.loading = false
       }
@@ -725,20 +733,16 @@ export default {
         this.tableHeight = 'calc(100vh - 363px)'
       } else if (this.title.search(/需求周期|新增项目|新增任务|需求人力|任务周期|缺陷修复时长|延期准出率|延期提测率/) > -1) {
         this.tableHeight = 'calc(100vh - 288px)'
-      } else if (this.title.search(/需求方向分布图数据|模块分布图数据/) > -1) {
-        this.tableHeight = 'calc(100vh - 200px)'
-      } else if (this.title.search(/累计新增|PRD评审通过|技术准入|累计上线|累计hold|累计修复|累计reopen/) > -1) {
-        this.tableHeight = 'calc(100vh - 134px)'
       } else if (this.title.search(/需求|任务|项目/) > -1) {
         // 吞吐量: 需求
         this.tableHeight = 'calc(100vh - 188px)'
       } else if (this.title === '缺陷24小时修复率') {
         this.tableHeight = 'calc(100vh - 328px)'
-      } else if (this.title.search(/新增缺陷|提测打回率|reopen|准出不通过/) > -1) {
-        this.tableHeight = 'calc(100vh - 136px)'
       } else {
         this.tableHeight = 'calc(100vh - 136px)'
-        // this.tableHeight = 'calc(100vh - 10px)'
+      }
+      if (this.headerTitle === '质量') {
+        this.tableHeight = 'calc(100vh - 136px)'
       }
       if (this.headerTitle === '吞吐量') {
         this.tableHeight = 'calc(100vh - 288px)'
@@ -748,7 +752,10 @@ export default {
     // 表格跳转
     dmTableChange({ column, row }) {
       // console.log(column, row)
-      if (this.headerTitle === '吞吐量') {
+      if (this.headerTitle === '质量' && this.drawerData.label === '新增问题') {
+        const url = `http://odin.xiaojukeji.com/#/risk/starflower/casedetail?id=${row.id}&name=${row.title}`
+        window.open(url, '_blank')
+      } else if (this.headerTitle === '吞吐量') {
         if (this.title.search(/需求/) > -1) {
           this.jumper(row, '需求')
         }
@@ -880,6 +887,38 @@ export default {
   color: #444444;
 }
 /* E 时间轴 */
+/* S 质量:线上问题_改进方案 */
+.antdv3-tag{
+  box-sizing: border-box;
+  color: rgba(0,0,0,.65);
+  font-variant: tabular-nums;
+  list-style: none;
+  font-feature-settings: "tnum";
+  display: inline-block;
+  height: auto;
+  margin: 0 8px 0 0;
+  padding: 0 7px;
+  font-size: 12px;
+  line-height: 20px;
+  white-space: nowrap;
+  background: #fafafa;
+  border: 1px solid #d9d9d9;
+  border-radius: 2px;
+  cursor: default;
+  opacity: 1;
+  transition: all .3s cubic-bezier(.78,.14,.15,.86);
+}
+.antdv3-tag-orange {
+  color: #fa8c16;
+  background: #fff7e6;
+  border-color: #ffd591;
+}
+.antdv3-tag-green {
+  color: #52c41a;
+  background: #f6ffed;
+  border-color: #b7eb8f;
+}
+/* E 质量:线上问题_改进方案 */
 .qz-footer-laout {
   display: flex;
   justify-content: space-between;

+ 4 - 1
src/views/dataBigManage/components/efficiencyModule/index.vue

@@ -367,6 +367,7 @@ export default {
           .num {
             font-size: 18px;
             cursor: pointer;
+            font-weight: 600;
           }
           .unit {
             font-size: 14px;
@@ -379,6 +380,7 @@ export default {
           }
           .num {
             font-size: 12px;
+            font-weight: 600;
           }
         }
       }
@@ -425,7 +427,8 @@ export default {
       color:#F32850
     }
     .item-down {
-      color:#9FFF39
+      //color:#9FFF39
+      color:#7Ed321
     }
 }
 </style>

+ 1 - 0
src/views/dataBigManage/components/qualityModule/index.vue

@@ -429,6 +429,7 @@ export default {
     align-items: center;
     .rollBackItem {
       color: #666;
+      margin-bottom: 10px;
       .numText {
         color: #409EFF;
         font-weight: 600;

+ 9 - 2
src/views/dataBigManage/components/throughputModule/index.vue

@@ -15,7 +15,7 @@
             @click="changeTab('wholeTab', item)"
           >{{ item }}</span>
         </div>
-        <div class="list">
+        <div v-loading="listLoading" class="list">
           <div
             v-for="item in mainData.throughputList"
             :key="item.pointer"
@@ -118,6 +118,11 @@ export default {
       type: Boolean,
       required: false,
       default: false
+    },
+    listLoading: {
+      type: Boolean,
+      required: false,
+      default: false
     }
   },
   data() {
@@ -193,6 +198,7 @@ export default {
       min-width: 100px;
     }
     .count {
+      cursor: pointer;
       font-weight: 600;
     }
   }
@@ -200,7 +206,8 @@ export default {
     color:#F32850
   }
   .item-down {
-    color:#9FFF39
+    //color:#9FFF39
+    color:#7Ed321
   }
   .itemBox {
     box-shadow: 0px 6px 50px rgba(0, 0, 0, 0.05);

+ 5 - 2
src/views/dataBigManage/data.js

@@ -7,7 +7,9 @@ export const listSearchData = {
         key: 'deptCode',
         type: 'cascader',
         placeholder: '请选择部门',
-        option: []
+        option: [],
+        styles: { minWidth: '435px', width: 'auto' },
+        nameStyles: { minWidth: '53px' }
       },
       {
         name: '时间',
@@ -16,7 +18,8 @@ export const listSearchData = {
         valueFormat: 'yyyy-MM-dd HH:mm:ss',
         type: 'showItemDataPicker',
         placeholder: '请选择时间',
-        styles: { minWidth: '270px', width: 'auto' }
+        styles: { minWidth: '270px', width: 'auto' },
+        nameStyles: { minWidth: '53px' }
       }
     ]
   ],

+ 18 - 6
src/views/dataBigManage/index.vue

@@ -2,6 +2,7 @@
   <div class="page-wrap data-big-wrapper" style="min-width: 1320px" @click="openDrawer=false">
     <div class="page-header detial">
       <searchHeader
+        :is-mt5="false"
         :data="listSearch"
         :is-hidden-time="true"
         @search="search"
@@ -10,7 +11,7 @@
       />
     </div>
     <div class="page-content detial">
-      <header class="header mb25">
+      <header class="header mb10">
         <headTitle title="质量" />
       </header>
       <qualityModule
@@ -19,16 +20,17 @@
         @search="qualitySearch"
         @checkDetialModal="(data) => checkDetialModal({...data, headerTitle: '质量' })"
       />
-      <header class="header mb25 mt40">
+      <header class="header mb10 mt40">
         <headTitle title="吞吐量" />
       </header>
       <throughputModule
         :datas="mainData.throughput"
         :loading="throughputLoading"
+        :list-loading="throughputListLoading"
         @search="qualitySearch"
         @checkDetialModal="(data) => checkDetialModal({...data, headerTitle: '吞吐量' })"
       />
-      <header class="header mb25 mt40">
+      <header class="header mb10 mt40">
         <headTitle title="效率" />
       </header>
       <efficiencyModule
@@ -109,6 +111,7 @@ export default {
       },
       qualityLoading: false,
       throughputLoading: false,
+      throughputListLoading: false,
       efficiencyLoading: false
     }
   },
@@ -183,7 +186,7 @@ export default {
       } else if (key === 'offlineProblemViweType') {
         this.getOfflineProblemChartData(this.params)
       } else if (key === 'wholeTab') {
-        this.getThroughputData(this.params)
+        this.getThroughputData(this.params, key)
       } else if (key === 'requirementBacklogType') {
         this.getRequirementBacklogRateChartData(this.params)
       }
@@ -246,6 +249,7 @@ export default {
         }
         this.qualityLoading = false
       }).catch((error) => {
+        console.log(error)
         this.qualityLoading = false
       })
     },
@@ -284,6 +288,7 @@ export default {
         }
         this.throughputLoading = false
       }).catch((error) => {
+        console.log(error)
         this.throughputLoading = false
       })
     },
@@ -321,8 +326,13 @@ export default {
       })
     },
     // 需求任务项目列表
-    getThroughputData(params) {
-      this.throughputLoading = true
+    getThroughputData(params, key) {
+      if (key) {
+        this.throughputListLoading = true
+      } else {
+        this.throughputLoading = true
+      }
+
       getThroughputDataRequest({
         ...params,
         extensionType: params.wholeTab
@@ -332,8 +342,10 @@ export default {
           throughput: { ...this.mainData.throughput, throughputList: res.data }
         }
         this.throughputLoading = false
+        this.throughputListLoading = false
       }).catch(() => {
         this.throughputLoading = false
+        this.throughputListLoading = false
       })
     },
     // 需求积压率