Browse Source

优化

master
陈裕财 4 years ago
parent
commit
3e94eff1b1
  1. 22
      src/views/xm/core/components/XmIterationSelect.vue
  2. 18
      src/views/xm/core/components/XmMenuWorkload.vue
  3. 49
      src/views/xm/core/xmIteration/XmIterationMng.vue
  4. 68
      src/views/xm/core/xmIterationMenu/XmIterationMenuMng.vue
  5. 34
      src/views/xm/core/xmMenu/XmMenuEdit.vue
  6. 70
      src/views/xm/core/xmMenu/XmMenuMng.vue
  7. 40
      src/views/xm/core/xmMenu/XmMenuSelect.vue

22
src/views/xm/core/components/XmIterationSelect.vue

@ -82,10 +82,10 @@
props:['clearable', 'productId', 'linkProjectId','autoSelect'],
watch:{
productId:function(){
this.getXmIterations();
this.initData();
},
iterationId:function(){
this.getXmIterations();
linkProjectId:function(){
this.initData();
}
},
data() {
@ -208,8 +208,8 @@
if(this.autoSelect===true&&this.xmIterations.length>0){
if(this.autoSelect!==false&&this.xmIterations.length>0 && this.iterationVisible==false){
var row=this.xmIterations[0];
this.$refs.table.setCurrentRow(row);
this.rowClick(row);
this.$refs.table.setCurrentRow(row);
this.rowClick(row)
}
}
}else{
@ -223,7 +223,7 @@
selsChange: function (sels) {
this.sels = sels;
},
rowClick: function(row, event, column){
rowClick: function(row, event, column){
var oldId=this.editForm.id
this.editForm=row
this.iterationVisible=false;
@ -252,8 +252,8 @@
this.xmIterations=xmIterations;
if(this.autoSelect!==false&&this.xmIterations.length>0 && this.iterationVisible==false){
var row=this.xmIterations[0];
this.$refs.table.setCurrentRow(row);
this.rowClick(row);
this.$refs.table.setCurrentRow(row);
this.rowClick(row)
}
}else{
this.searchXmIterations();
@ -264,14 +264,14 @@
this.xmIterations=xmIterations;
if(this.autoSelect!==false&&this.xmIterations.length>0 && this.iterationVisible==false){
var row=this.xmIterations[0];
this.$refs.table.setCurrentRow(row);
this.rowClick(row);
this.$refs.table.setCurrentRow(row);
this.rowClick(row)
}
}else{
this.searchXmIterations();
}
}else{
this.searchXmIterations();
//his.searchXmIterations();
}
},

18
src/views/xm/core/components/XmMenuWorkload.vue

@ -6,22 +6,22 @@
v-model="formVisible"
trigger="manual" > <el-form :model="editForm" label-width="100px" ref="editForm">
<el-form-item label="汇总方式" prop="calcType">
<el-radio v-model="editForm.calcType" label="3" placeholder="下级往上级汇总" :disabled="editForm.ntype==='0'">下往上</el-radio>
<el-radio v-model="editForm.calcType" label="1" placeholder="由任务汇总" :disabled="editForm.ntype==='1'">任务汇总</el-radio>
<el-radio v-model="editForm.calcType" label="2" placeholder="手工填报" :disabled="editForm.ntype==='1'">手工填报</el-radio>
<el-radio v-model="editForm.calcType" label="3" placeholder="下级往上级汇总" :disabled="editForm.ntype!=='0'">下往上</el-radio>
<el-radio v-model="editForm.calcType" label="1" placeholder="由任务汇总" :disabled="editForm.ntype!=='0'">任务汇总</el-radio>
<el-radio v-model="editForm.calcType" label="2" placeholder="手工填报" :disabled="editForm.ntype!=='0'">手工填报</el-radio>
</el-form-item>
<el-form-item label="当前进度" prop="mactRate" >
<el-form-item label="工时进度" prop="mactRate" >
<el-progress style="width:50%;" :stroke-width="15" :percentage="editForm.mactRate?editForm.mactRate:0"></el-progress>
</el-form-item>
<el-form-item label="预估工期" prop="budgetHours">
<el-input-number :disabled="editForm.calcType!=='2' && editForm.ntype==='1'" style="width:200px;" v-model="editForm.budgetHours" :precision="2" :step="8" :min="0" placeholder="预计工期(小时)"></el-input-number>&nbsp;h
<el-input-number :disabled="editForm.calcType!=='2' " style="width:200px;" v-model="editForm.budgetHours" :precision="2" :step="8" :min="0" placeholder="预计工期(小时)"></el-input-number>&nbsp;h
</el-form-item>
<el-form-item label="预估工时" prop="budgetWorkload">
<el-input-number :disabled="editForm.calcType!=='2' && editForm.ntype==='1'" style="width:200px;" v-model="editForm.budgetWorkload" :precision="2" :step="8" :min="0" placeholder="预计工时(人时)"></el-input-number> &nbsp;h
<el-input-number :disabled="editForm.calcType!=='2' " style="width:200px;" v-model="editForm.budgetWorkload" :precision="2" :step="8" :min="0" placeholder="预计工时(人时)"></el-input-number> &nbsp;h
</el-form-item>
<el-form-item label="实际工时" prop="mactWorkload">
<el-input-number :disabled="editForm.calcType!=='2' && editForm.ntype==='1'" style="width:200px;" v-model="editForm.mactWorkload" :precision="2" :step="8" :min="0" placeholder="实际工时(人时)"></el-input-number> &nbsp;h
<el-input-number :disabled="editForm.calcType!=='2' " style="width:200px;" v-model="editForm.mactWorkload" :precision="2" :step="8" :min="0" placeholder="实际工时(人时)"></el-input-number> &nbsp;h
</el-form-item>
<font color="blue" style="font-size:10px;">控制规则:
<br>下级往上汇总指工时数据按 &nbsp;用户故事->特性->史诗 &nbsp;这样的汇总关系将数据逐级往上汇总
@ -31,10 +31,10 @@
<el-form-item label="" class="padding">
<el-button type="text" @click="cancel">关闭</el-button>
<el-button :disabled="editForm.calcType!=='2' && editForm.ntype==='1'" type="primary" @click="submit">确认</el-button>
<el-button :disabled="editForm.calcType!=='2'" type="primary" @click="submit">确认</el-button>
</el-form-item>
</el-form>
<el-button title="点击填写工时" @click="formVisible=true" type="warning" slot="reference" icon="el-icon-edit"><font style="font-size:14px;"></font></el-button>
<el-button title="点击填写工时" @click="formVisible=!formVisible" type="warning" slot="reference" icon="el-icon-edit"><font style="font-size:14px;"></font></el-button>
</el-popover>
</section>
</template>

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

@ -150,8 +150,8 @@ import XmIterationSelect from '@/views/xm/core/components/XmIterationSelect.vue'
]),
xmIterationTreeData(){
return this.translateDataToTree(this.xmIterations);
},
return this.xmIterations
},
},
props:['xmProduct','selProject','menuId','visible'],
watch:{
@ -407,50 +407,7 @@ import XmIterationSelect from '@/views/xm/core/components/XmIterationSelect.vue'
rowClick: function(row, event, column){
this.editForm=row
this.$emit('row-click',row, event, column);// @row-click="rowClick"
},
/**begin 自定义函数请在下面加**/
translateDataToTree(data2) {
var data=JSON.parse(JSON.stringify(data2));
let parents = data.filter(value =>{
//
if(value.pid == 'undefined' || value.pid == null || value.pid == ''){
return true;
//
}else if(data.some(i=>value.pid==i.id)){
return false;
}else {
return true
}
})
let children = data.filter(value =>{
if(data.some(i=>value.pid==i.id)){
return true;
}else{
return false;
}
})
let translator = (parents, children) => {
parents.forEach((parent) => {
children.forEach((current, index) => {
if (current.pid === parent.id) {
let temp = JSON.parse(JSON.stringify(children))
temp.splice(index, 1)
translator([current], temp)
typeof parent.children !== 'undefined' ? parent.children.push(current) : parent.children = [current]
}
}
)
}
)
}
translator(parents, children)
return parents
},
},
clearSelectIteration(){
this.editForm=this.editFormInit

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

@ -15,7 +15,7 @@
</el-row>
<el-row class="page-main padding-top padding-left">
<!--列表 XmIterationMenu 迭代定义-->
<el-table ref="table" :height="maxTableHeight" :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" :height="maxTableHeight" :data="xmIterationMenusTreeData" row-key="menuId" :tree-props="{children: 'children', hasChildren: 'childrenCnt'}" @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 prop="menuName" label="需求名称" min-width="140" >
@ -45,7 +45,7 @@
</el-row>
</el-col>
<el-col :span="14">
<xm-menu-select checkScope="0" :xm-product="{id:xmIteration.productId}" :xm-iteration="xmIteration" :visible="menuVisible" :is-select-menu="true" :multi="true" @menus-selected="onSelectedMenus" ></xm-menu-select>
<xm-menu-select ref="menusSelect" iterationFilterType="not-join-curr-iteration" checkScope="0" :xm-product="{id:xmIteration.productId}" :xm-iteration="xmIteration" :visible="menuVisible" :is-select-menu="true" :multi="true" @menus-selected="onSelectedMenus" ></xm-menu-select>
</el-col>
</el-row>
</section>
@ -53,6 +53,7 @@
<script>
import util from '@/common/js/util';//
import treeTool from '@/common/js/treeTool';//
import config from '@/common/config';//
import { initSimpleDicts } from '@/api/mdp/meta/item';//
import { listXmIterationMenu, delXmIterationMenu, batchDelXmIterationMenu,batchAddXmIterationMenu } from '@/api/xm/core/xmIterationMenu';
@ -66,12 +67,13 @@
computed: {
...mapGetters([
'userInfo','roles'
]),
xmIterationMenusTreeData(){
var data= this.translateDataToTree(this.xmIterationMenus);
return data;
},
]),
xmIterationMenusTreeData() {
let xmMenus = JSON.parse(JSON.stringify(this.xmIterationMenus || []));
let xmMenusTreeData = treeTool.translateDataToTree(xmMenus,"pmenuId","menuId");
return xmMenusTreeData;
},
},
watch:{
'xmIteration':function(xmIteration){
@ -216,6 +218,8 @@
var tips=res.data.tips;
if(tips.isOk){
this.pageInfo.count=true;
this.$refs.menusSelect.reloadChildren([row]);
this.getXmIterationMenus();
}
this.$notify({showClose: true, message: tips.msg, type: tips.isOk?'success':'error' });
@ -239,6 +243,7 @@
this.load.del=false;
var tips=res.data.tips;
if( tips.isOk ){
this.$refs.menusSelect.reloadChildren(this.sels);
this.pageInfo.count=true;
this.getXmIterationMenus();
}
@ -248,51 +253,7 @@
},
rowClick: function(row, event, column){
this.$emit('row-click',row, event, column);// @row-click="rowClick"
},
/**begin 自定义函数请在下面加**/
/**begin 自定义函数请在下面加**/
translateDataToTree(data2) {
var data=JSON.parse(JSON.stringify(data2));
let parents = data.filter(value =>{
//
if(value.pmenuId == 'undefined' || value.pmenuId == null || value.pmenuId == ''){
return true;
//
}else if(data.some(i=>value.pmenuId==i.menuId)){
return false;
}else {
return true
}
})
let children = data.filter(value =>{
if(data.some(i=>value.pmenuId==i.menuId)){
return true;
}else{
return false;
}
})
let translator = (parents, children) => {
parents.forEach((parent) => {
children.forEach((current, index) => {
if (current.pmenuId === parent.menuId) {
let temp = JSON.parse(JSON.stringify(children))
temp.splice(index, 1)
translator([current], temp)
typeof parent.children !== 'undefined' ? parent.children.push(current) : parent.children = [current]
}
}
)
}
)
}
translator(parents, children)
return parents
},
},
onSelectedMenus(menus){
if(!menus || menus.length==0){
this.menuVisible=false
@ -308,6 +269,7 @@
var tips = res.data.tips
if(tips.isOk){
this.getXmIterationMenus()
this.$refs.menusSelect.reloadChildren(menus);
}
this.$notify({showClose: true, message: tips.msg, type: tips.isOk?'success':'error'});
})

34
src/views/xm/core/xmMenu/XmMenuEdit.vue

@ -111,16 +111,16 @@
</el-form-item>
<el-form-item label="当前进度" prop="mactRate" >
<el-progress style="width:80%;" :stroke-width="26" :percentage="editForm.mactRate?editForm.mactRate:0"></el-progress>
<el-progress style="width:40%;" :stroke-width="26" :percentage="editForm.mactRate?editForm.mactRate:0"></el-progress>
</el-form-item>
<el-form-item label="预估工期" prop="budgetHours">
<el-input-number :disabled="editForm.calcType!=='2' && editForm.ntype==='1'" style="width:200px;" v-model="editForm.budgetHours" :precision="2" :step="8" :min="0" placeholder="预计工期(小时)"></el-input-number>&nbsp;h
<el-input-number :disabled="editForm.calcType!=='2'" style="width:200px;" v-model="editForm.budgetHours" :precision="2" :step="8" :min="0" placeholder="预计工期(小时)"></el-input-number>&nbsp;h
</el-form-item>
<el-form-item label="预估工时" prop="budgetWorkload">
<el-input-number :disabled="editForm.calcType!=='2' && editForm.ntype==='1'" style="width:200px;" v-model="editForm.budgetWorkload" :precision="2" :step="8" :min="0" placeholder="预计工时(人时)"></el-input-number> &nbsp;h
<el-input-number :disabled="editForm.calcType!=='2'" style="width:200px;" v-model="editForm.budgetWorkload" :precision="2" :step="8" :min="0" placeholder="预计工时(人时)"></el-input-number> &nbsp;h
</el-form-item>
<el-form-item label="实际工时" prop="mactWorkload">
<el-input-number :disabled="editForm.calcType!=='2' && editForm.ntype==='1'" style="width:200px;" v-model="editForm.mactWorkload" :precision="2" :step="8" :min="0" placeholder="实际工时(人时)"></el-input-number> &nbsp;h
<el-input-number :disabled="editForm.calcType!=='2'" style="width:200px;" v-model="editForm.mactWorkload" :precision="2" :step="8" :min="0" placeholder="实际工时(人时)"></el-input-number> &nbsp;h
</el-form-item>
<font color="blue" style="font-size:10px;">控制规则:
<br>下级往上汇总指工时数据按 &nbsp;用户故事->特性->史诗 &nbsp;这样的汇总关系将数据逐级往上汇总
@ -235,7 +235,31 @@ import XmMenuExchangeMng from '../xmMenuExchange/XmMenuExchangeMng.vue';
if(visible==true){
//
}
}
},
'editForm.mactWorkload':function(val,oldVal){
if(!this.editForm.budgetWorkload){
return;
}
if(val==0||!val){
return;
}
this.editForm.mactRate=Math.round(val/this.editForm.budgetWorkload*100)
if( this.editForm.mactRate>100){
this.editForm.mactRate=100;
}
},
'editForm.budgetWorkload':function(val,oldVal){
if(!this.editForm.mactWorkload){
return;
}
if(val==0||!val){
return;
}
this.editForm.mactRate=Math.round(this.editForm.mactWorkload/val*100)
if( this.editForm.mactRate>100){
this.editForm.mactRate=100;
}
}
},
data() {
return {

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

@ -5,7 +5,7 @@
<el-row>
<xm-product-select ref="xmProductSelect1" style="display:inline;" v-if="!xmProduct && !xmIteration" :auto-select="false" :link-project-id="selProject?selProject.id:null" @row-click="onProductSelected" :iterationId="xmIteration?xmIteration.id:null" @clear-select="onProductClearSelect"></xm-product-select>
<xm-it-select v-if="!xmIteration || !xmIteration.id" style="display:inline;" :product-id="filters.product?filters.product.id:null" :link-project-id="selProject?selProject.id:null" placeholder="迭代" @row-click="onIterationSelected" @clear="onIterationClearSelect">
<xm-it-select v-if="!xmIteration || !xmIteration.id" style="display:inline;" :auto-select="false" :product-id="filters.product?filters.product.id:null" :link-project-id="selProject?selProject.id:null" placeholder="迭代" @row-click="onIterationSelected" @clear="onIterationClearSelect">
</xm-it-select>
<el-select v-model="filters.taskFilterType" placeholder="已分配任务的需求?" clearable v-if="selProject &&selProject.id">
@ -288,16 +288,8 @@
</template>
</el-table-column>
<el-table-column prop="iterationName" label="迭代" width="150" show-overflow-tooltip sortable>
<template slot-scope="scope">
<div class="cell-text">
{{scope.row.iterationName}}
</div>
<span class="cell-bar">
<xm-it-select :product-id="filters.product?filters.product.id:null" :link-project-id="selProject?selProject.id:null" placeholder="迭代" style="display:block;" @change="editXmMenuSomeFields(scope.row,'iterationId',$event)">
</xm-it-select>
</span>
<template slot-scope="scope">
{{scope.row.iterationName}}
</template>
</el-table-column>
@ -394,10 +386,6 @@
</el-drawer>
</el-col>
</el-row>
<el-row v-if="batchEditVisible">
<xm-menu-mng-batch :xm-menus="xmMenus" :dicts="dicts" @no-batch-edit="noBatchEdit" :product="filters.product"></xm-menu-mng-batch>
</el-row>
<el-pagination layout="total, sizes, prev, pager, next" @current-change="handleCurrentChange" @size-change="handleSizeChange" :page-sizes="[10,20, 50, 100, 500]" :current-page="pageInfo.pageNum" :page-size="pageInfo.pageSize" :total="pageInfo.total" style="float:right;"></el-pagination>
<el-drawer append-to-body title="标签条件" :visible.sync="tagSelectVisible" size="60%">
@ -448,7 +436,6 @@
import XmTaskList from '../xmTask/XmTaskList';
import XmTaskMng from '../xmTask/XmTaskMng';
import XmTaskListForMenu from '../xmTask/XmTaskListForMenu';
import XmIterationSelect from '../xmIteration/XmIterationSelect';//
import XmItSelect from '@/views/xm/core/components/XmIterationSelect.vue';//
import XmMenuWorkload from '@/views/xm/core/components/XmMenuWorkload';//
import XmTableConfig from '@/views/xm/core/components/XmTableConfig';//
@ -468,7 +455,7 @@
'userInfo','roles'
]),
xmMenusTreeData() {
xmMenusTreeData() {
let xmMenus = JSON.parse(JSON.stringify(this.xmMenus || []));
let xmMenusTreeData = treeTool.translateDataToTree(xmMenus,"pmenuId","menuId");
return xmMenusTreeData;
@ -630,7 +617,13 @@
}
if(this.filters.taskFilterType){
params.taskFilterType=this.filters.taskFilterType
params.projectId=this.selProject.id
if(params.taskFilterType==='not-join-curr-project'){
params.projectId=this.selProject.id
}
if(params.taskFilterType==='join-curr-project'){
params.projectId=this.selProject.id
}
params.ntype="0"
}
if(this.selProject && this.selProject.id){
@ -792,15 +785,13 @@
this.xmMenus=[]
this.getXmMenus()
},
onIterationSelected:function(iteration){
this.filters.iteration=iteration
this.iterationVisible=false;
onIterationSelected:function(iteration){
this.filters.iteration=iteration
this.xmMenus=[]
this.getXmMenus()
},
onIterationClearSelect:function(){
this.filters.iteration=null
this.iterationVisible=false;
this.filters.iteration=null
this.xmMenus=[]
this.getXmMenus()
},
@ -828,7 +819,7 @@
//xmMenu
batchDel: function () {
if(this.sels.length==0){
this.$notify({showClose: true, message: "请先选择要删除的需求或者需求池", type: 'warning'});
this.$notify({showClose: true, message: "请先选择要删除的需求", type: 'warning'});
return;
}
this.$confirm('确认删除选中的'+this.sels.length+'条数据吗?删除后数据不可恢复', '提示', {
@ -889,10 +880,6 @@
return dataList;
},
/**begin 自定义函数请在下面加**/
selectedMenu:function(row){
this.$emit("selected",row)
},
showImportFromMenuTemplate(row){
if(!this.filters.product){
this.$notify.error("请选择产品模板")
@ -969,14 +956,8 @@
}
}).catch( err => this.load.add=false );
},
toBatchEdit(){
this.batchEditVisible=true;
},
noBatchEdit(){
this.batchEditVisible=false;
this.getXmMenus();
},
showTaskList(row){
this.editForm=row
@ -1004,22 +985,6 @@
this.$notify({showClose: true, message: tips.msg, type: tips.isOk?'success':'error'});
});
},
showMenuExchange:function(row){
this.editForm=row
this. menuDetailVisible=true;
},
toProjectList:function(product){
this.$router.push({name:'xmProjectMng',params:{productId:product.id,productName:product.productName}})
},
toIterationList:function(row){
this.editForm=row
this.iterationVisible=true;
},
showTasks(row){
this.editForm=row
this.taskMngVisible=true
},
showTaskListForMenu(row){
this.editForm=row
@ -1289,7 +1254,6 @@
XmTaskList,
XmTaskMng,
XmTaskListForMenu,
XmIterationSelect,
UsersSelect,
XmMenuMngBatch,
TagMng,

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

@ -6,7 +6,19 @@
<xm-product-select v-if="!xmProduct&&!xmIteration" :auto-select="false" :link-project-id="selProject?selProject.id:null" @row-click="onProductSelected" ref="xmProductMng" :iteration-id="xmIteration?xmIteration.id:null" @clear-select="onProductClearSelect" @close="productVisible=false"></xm-product-select>
<xm-iteration-select v-if="!xmIteration" :auto-select="false" :link-project-id="selProject?selProject.id:null" @row-click="onIterationSelected" ref="xmIterationMng" :product-id="xmProduct?xmProduct.id:null" @clear-select="onIterationClearSelect" @close="iterationVisible=false"></xm-iteration-select>
<el-select v-model="filters.taskFilterType" placeholder="已分配任务的需求?" clearable v-if="taskFilterType">
<el-option value="not-join-any-project" label="未分配过任务的需求"></el-option>
<el-option value="join-any-project" label="已分配过任务的需求"></el-option>
<el-option value="not-join-curr-project" :label="'未分配任务到项目【'+selProject.name+'】'" v-if="selProject && selProject.id"></el-option>
<el-option value="join-curr-project" :label="'已分配任务到项目【'+selProject.name+'】'" v-if="selProject && selProject.id"></el-option>
</el-select>
<el-select v-model="filters.iterationFilterType" placeholder="加入过迭代?" clearable v-if="iterationFilterType">
<el-option value="not-join-any-iteration" label="未加入过迭代"></el-option>
<el-option value="join-any-iteration" label="已加入过迭代"></el-option>
<el-option value="not-join-curr-iteration" :label="'未加入迭代【'+filters.iteration.iterationName+'】'" v-if="filters.iteration && filters.iteration.id"></el-option>
<el-option value="join-curr-iteration" :label="'已加入本迭代【'+filters.iteration.iterationName+'】'" v-if="filters.iteration && filters.iteration.id"></el-option>
</el-select>
<el-select v-model="filters.priority" placeholder="优先级" clearable style="width: 100px;">
<el-option v-for="i in dicts.priority" :label="i.name" :key="i.id" :value="i.id"></el-option>
</el-select>
@ -191,7 +203,7 @@
import { mapGetters } from 'vuex'
export default {
props:['isSelectMenu','multi','visible','xmIteration','xmProduct','selProject','checkScope'/**0-需求,1-需求池 */],
props:['isSelectMenu','multi','visible','xmIteration','xmProduct','selProject','checkScope'/**0-需求,1-需求池 */,'iterationFilterType','taskFilterType'],
computed: {
...mapGetters([
'userInfo','roles'
@ -225,6 +237,7 @@
const endDate = new Date();
beginDate.setTime(beginDate.getTime() - 3600 * 1000 * 24 * 7 * 4 * 6 );
return {
maps:new Map(),
filters: {
key: '',
product:null,
@ -326,7 +339,13 @@
}
if(this.filters.taskFilterType){
params.taskFilterType=this.filters.taskFilterType
params.projectId=this.selProject.id
if(params.taskFilterType==='not-join-curr-project'){
params.projectId=this.selProject.id
}
if(params.taskFilterType==='join-curr-project'){
params.projectId=this.selProject.id
}
params.ntype="0"
}
if(this.selProject && this.selProject.id){
@ -363,9 +382,9 @@
}
return params;
},
loadMenusLazy(row, treeNode, resolve) {
var params={pmenuId:row.menuId}
loadMenusLazy(tree, treeNode, resolve) {
this.maps.set(tree.menuId, { tree, treeNode, resolve }) //
var params={pmenuId:tree.menuId}
params=this.getParams(params);
params.isTop=""
this.load.list = true;
@ -380,6 +399,9 @@
}
}).catch( err => this.load.list = false );
},
reloadChildren(rows){
treeTool.reloadAllChildren(this.$refs.table,this.maps,rows,'pmenuId',this.loadMenusLazy)
},
// XmMenu xm_project_menu
getXmMenus() {
@ -529,7 +551,13 @@
this.filters.iterationFilterType='join-curr-iteration'
this.filters.iteration=this.xmIteration
}
if(this.iterationFilterType){
this.filters.iterationFilterType=this.iterationFilterType
}
if(this.taskFilterType){
this.filters.taskFilterType=this.taskFilterType
}
this.filters.product=this.xmProduct
this.getXmMenus();
});

Loading…
Cancel
Save