Browse Source

表格高度优化

master
陈裕财 5 years ago
parent
commit
861873a264
  1. 4
      config/index.js
  2. 6
      src/views/xm/core/xmIteration/XmIterationMng.vue
  3. 6
      src/views/xm/core/xmIterationMenu/XmIterationMenuMng.vue
  4. 6
      src/views/xm/core/xmMenu/XmMenuMng.vue
  5. 6
      src/views/xm/core/xmMenu/XmMenuSelect.vue
  6. 6
      src/views/xm/core/xmMenu/XmMenuWithPlan.vue
  7. 6
      src/views/xm/core/xmMenuState/XmMenuStateMng.vue
  8. 6
      src/views/xm/core/xmProduct/XmProductMng.vue
  9. 6
      src/views/xm/core/xmProduct/XmProductSelect.vue
  10. 5
      src/views/xm/core/xmProject/XmProjectList.vue
  11. 6
      src/views/xm/core/xmProject/XmProjectMng.vue
  12. 6
      src/views/xm/core/xmProjectPhase/XmProjectPhaseMng.vue
  13. 4
      src/views/xm/core/xmProjectPhase/XmProjectPhaseSelect.vue
  14. 9
      src/views/xm/core/xmQuestion/XmQuestionMng.vue
  15. 6
      src/views/xm/core/xmRecord/XmRecord.vue
  16. 4
      src/views/xm/core/xmTask/XmTaskList.vue
  17. 16
      src/views/xm/core/xmTask/XmTaskMng.vue
  18. 6
      src/views/xm/core/xmTaskExecuser/XmTaskExecuserMng.vue
  19. 8
      src/views/xm/core/xmTestCase/XmTestCaseMng.vue
  20. 6
      src/views/xm/core/xmTestCaseExec/XmTestCaseExecMng.vue

4
config/index.js

@ -11,7 +11,7 @@ module.exports = {
assetsSubDirectory: 'static', assetsSubDirectory: 'static',
assetsPublicPath: '/', assetsPublicPath: '/',
proxyTable: { proxyTable: {
/**
'/api/m1/xm': { '/api/m1/xm': {
target: 'http://localhost:7067', target: 'http://localhost:7067',
changeOrigin: true, changeOrigin: true,
@ -19,7 +19,7 @@ module.exports = {
'^/api/m1/xm': '/xm' '^/api/m1/xm': '/xm'
} }
}, },
/**
'/api/m1/workflow': { '/api/m1/workflow': {
target: 'http://localhost:7080', target: 'http://localhost:7080',
changeOrigin: true, changeOrigin: true,

6
src/views/xm/core/xmIteration/XmIterationMng.vue

@ -11,7 +11,7 @@
</el-row> </el-row>
<el-row v-if="!simple" class="app-container"> <el-row v-if="!simple" class="app-container">
<!--列表 XmIteration 迭代定义--> <!--列表 XmIteration 迭代定义-->
<el-table :max-height="tableHeight" v-if="!gstcVisible" :data="xmIterationTreeData" row-key="id" default-expand-all :tree-props="{children: 'children', hasChildren: 'hasChildren'}" @sort-change="sortChange" highlight-current-row v-loading="load.list" border @selection-change="selsChange" @row-click="rowClick" style="width: 100%;">
<el-table ref="table" :max-height="tableHeight" v-if="!gstcVisible" :data="xmIterationTreeData" row-key="id" default-expand-all :tree-props="{children: 'children', hasChildren: 'hasChildren'}" @sort-change="sortChange" highlight-current-row v-loading="load.list" border @selection-change="selsChange" @row-click="rowClick" style="width: 100%;">
<el-table-column type="selection" aria-disabled width="55"></el-table-column> <el-table-column type="selection" aria-disabled width="55"></el-table-column>
<el-table-column prop="iterationName" label="迭代名称" min-width="160" > <el-table-column prop="iterationName" label="迭代名称" min-width="160" >
<template slot-scope="scope"> <template slot-scope="scope">
@ -401,7 +401,9 @@
}, },
mounted() { mounted() {
this.$nextTick(() => { this.$nextTick(() => {
this.tableHeight = window.innerHeight - 250;
var clientRect=this.$refs.table.$el.getBoundingClientRect();
var subHeight=65;
this.tableHeight = window.innerHeight -clientRect.y - this.$refs.table.$el.offsetTop-subHeight;
this.getXmIterations(); this.getXmIterations();
}); });
/** /**

6
src/views/xm/core/xmIterationMenu/XmIterationMenuMng.vue

@ -16,7 +16,7 @@
</el-row> </el-row>
<el-row class="app-container"> <el-row class="app-container">
<!--列表 XmIterationMenu 迭代定义--> <!--列表 XmIterationMenu 迭代定义-->
<el-table :max-height="tableHeight" :data="xmIterationMenusTreeData" default-expand-all row-key="menuId" :tree-props="{children: 'children', hasChildren: 'hasChildren'}" @sort-change="sortChange" highlight-current-row v-loading="load.list" border @selection-change="selsChange" @row-click="rowClick" style="width: 100%;">
<el-table ref="table" :max-height="tableHeight" :data="xmIterationMenusTreeData" default-expand-all row-key="menuId" :tree-props="{children: 'children', hasChildren: 'hasChildren'}" @sort-change="sortChange" highlight-current-row v-loading="load.list" border @selection-change="selsChange" @row-click="rowClick" style="width: 100%;">
<el-table-column type="selection" width="45"></el-table-column> <el-table-column type="selection" width="45"></el-table-column>
<el-table-column prop="menuName" label="故事名称" min-width="140" > <el-table-column prop="menuName" label="故事名称" min-width="140" >
<template slot-scope="scope"> <template slot-scope="scope">
@ -323,7 +323,9 @@
}, },
mounted() { mounted() {
this.$nextTick(() => { this.$nextTick(() => {
this.tableHeight = window.innerHeight - 250;
var clientRect=this.$refs.table.$el.getBoundingClientRect();
var subHeight=65;
this.tableHeight = window.innerHeight -clientRect.y - this.$refs.table.$el.offsetTop-subHeight;
this.getXmIterationMenus(); this.getXmIterationMenus();
}); });
/** /**

6
src/views/xm/core/xmMenu/XmMenuMng.vue

@ -42,7 +42,7 @@
</el-row> </el-row>
<el-row v-show="batchEditVisible" class="app-container"> <el-row v-show="batchEditVisible" class="app-container">
<el-table :max-height="tableHeight" :data="xmMenusTreeData" class="drag-table" default-expand-all row-key="menuId" :tree-props="{children: 'children', hasChildren: 'hasChildren'}" @sort-change="sortChange" highlight-current-row v-loading="load.list" border @selection-change="selsChange" @row-click="rowClick" style="width: 100%;">
<el-table ref="table" :max-height="tableHeight" :data="xmMenusTreeData" class="drag-table" default-expand-all row-key="menuId" :tree-props="{children: 'children', hasChildren: 'hasChildren'}" @sort-change="sortChange" highlight-current-row v-loading="load.list" border @selection-change="selsChange" @row-click="rowClick" style="width: 100%;">
<el-table-column sortable type="selection" width="45"></el-table-column> <el-table-column sortable type="selection" width="45"></el-table-column>
<el-table-column sortable prop="seqNo" label="序号" min-width="100"> <el-table-column sortable prop="seqNo" label="序号" min-width="100">
<template slot-scope="scope"> <template slot-scope="scope">
@ -1042,7 +1042,9 @@
}, },
mounted() { mounted() {
this.$nextTick(() => { this.$nextTick(() => {
this.tableHeight = window.innerHeight - 250;
var clientRect=this.$refs.table.$el.getBoundingClientRect();
var subHeight=65;
this.tableHeight = window.innerHeight -clientRect.y - this.$refs.table.$el.offsetTop-subHeight;
this.getXmMenus(); this.getXmMenus();
}); });
// //

6
src/views/xm/core/xmMenu/XmMenuSelect.vue

@ -16,7 +16,7 @@
<el-button type="primary" v-if="multi" v-on:click="multiSelectedConfirm">确认选择</el-button> <el-button type="primary" v-if="multi" v-on:click="multiSelectedConfirm">确认选择</el-button>
</el-row> </el-row>
<el-row style="padding-top:12px;"> <el-row style="padding-top:12px;">
<el-table :max-height="tableHeight" :data="xmMenusTreeData" default-expand-all row-key="menuId" :tree-props="{children: 'children', hasChildren: 'hasChildren'}" @sort-change="sortChange" highlight-current-row v-loading="load.list" border @selection-change="selsChange" @row-click="rowClick" style="width: 100%;">
<el-table ref="table" :max-height="tableHeight" :data="xmMenusTreeData" default-expand-all row-key="menuId" :tree-props="{children: 'children', hasChildren: 'hasChildren'}" @sort-change="sortChange" highlight-current-row v-loading="load.list" border @selection-change="selsChange" @row-click="rowClick" style="width: 100%;">
<el-table-column v-if="multi" type="selection" width="50"></el-table-column> <el-table-column v-if="multi" type="selection" width="50"></el-table-column>
<el-table-column prop="menuName" label="故事名称" min-width="140" > <el-table-column prop="menuName" label="故事名称" min-width="140" >
<template slot-scope="scope"> <template slot-scope="scope">
@ -267,7 +267,9 @@
mounted() { mounted() {
this.$nextTick(() => { this.$nextTick(() => {
this.getXmMenus(); this.getXmMenus();
this.tableHeight = window.innerHeight - 250;
var clientRect=this.$refs.table.$el.getBoundingClientRect();
var subHeight=65;
this.tableHeight = window.innerHeight -clientRect.y - this.$refs.table.$el.offsetTop-subHeight;
}); });
} }
} }

6
src/views/xm/core/xmMenu/XmMenuWithPlan.vue

@ -14,7 +14,7 @@
<el-button v-if=" batchEditVisible==true " @click="noBatchEdit" v-loading="load.edit" icon="el-icon-back">返回</el-button> <el-button v-if=" batchEditVisible==true " @click="noBatchEdit" v-loading="load.edit" icon="el-icon-back">返回</el-button>
</el-row> </el-row>
<el-row class="app-container" v-show="!batchEditVisible"> <el-row class="app-container" v-show="!batchEditVisible">
<el-table :max-height="tableHeight" v-if="!gstcVisible" :data="xmMenusTreeData" default-expand-all row-key="menuId" :tree-props="{children: 'children', hasChildren: 'hasChildren'}" @sort-change="sortChange" highlight-current-row v-loading="load.list" border @selection-change="selsChange" @row-click="rowClick" style="width: 100%;">
<el-table ref="table" :max-height="tableHeight" v-if="!gstcVisible" :data="xmMenusTreeData" default-expand-all row-key="menuId" :tree-props="{children: 'children', hasChildren: 'hasChildren'}" @sort-change="sortChange" highlight-current-row v-loading="load.list" border @selection-change="selsChange" @row-click="rowClick" style="width: 100%;">
<el-table-column sortable type="selection" width="40"></el-table-column> <el-table-column sortable type="selection" width="40"></el-table-column>
<el-table-column prop="menuName" label="故事名称" min-width="150" > <el-table-column prop="menuName" label="故事名称" min-width="150" >
<template slot-scope="scope"> <template slot-scope="scope">
@ -513,7 +513,9 @@
}, },
mounted() { mounted() {
this.$nextTick(() => { this.$nextTick(() => {
this.tableHeight = window.innerHeight - 250;
var clientRect=this.$refs.table.$el.getBoundingClientRect();
var subHeight=65;
this.tableHeight = window.innerHeight -clientRect.y - this.$refs.table.$el.offsetTop-subHeight;
this.getXmMenus(); this.getXmMenus();
}); });
listOption([{categoryId:'all',itemCode:'xmMenuPlanStatus'} ]).then(res=>{ listOption([{categoryId:'all',itemCode:'xmMenuPlanStatus'} ]).then(res=>{

6
src/views/xm/core/xmMenuState/XmMenuStateMng.vue

@ -9,7 +9,7 @@
<el-button type="primary" v-if=" batchEditVisible==true " @click="noBatchEdit" v-loading="load.edit">返回</el-button> <el-button type="primary" v-if=" batchEditVisible==true " @click="noBatchEdit" v-loading="load.edit">返回</el-button>
</el-row> </el-row>
<el-row class="app-container" v-show="!batchEditVisible"> <el-row class="app-container" v-show="!batchEditVisible">
<el-table :data="xmMenusTreeData" default-expand-all row-key="menuId" :tree-props="{children: 'children', hasChildren: 'hasChildren'}" @sort-change="sortChange" highlight-current-row v-loading="load.list" border @selection-change="selsChange" @row-click="rowClick" style="width: 100%;">
<el-table ref="table" :data="xmMenusTreeData" default-expand-all row-key="menuId" :tree-props="{children: 'children', hasChildren: 'hasChildren'}" @sort-change="sortChange" highlight-current-row v-loading="load.list" border @selection-change="selsChange" @row-click="rowClick" style="width: 100%;">
<el-table-column sortable type="selection" width="40"></el-table-column> <el-table-column sortable type="selection" width="40"></el-table-column>
<el-table-column prop="menuName" label="故事名称" min-width="150" > <el-table-column prop="menuName" label="故事名称" min-width="150" >
<template slot-scope="scope"> <template slot-scope="scope">
@ -481,7 +481,9 @@
}, },
mounted() { mounted() {
this.$nextTick(() => { this.$nextTick(() => {
this.tableHeight = window.innerHeight - 250;
var clientRect=this.$refs.table.$el.getBoundingClientRect();
var subHeight=50;
this.tableHeight = window.innerHeight -clientRect.y - this.$refs.table.$el.offsetTop-subHeight;
this.getXmMenus(); this.getXmMenus();
}); });
listOption([{categoryId:'all',itemCode:'xmMenuStateStatus'} ]).then(res=>{ listOption([{categoryId:'all',itemCode:'xmMenuStateStatus'} ]).then(res=>{

6
src/views/xm/core/xmProduct/XmProductMng.vue

@ -13,7 +13,7 @@
</el-row> </el-row>
<el-row class="app-container"> <el-row class="app-container">
<!--列表 XmProduct 产品表--> <!--列表 XmProduct 产品表-->
<el-table :max-height="tableHeight" :data="xmProducts" @sort-change="sortChange" highlight-current-row v-loading="load.list" border @selection-change="selsChange" @row-click="rowClick" style="width: 100%;">
<el-table ref="table" :max-height="tableHeight" :data="xmProducts" @sort-change="sortChange" highlight-current-row v-loading="load.list" border @selection-change="selsChange" @row-click="rowClick" style="width: 100%;">
<el-table-column sortable type="selection" width="55"></el-table-column> <el-table-column sortable type="selection" width="55"></el-table-column>
<el-table-column sortable type="index" width="55"></el-table-column> <el-table-column sortable type="index" width="55"></el-table-column>
<el-table-column prop="productName" label="产品名称" min-width="150" > <el-table-column prop="productName" label="产品名称" min-width="150" >
@ -337,7 +337,9 @@
}, },
mounted() { mounted() {
this.$nextTick(() => { this.$nextTick(() => {
this.tableHeight = window.innerHeight - 250;
var clientRect=this.$refs.table.$el.getBoundingClientRect();
var subHeight=65;
this.tableHeight = window.innerHeight -clientRect.y - this.$refs.table.$el.offsetTop-subHeight;
this.getXmProducts(); this.getXmProducts();
}); });
} }

6
src/views/xm/core/xmProduct/XmProductSelect.vue

@ -2,7 +2,7 @@
<section> <section>
<el-row > <el-row >
<!--列表 XmProduct 产品表--> <!--列表 XmProduct 产品表-->
<el-table :max-height="tableHeight" :data="xmProducts" @sort-change="sortChange" highlight-current-row v-loading="load.list" border @selection-change="selsChange" @row-click="rowClick" style="width: 100%;">
<el-table ref="table" :max-height="tableHeight" :data="xmProducts" @sort-change="sortChange" highlight-current-row v-loading="load.list" border @selection-change="selsChange" @row-click="rowClick" style="width: 100%;">
<el-table-column sortable type="index" width="55"></el-table-column> <el-table-column sortable type="index" width="55"></el-table-column>
<el-table-column prop="productName" label="产品名称" min-width="150" > <el-table-column prop="productName" label="产品名称" min-width="150" >
<template slot="header" slot-scope="scope"> <template slot="header" slot-scope="scope">
@ -160,7 +160,9 @@
}, },
mounted() { mounted() {
this.$nextTick(() => { this.$nextTick(() => {
this.tableHeight = window.innerHeight - 250;
var clientRect=this.$refs.table.$el.getBoundingClientRect();
var subHeight=65;
this.tableHeight = window.innerHeight -clientRect.y - this.$refs.table.$el.offsetTop-subHeight;
this.getXmProducts(); this.getXmProducts();
}); });
} }

5
src/views/xm/core/xmProject/XmProjectList.vue

@ -8,7 +8,7 @@
</el-input> </el-input>
</el-row> </el-row>
<el-row class="app-container"> <el-row class="app-container">
<el-table stripe :data="xmProjects" highlight-current-row v-loading="load.list" style="width: 100%;">
<el-table ref="table" :max-height="tableHeight" stripe :data="xmProjects" highlight-current-row v-loading="load.list" style="width: 100%;">
<el-table-column type="index" label="序号" width="55" ></el-table-column> <el-table-column type="index" label="序号" width="55" ></el-table-column>
<el-table-column prop="code" label="项目编号" min-width="80" ></el-table-column> <el-table-column prop="code" label="项目编号" min-width="80" ></el-table-column>
<el-table-column prop="name" label="标题名称" min-width="80" ></el-table-column> <el-table-column prop="name" label="标题名称" min-width="80" ></el-table-column>
@ -156,6 +156,9 @@
}, },
mounted() { mounted() {
this.$nextTick(() => { this.$nextTick(() => {
var clientRect=this.$refs.table.$el.getBoundingClientRect();
var subHeight=50;
this.tableHeight = window.innerHeight -clientRect.y - this.$refs.table.$el.offsetTop-subHeight;
this.showInfo = false; this.showInfo = false;
this.getXmProjects(); this.getXmProjects();
}); });

6
src/views/xm/core/xmProject/XmProjectMng.vue

@ -89,7 +89,7 @@
</el-col> </el-col>
</el-row> </el-row>
<el-table v-cloak v-show="!showType" stripe :data="ScreenData" @sort-change="sortChange" highlight-current-row v-loading="load.list" @selection-change="selsChange" @row-click="rowClick" style="width: 100%;">
<el-table ref="table" v-cloak v-show="!showType" stripe :data="ScreenData" @sort-change="sortChange" highlight-current-row v-loading="load.list" @selection-change="selsChange" @row-click="rowClick" style="width: 100%;">
<el-table-column prop="code" label="项目编号" min-width="120" ></el-table-column> <el-table-column prop="code" label="项目编号" min-width="120" ></el-table-column>
<el-table-column prop="name" label="标题" min-width="200" > <el-table-column prop="name" label="标题" min-width="200" >
<template slot-scope="scope"> <template slot-scope="scope">
@ -639,7 +639,9 @@
this.filters.productName=this.$route.params.productName; this.filters.productName=this.$route.params.productName;
} }
this.$nextTick(() => { this.$nextTick(() => {
this.tableHeight = window.innerHeight - 200;
var clientRect=this.$refs.table.$el.getBoundingClientRect();
var subHeight=65;
this.tableHeight = window.innerHeight -clientRect.y - this.$refs.table.$el.offsetTop-subHeight;
this.showInfo = false; this.showInfo = false;
this.getXmProjects(); this.getXmProjects();
}); });

6
src/views/xm/core/xmProjectPhase/XmProjectPhaseMng.vue

@ -50,7 +50,7 @@
</el-row> </el-row>
<el-row class="app-container" v-show="batchEditVisible==false"> <el-row class="app-container" v-show="batchEditVisible==false">
<!--列表 XmProjectPhase xm_project_phase--> <!--列表 XmProjectPhase xm_project_phase-->
<el-table :max-height="tableHeight" v-show="!gstcVisible " default-expand-all :data="projectPhaseTreeData" :summary-method="getSummariesForNoBatchEdit" :show-summary="true" row-key="id" :tree-props="{children: 'children', hasChildren: 'hasChildren'}" @sort-change="sortChange" highlight-current-row v-loading="load.list" border @selection-change="selsChange" @row-click="rowClick" style="width: 100%;">
<el-table ref="table" :max-height="tableHeight" v-show="!gstcVisible " default-expand-all :data="projectPhaseTreeData" :summary-method="getSummariesForNoBatchEdit" :show-summary="true" row-key="id" :tree-props="{children: 'children', hasChildren: 'hasChildren'}" @sort-change="sortChange" highlight-current-row v-loading="load.list" border @selection-change="selsChange" @row-click="rowClick" style="width: 100%;">
<el-table-column sortable type="selection" width="40"></el-table-column> <el-table-column sortable type="selection" width="40"></el-table-column>
<el-table-column prop="phaseName" label="阶段名称" min-width="150" > <el-table-column prop="phaseName" label="阶段名称" min-width="150" >
<template slot-scope="scope"> <template slot-scope="scope">
@ -1295,7 +1295,9 @@ import XmProjectGroupSelect from '../xmProjectGroup/XmProjectGroupSelect.vue';
this.getXmProjectPhases(); this.getXmProjectPhases();
} }
this.tableHeight = window.innerHeight - 300;
var clientRect=this.$refs.table.$el.getBoundingClientRect();
var subHeight=65;
this.tableHeight = window.innerHeight -clientRect.y - this.$refs.table.$el.offsetTop-subHeight;
listOption([ listOption([
{categoryId:'all',itemCode:'xmPhaseStatus'} {categoryId:'all',itemCode:'xmPhaseStatus'}
]).then(res=>{ ]).then(res=>{

4
src/views/xm/core/xmProjectPhase/XmProjectPhaseSelect.vue

@ -417,7 +417,9 @@
mounted() { mounted() {
this.$nextTick(() => { this.$nextTick(() => {
this.tableHeight = window.innerHeight - 250;
var clientRect=this.$refs.selectPhaseTable.$el.getBoundingClientRect();
var subHeight=65;
this.tableHeight = window.innerHeight -clientRect.y - this.$refs.selectPhaseTable.$el.offsetTop-subHeight;
if(this.selProject){ if(this.selProject){
this.getXmProjectPhases(); this.getXmProjectPhases();
} }

9
src/views/xm/core/xmQuestion/XmQuestionMng.vue

@ -1,8 +1,6 @@
<template> <template>
<section> <section>
<el-row class="xm-question">
<el-row class="app-container"> <el-row class="app-container">
<el-select v-model="filters.bugStatus" placeholder="请选择状态" style="width:15%;" clearable @change="changeBugStatus"> <el-select v-model="filters.bugStatus" placeholder="请选择状态" style="width:15%;" clearable @change="changeBugStatus">
<el-option v-for="(b,index) in options['bugStatus']" :value="b.optionValue" :key="index" :label="b.optionName">{{b.optionName}} <el-option v-for="(b,index) in options['bugStatus']" :value="b.optionValue" :key="index" :label="b.optionName">{{b.optionName}}
</el-option> </el-option>
@ -63,7 +61,7 @@
</el-row> </el-row>
<el-row class="app-container"> <el-row class="app-container">
<!--列表 XmQuestion xm_question--> <!--列表 XmQuestion xm_question-->
<el-table :max-height="tableHeight" :data="xmQuestions" @sort-change="sortChange" highlight-current-row v-loading="load.list" border @selection-change="selsChange" @row-click="rowClick" style="width: 100%;">
<el-table ref="table" :max-height="tableHeight" :data="xmQuestions" @sort-change="sortChange" highlight-current-row v-loading="load.list" border @selection-change="selsChange" @row-click="rowClick" style="width: 100%;">
<el-table-column sortable type="index" width="45"></el-table-column> <el-table-column sortable type="index" width="45"></el-table-column>
<el-table-column prop="name" label="问题名称" min-width="200"> <el-table-column prop="name" label="问题名称" min-width="200">
<template slot-scope="scope"> <template slot-scope="scope">
@ -136,7 +134,6 @@
<el-dialog title="选中项目" :visible.sync="selectProjectVisible" width="80%" append-to-body :close-on-click-modal="false"> <el-dialog title="选中项目" :visible.sync="selectProjectVisible" width="80%" append-to-body :close-on-click-modal="false">
<xm-project-list @project-confirm="onPorjectConfirm"></xm-project-list> <xm-project-list @project-confirm="onPorjectConfirm"></xm-project-list>
</el-dialog> </el-dialog>
</el-row>
</section> </section>
</template> </template>
@ -682,7 +679,9 @@
this.filters.selProject=this.selProject this.filters.selProject=this.selProject
} }
this.$nextTick(() => { this.$nextTick(() => {
this.tableHeight = window.innerHeight-250;
var clientRect=this.$refs.table.$el.getBoundingClientRect();
var subHeight=65;
this.tableHeight = window.innerHeight -clientRect.y - this.$refs.table.$el.offsetTop-subHeight;
this.getXmQuestions(); this.getXmQuestions();
}); });
listOption([{categoryId:'all',itemCode:'bugSeverity'},{categoryId:'all',itemCode:'bugSolution'},{categoryId:'all',itemCode:'bugStatus'},{categoryId:'all',itemCode:'bugType'},{categoryId:'all',itemCode:'urgencyLevel'}] ).then(res=>{ listOption([{categoryId:'all',itemCode:'bugSeverity'},{categoryId:'all',itemCode:'bugSolution'},{categoryId:'all',itemCode:'bugStatus'},{categoryId:'all',itemCode:'bugType'},{categoryId:'all',itemCode:'urgencyLevel'}] ).then(res=>{

6
src/views/xm/core/xmRecord/XmRecord.vue

@ -7,7 +7,7 @@
</el-row> </el-row>
<el-row class="app-container"> <el-row class="app-container">
<!--列表 XmRecord xm_record--> <!--列表 XmRecord xm_record-->
<el-table :max-height="tableHeight" :data="xmRecords" @sort-change="sortChange" highlight-current-row v-loading="load.list" border @selection-change="selsChange" @row-click="rowClick" style="width: 100%;">
<el-table ref="table" :max-height="tableHeight" :data="xmRecords" @sort-change="sortChange" highlight-current-row v-loading="load.list" border @selection-change="selsChange" @row-click="rowClick" style="width: 100%;">
<el-table-column sortable type="index" width="40"></el-table-column> <el-table-column sortable type="index" width="40"></el-table-column>
<el-table-column prop="projectId" label="项目编号" v-if="!simple" min-width="80" ></el-table-column> <el-table-column prop="projectId" label="项目编号" v-if="!simple" min-width="80" ></el-table-column>
<el-table-column prop="taskId" label="对象主键编号" v-if="!simple" min-width="80" ></el-table-column> <el-table-column prop="taskId" label="对象主键编号" v-if="!simple" min-width="80" ></el-table-column>
@ -255,7 +255,9 @@
} }
this.$nextTick(() => { this.$nextTick(() => {
this.tableHeight = window.innerHeight - 250;
var clientRect=this.$refs.table.$el.getBoundingClientRect();
var subHeight=50;
this.tableHeight = window.innerHeight -clientRect.y - this.$refs.table.$el.offsetTop-subHeight;
this.getXmRecords(); this.getXmRecords();
}); });
} }

4
src/views/xm/core/xmTask/XmTaskList.vue

@ -438,7 +438,9 @@
mounted() { mounted() {
this.filters.selProject=this.selProject this.filters.selProject=this.selProject
this.$nextTick(()=>{ this.$nextTick(()=>{
this.tableHeight = window.innerHeight - 250;
var clientRect=this.$refs.taskTable.$el.getBoundingClientRect();
var subHeight=85;
this.tableHeight = window.innerHeight -clientRect.y - this.$refs.taskTable.$el.offsetTop-subHeight;
this.getXmTasks(); this.getXmTasks();
}); });
listOption([{categoryId:'all',itemCode:'planType'},{categoryId:'all',itemCode:'taskType'},{categoryId:'all',itemCode:'urgencyLevel'},{categoryId:'all',itemCode:'priority'}]).then(res=>{ listOption([{categoryId:'all',itemCode:'planType'},{categoryId:'all',itemCode:'taskType'},{categoryId:'all',itemCode:'urgencyLevel'},{categoryId:'all',itemCode:'priority'}]).then(res=>{

16
src/views/xm/core/xmTask/XmTaskMng.vue

@ -85,8 +85,10 @@
size="mini" size="mini"
default-expand-all default-expand-all
:max-height="tableHeight" :max-height="tableHeight"
:height="tableHeight"
:tree-props="{children: 'children', hasChildren: 'hasChildren'}" :tree-props="{children: 'children', hasChildren: 'hasChildren'}"
row-key="id" row-key="id"
ref="table"
> >
<el-table-column sortable prop="name" label="任务名称(点击详情)" min-width="240" show-overflow-tooltip> <el-table-column sortable prop="name" label="任务名称(点击详情)" min-width="240" show-overflow-tooltip>
<template slot-scope="scope"> <template slot-scope="scope">
@ -1661,7 +1663,19 @@ XmProjectGroupSelect
} }
this.$nextTick(()=>{ this.$nextTick(()=>{
this.getXmTasks(); this.getXmTasks();
this.tableHeight = window.innerHeight - 250;
var clientRect=this.$refs.table.$el.getBoundingClientRect();
var subHeight=85;
if(this.isTaskCenter){
subHeight=50;
}
this.tableHeight = window.innerHeight -clientRect.y - this.$refs.table.$el.offsetTop-subHeight;
//
/**
let self = this;
window.onresize = function() {
self.tableHeight = window.innerHeight -clientRect.y - this.$refs.table.$el.offsetTop-subHeight;
}
*/
listOption([{categoryId:'all',itemCode:'planType'} listOption([{categoryId:'all',itemCode:'planType'}
,{categoryId:'all',itemCode:'taskType'} ,{categoryId:'all',itemCode:'taskType'}
,{categoryId:'all',itemCode:'urgencyLevel'} ,{categoryId:'all',itemCode:'urgencyLevel'}

6
src/views/xm/core/xmTaskExecuser/XmTaskExecuserMng.vue

@ -9,7 +9,7 @@
</div> </div>
<el-row class="app-container"> <el-row class="app-container">
<!--列表 XmTaskExecuser xm_task_execuser--> <!--列表 XmTaskExecuser xm_task_execuser-->
<el-table :data="xmTaskExecusers" @sort-change="sortChange" highlight-current-row v-loading="load.list" border @selection-change="selsChange" @row-click="rowClick" style="width: 100%;">
<el-table ref="table" :max-height="tableHeight" :data="xmTaskExecusers" @sort-change="sortChange" highlight-current-row v-loading="load.list" border @selection-change="selsChange" @row-click="rowClick" style="width: 100%;">
<el-table-column sortable type="selection" width="40"></el-table-column> <!-- :selectable="checkSelectable" --> <el-table-column sortable type="selection" width="40"></el-table-column> <!-- :selectable="checkSelectable" -->
<el-table-column sortable type="index" width="40"></el-table-column> <el-table-column sortable type="index" width="40"></el-table-column>
<el-table-column type="expand"> <el-table-column type="expand">
@ -270,6 +270,7 @@
], ],
execuserAddType:'add',//add join execuserAddType:'add',//add join
pickerOptions: util.pickerOptions('datarange'), pickerOptions: util.pickerOptions('datarange'),
tableHeight:500,
/**end 自定义属性请在上面加 请加备注**/ /**end 自定义属性请在上面加 请加备注**/
} }
},//end data },//end data
@ -781,6 +782,9 @@
}, },
mounted() { mounted() {
this.$nextTick(() => { this.$nextTick(() => {
var clientRect=this.$refs.table.$el.getBoundingClientRect();
var subHeight=50;
this.tableHeight = window.innerHeight -clientRect.y - this.$refs.table.$el.offsetTop-subHeight;
this.getXmTaskExecusers(); this.getXmTaskExecusers();
}); });

8
src/views/xm/core/xmTestCase/XmTestCaseMng.vue

@ -1,8 +1,6 @@
<template> <template>
<section> <section>
<el-row class="app-container"> <el-row class="app-container">
<div> <div>
已选故事<el-tag v-if=" !filters.menus || filters.menus.length==0" @click="showMenu"> 未选,点我</el-tag><el-tag @click="showMenu" v-for="(item,index) in filters.menus" :key="index" closable @close="clearFiltersMneu(item)">{{item.menuName}}</el-tag> 已选故事<el-tag v-if=" !filters.menus || filters.menus.length==0" @click="showMenu"> 未选,点我</el-tag><el-tag @click="showMenu" v-for="(item,index) in filters.menus" :key="index" closable @close="clearFiltersMneu(item)">{{item.menuName}}</el-tag>
<el-input v-model="filters.key" style="width: 20%;" placeholder="模糊查询"> <el-input v-model="filters.key" style="width: 20%;" placeholder="模糊查询">
@ -18,7 +16,7 @@
</el-row> </el-row>
<el-row class="app-container"> <el-row class="app-container">
<!--列表 XmTestCase 测试用例--> <!--列表 XmTestCase 测试用例-->
<el-table :max-height="tableHeight" :data="xmTestCases" @sort-change="sortChange" highlight-current-row v-loading="load.list" border @selection-change="selsChange" @row-click="rowClick" style="width: 100%;">
<el-table ref="table" :max-height="tableHeight" :data="xmTestCases" @sort-change="sortChange" highlight-current-row v-loading="load.list" border @selection-change="selsChange" @row-click="rowClick" style="width: 100%;">
<el-table-column type="selection" width="45"></el-table-column> <el-table-column type="selection" width="45"></el-table-column>
<el-table-column sortable type="index" width="45"></el-table-column> <el-table-column sortable type="index" width="45"></el-table-column>
<el-table-column prop="caseName" label="标题" min-width="100" > <el-table-column prop="caseName" label="标题" min-width="100" >
@ -300,7 +298,9 @@
mounted() { mounted() {
this.$nextTick(() => { this.$nextTick(() => {
this.getXmTestCases(); this.getXmTestCases();
this.tableHeight = window.innerHeight - 250;
var clientRect=this.$refs.table.$el.getBoundingClientRect();
var subHeight=65;
this.tableHeight = window.innerHeight -clientRect.y - this.$refs.table.$el.offsetTop-subHeight;
}); });
/** /**
listOption([{categoryId:'all',itemCode:'sex'},{categoryId:'all',itemCode:'grade'}] ).then(res=>{ listOption([{categoryId:'all',itemCode:'sex'},{categoryId:'all',itemCode:'grade'}] ).then(res=>{

6
src/views/xm/core/xmTestCaseExec/XmTestCaseExecMng.vue

@ -26,7 +26,7 @@
</el-row> </el-row>
<el-row class="app-container"> <el-row class="app-container">
<!--列表 XmTestCaseExec xm_test_case_exec--> <!--列表 XmTestCaseExec xm_test_case_exec-->
<el-table :max-height="tableHeight" v-if="!gstcVisible" :data="xmTestCaseExecs" @sort-change="sortChange" highlight-current-row v-loading="load.list" border @selection-change="selsChange" @row-click="rowClick" style="width: 100%;">
<el-table ref="table" :max-height="tableHeight" v-if="!gstcVisible" :data="xmTestCaseExecs" @sort-change="sortChange" highlight-current-row v-loading="load.list" border @selection-change="selsChange" @row-click="rowClick" style="width: 100%;">
<el-table-column type="selection" width="45"></el-table-column> <el-table-column type="selection" width="45"></el-table-column>
<el-table-column sortable type="index" width="45"></el-table-column> <el-table-column sortable type="index" width="45"></el-table-column>
<el-table-column prop="projectName" label="项目名称" min-width="100" > <el-table-column prop="projectName" label="项目名称" min-width="100" >
@ -632,7 +632,9 @@
mounted() { mounted() {
this.filters.selProject=this.selProject; this.filters.selProject=this.selProject;
this.$nextTick(() => { this.$nextTick(() => {
this.tableHeight = window.innerHeight - 250;
var clientRect=this.$refs.table.$el.getBoundingClientRect();
var subHeight=70;
this.tableHeight = window.innerHeight -clientRect.y - this.$refs.table.$el.offsetTop-subHeight;
this.getXmTestCaseExecs(); this.getXmTestCaseExecs();
}); });
/** /**

Loading…
Cancel
Save