Browse Source

阶段计划增加负责人

master
陈裕财 5 years ago
parent
commit
147b3daa0d
  1. 6
      src/views/xm/core/xmProjectPhase/XmProjectPhaseBatch.vue
  2. 19
      src/views/xm/core/xmProjectPhase/XmProjectPhaseMng.vue

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

@ -50,6 +50,12 @@
<el-input v-model="scope.row.phaseName" @change="fieldChange(scope.row,'phaseName')"></el-input>
</template>
</el-table-column>
<el-table-column prop="mngUsername" label="责任人" min-width="80" >
<template slot-scope="scope">
<el-button v-if="!scope.row.mngUserid" v-model="scope.row.mngUsername" @click="setMngUser" icon="el-icon-setting">去设置</el-button>
<el-link v-else type="primary" icon="el-icon-setting">{{scope.row.mngUsername}}</el-link>
</template>
</el-table-column>
<el-table-column prop="beginDate" label="起始时间" width="200" >
<template slot-scope="scope">
<div>

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

@ -31,19 +31,25 @@
<el-table-column sortable type="selection" width="40"></el-table-column>
<el-table-column prop="phaseName" label="阶段名称" min-width="160" >
<template slot-scope="scope">
<el-link @click="showEdit(scope.row)"> {{scope.row.seqNo}} &nbsp;&nbsp;{{scope.row.phaseName}}</el-link>
{{scope.row.seqNo}} &nbsp;&nbsp;<el-link type="primary" @click="showEdit(scope.row)"> {{scope.row.phaseName}}</el-link>
</template>
</el-table-column>
<el-table-column prop="mngUsername" label="责任人" min-width="80" >
<template slot-scope="scope">
<el-button v-if="!scope.row.mngUserid" v-model="scope.row.mngUsername" @click="setMngUser" icon="el-icon-setting">去设置</el-button>
<el-link v-else type="primary" icon="el-icon-setting" @click="setMngUser">{{scope.row.mngUsername}}</el-link>
</template>
</el-table-column>
<el-table-column prop="beginDate" label="起止时间" min-width="150" >
<template slot-scope="scope">
{{formatDate(scope.row.beginDate)}}~{{formatDate(scope.row.endDate)}} <br/>
{{formatDate(scope.row.beginDate)}}~{{formatDate(scope.row.endDate)}}
<div v-for="item in [calcTaskStateByTime(scope.row.beginDate,scope.row.endDate,scope.row.actRate,scope.phaseStatus)]" :key="item.status"><el-tag :type="item.status">{{item.remark}}</el-tag></div>
</template>
</el-table-column>
<el-table-column prop="actRate" label="进度.状态" width="100">
<template slot-scope="scope">
<el-tag > {{ (scope.row.actRate!=null?scope.row.actRate:0)+'%'}} </el-tag> <br/>
<el-tag > {{ formateOption('xmPhaseStatus',scope.row.phaseStatus)}} </el-tag>
<el-tag :type="scope.row.actRate>=100?'success':'primary'"> {{ (scope.row.actRate!=null?scope.row.actRate:0)+'%'}} </el-tag>
<!--<el-tag > {{ formateOption('xmPhaseStatus',scope.row.phaseStatus)}} </el-tag> -->
</template>
</el-table-column>
<el-table-column prop="phaseBudgetHours" label="工时.人时" min-width="200" >
@ -75,7 +81,6 @@
</el-tooltip>
</template>
</el-table-column>
<el-table-column prop="remark" label="备注" min-width="80" > </el-table-column>
<el-table-column label="操作" width="100" fixed="right">
<template slot-scope="scope">
<el-dropdown @command="handleCommand" :hide-on-click="false">
@ -989,8 +994,12 @@ import XmProjectPhaseBatch from './XmProjectPhaseBatch.vue';
}else if( this.getDaysBetween(curDate, start) > 0 && this.getDaysBetween(curDate, end) <= 0 ){
return {remark: this.toFixed(this.getDaysBetween(end, curDate))+"天后结束",status:'primary'};
}else if( this.getDaysBetween(curDate, end) > 0 ){
if(actRate>=100){
return {remark:"已完工"+( this.toFixed(this.getDaysBetween(curDate, end)) )+"天",status:'success'};
}else{
return {remark:"逾期"+( this.toFixed(this.getDaysBetween(curDate, end)) )+"天",status:'danger'};
}
}
},
/**
* 计算两个日期之间的天数

Loading…
Cancel
Save