|
@@ -118,7 +118,7 @@
|
|
</div>
|
|
</div>
|
|
</van-popup>
|
|
</van-popup>
|
|
<!-- 项目经理 -->
|
|
<!-- 项目经理 -->
|
|
- <van-field label="项目经理" @click="(user.id == projectDetail.creatorId || editProjectMan) ? inchargerShow = true : ''" readonly clickable :disabled="!(user.id == projectDetail.creatorId || editProjectMan)">
|
|
|
|
|
|
+ <van-field label="项目经理" @click="editProjectMan ? inchargerShow = true : ''" readonly clickable :disabled="!editProjectMan">
|
|
<template #input>
|
|
<template #input>
|
|
<span v-if="user.userNameNeedTranslate == '1'"><ww-open-data type='userName' :openid='projectDetail.inchargerName'></ww-open-data></span>
|
|
<span v-if="user.userNameNeedTranslate == '1'"><ww-open-data type='userName' :openid='projectDetail.inchargerName'></ww-open-data></span>
|
|
<span v-else>{{projectDetail.inchargerName}}</span>
|
|
<span v-else>{{projectDetail.inchargerName}}</span>
|
|
@@ -427,6 +427,7 @@ export default {
|
|
|
|
|
|
|
|
|
|
getProjectDetail(){
|
|
getProjectDetail(){
|
|
|
|
+ this.editProjectMan = false
|
|
this.$axios.post("/project/detail", {id: this.projectId})
|
|
this.$axios.post("/project/detail", {id: this.projectId})
|
|
.then(res => {
|
|
.then(res => {
|
|
if(res.code == "ok") {
|
|
if(res.code == "ok") {
|
|
@@ -461,18 +462,20 @@ export default {
|
|
this.projectDetail.levelLabel = this.levelList[this.projectDetail.level - 1].label
|
|
this.projectDetail.levelLabel = this.levelList[this.projectDetail.level - 1].label
|
|
}
|
|
}
|
|
|
|
|
|
- if(this.user.id == res.data.creatorId){
|
|
|
|
- this.editCodeAndName = true
|
|
|
|
- return
|
|
|
|
- }
|
|
|
|
|
|
+
|
|
for(let i in this.user.functionList){
|
|
for(let i in this.user.functionList){
|
|
if(this.user.functionList[i].name == '编辑负责项目编码和名称' || this.user.functionList[i].name == '管理全部项目'){
|
|
if(this.user.functionList[i].name == '编辑负责项目编码和名称' || this.user.functionList[i].name == '管理全部项目'){
|
|
this.editCodeAndName = true
|
|
this.editCodeAndName = true
|
|
}
|
|
}
|
|
- if(this.user.functionList[i].name == '管理全部项目') {
|
|
|
|
|
|
+ if(this.user.functionList[i].name == '管理全部项目' || this.user.id == res.data.creatorId){
|
|
this.editProjectMan = true
|
|
this.editProjectMan = true
|
|
}
|
|
}
|
|
}
|
|
}
|
|
|
|
+
|
|
|
|
+ if(this.user.id == res.data.creatorId){
|
|
|
|
+ this.editCodeAndName = true
|
|
|
|
+ return
|
|
|
|
+ }
|
|
} else {
|
|
} else {
|
|
this.$toast.fail('获取失败');
|
|
this.$toast.fail('获取失败');
|
|
}
|
|
}
|