|
@@ -57,6 +57,9 @@
|
|
|
<el-dropdown-item divided @click.native="renameGroup(item)" :disabled="!(projectCreatorId == user.id || projectInchargerId == user.id || permissions.projectManagement || isManageDept)">
|
|
|
<i class="el-icon-edit"></i>
|
|
|
{{ $t('changegroups') }}</el-dropdown-item>
|
|
|
+ <el-dropdown-item divided @click.native="setManDay(item)" :disabled="!(projectCreatorId == user.id || projectInchargerId == user.id || permissions.projectManagement || isManageDept)">
|
|
|
+ <i class="el-icon-time"></i>
|
|
|
+ 预估工时</el-dropdown-item>
|
|
|
<el-dropdown-item divided @click.native="addToTemplate(item)" :disabled="!(projectCreatorId == user.id || projectInchargerId == user.id || permissions.projectManagement || isManageDept)">
|
|
|
<i class="el-icon-plus"></i>
|
|
|
{{ $t('settemplate') }}</el-dropdown-item>
|
|
@@ -71,7 +74,6 @@
|
|
|
<el-dropdown-item divided @click.native="deleteGroup(item)" :disabled="!(projectCreatorId == user.id || projectInchargerId == user.id || permissions.projectManagement || isManageDept)">
|
|
|
<i class="el-icon-delete"></i>
|
|
|
{{ $t('deletethegroup') }} </el-dropdown-item>
|
|
|
- <!-- 设置参与人 0000 -->
|
|
|
<el-dropdown-item divided @click.native="getGroupDetails(item)">
|
|
|
<i class="el-icon-tickets"></i>
|
|
|
{{ $t('groupdetails') }} </el-dropdown-item>
|
|
@@ -93,7 +95,7 @@
|
|
|
<!-- 分组详情 -->
|
|
|
<el-dialog :title="groupDetailTil" :visible.sync="groupDetailsShow" width="500px" :before-close="handleClose">
|
|
|
<div>
|
|
|
- <el-form label-width="80px">
|
|
|
+ <el-form label-width="90px">
|
|
|
<el-form-item :label="$t('head') + ':'">
|
|
|
<span v-if="user.userNameNeedTranslate != '1'">{{groupDetailData.incharger}}</span>
|
|
|
<span v-if="user.userNameNeedTranslate == '1'">
|
|
@@ -111,9 +113,12 @@
|
|
|
<span v-if="index < groupDetailData.participators.length - 1">、</span>
|
|
|
</span>
|
|
|
</el-form-item>
|
|
|
- <el-form-item label="wbsCode" v-if="user.companyId == 936">
|
|
|
+ <el-form-item label="wbsCode:" v-if="user.companyId == 936">
|
|
|
<span>{{groupDetailData.wbsCode}}</span>
|
|
|
</el-form-item>
|
|
|
+ <el-form-item label="预估工时:" v-if="user.timeType.projectManDay">
|
|
|
+ <span>{{groupDetailData.manDay}}人天 ({{ (groupDetailData.manDay==null?0:groupDetailData.manDay)*user.timeType.allday }}小时)</span>
|
|
|
+ </el-form-item>
|
|
|
</el-form>
|
|
|
</div>
|
|
|
<span slot="footer" class="dialog-footer">
|
|
@@ -1133,6 +1138,22 @@
|
|
|
<el-button type="primary" @click="addGroup('form2')" style="width:100%;" >{{ $t('save') }}</el-button>
|
|
|
</div>
|
|
|
</el-dialog>
|
|
|
+
|
|
|
+ <el-dialog title="设置分组预估工时" v-if="modGroupManDayDialog" :visible.sync="modGroupManDayDialog" :close-on-click-modal="false" customClass="customWidth" width="450px">
|
|
|
+ <el-table :data="groupList" size="small" :key="Math.random()" :height="'400px'" show-summary="true">
|
|
|
+ <el-table-column prop="name" label="分组名称">
|
|
|
+ </el-table-column>
|
|
|
+ <el-table-column prop="manDay" width="200" label="预估工时" >
|
|
|
+ <template slot-scope="scope">
|
|
|
+ <el-input v-model="scope.row.manDay" type="number" :placeholder="$t('peaseenterthe')" maxlength="10" :max="99999" style="width:120px;"></el-input> 人天
|
|
|
+ </template>
|
|
|
+ </el-table-column>
|
|
|
+ </el-table>
|
|
|
+ <p style="text-align:center;">当前项目预估工时为:{{ currentProject.manDay == null? 0:currentProject.manDay }}人天</p>
|
|
|
+ <div slot="footer" class="dialog-footer">
|
|
|
+ <el-button type="primary" @click="setManDayData()" style="width:100%;" >{{ $t('save') }}</el-button>
|
|
|
+ </div>
|
|
|
+ </el-dialog>
|
|
|
<el-dialog :title="$t('addtemplate')" v-if="addToTmpDialog" :visible.sync="addToTmpDialog" :close-on-click-modal="false" customClass="customWidth" width="500px">
|
|
|
<el-form ref="formTmp" :model="templateForm" :rules="rules" style="margin-top:10px;">
|
|
|
<el-form-item prop="name">
|
|
@@ -1257,6 +1278,7 @@
|
|
|
|
|
|
data() {
|
|
|
return {
|
|
|
+ modGroupManDayDialog: false,
|
|
|
isManageDept: false,
|
|
|
componentFlg: false,
|
|
|
mileageCup: false,
|
|
@@ -1336,6 +1358,9 @@
|
|
|
rules: {
|
|
|
name: [{ required: true, message: this.$t('pleaseenteragroupname'), trigger: "blur" }],
|
|
|
},
|
|
|
+ rulesManDay: {
|
|
|
+ manDay: [{ required: true, message: '请输入预估工时', trigger: "blur" }],
|
|
|
+ },
|
|
|
rules2: {
|
|
|
stagesName: [{ required: true, message: this.$t('pleaseenteratasklistname'), trigger: "blur" }],
|
|
|
},
|
|
@@ -3038,6 +3063,10 @@
|
|
|
this.groupForm = JSON.parse(JSON.stringify(item));
|
|
|
this.setInchargerDialog = true;
|
|
|
},
|
|
|
+ setManDay(item) {
|
|
|
+ this.groupForm = JSON.parse(JSON.stringify(item));
|
|
|
+ this.modGroupManDayDialog = true;
|
|
|
+ },
|
|
|
renameGroup(item) {
|
|
|
this.groupForm = JSON.parse(JSON.stringify(item));
|
|
|
this.modGroupDialog = true;
|
|
@@ -3181,7 +3210,26 @@
|
|
|
});
|
|
|
});
|
|
|
},
|
|
|
-
|
|
|
+ setManDayData() {
|
|
|
+ this.http.post('/task-group/saveManDay',{data:JSON.stringify(this.groupList)},
|
|
|
+ res => {
|
|
|
+ if (res.code == "ok") {
|
|
|
+ this.modGroupManDayDialog = false;
|
|
|
+ this.groupList = res.data;
|
|
|
+ } else {
|
|
|
+ this.$message({
|
|
|
+ message: res.msg,
|
|
|
+ type: "error"
|
|
|
+ });
|
|
|
+ }
|
|
|
+ },
|
|
|
+ error => {
|
|
|
+ this.$message({
|
|
|
+ message: error,
|
|
|
+ type: "error"
|
|
|
+ });
|
|
|
+ });
|
|
|
+ },
|
|
|
// 重新定义了 addGroup 方法
|
|
|
addGroup(formName) {
|
|
|
// return
|