[update] 认证工程师权限
This commit is contained in:
@@ -354,9 +354,12 @@ export default {
|
||||
},
|
||||
// 冻结配置
|
||||
freezeConfiguration() {
|
||||
if(this.homo) {
|
||||
// 认证工程师 任意状态 都有此权限
|
||||
this.areaVisibleFreeze = true
|
||||
// 获取冻结配置数据
|
||||
this.getFreeze()
|
||||
}
|
||||
},
|
||||
// 冻结配置提交
|
||||
handleSubmitFreeze() {
|
||||
@@ -429,81 +432,83 @@ export default {
|
||||
},
|
||||
// 下发收集
|
||||
distributionAndCollection() {
|
||||
// 先判断是否有权限 认证工程师 待发起收集
|
||||
let permissionmoAndinitiated = this.permissionmoAndinitiated()
|
||||
if(permissionmoAndinitiated) {
|
||||
let _array = []
|
||||
this.selectedRowKeysValue.forEach((item, index) => {
|
||||
_array.push(item.id)
|
||||
})
|
||||
let _this = this
|
||||
let param = {projectId: this.$route.query.id, ids: _array.join(',')}
|
||||
axios({
|
||||
url: '/jero-boot/params/collectManifest/issueCollection',
|
||||
method: 'post',
|
||||
data: param,
|
||||
transformRequest: [function (data) {
|
||||
let ret = ''
|
||||
for (let it in data) {
|
||||
ret += encodeURIComponent(it) + '=' + encodeURIComponent(data[it]) + '&'
|
||||
}
|
||||
return ret
|
||||
}],
|
||||
headers: {
|
||||
'Content-Type': 'application/x-www-form-urlencoded',
|
||||
'X-Access-Token':_this.token
|
||||
let _array = []
|
||||
this.selectedRowKeysValue.forEach((item, index) => {
|
||||
_array.push(item.id)
|
||||
})
|
||||
let _this = this
|
||||
let param = {projectId: this.$route.query.id, ids: _array.join(',')}
|
||||
axios({
|
||||
url: '/jero-boot/params/collectManifest/issueCollection',
|
||||
method: 'post',
|
||||
data: param,
|
||||
transformRequest: [function (data) {
|
||||
let ret = ''
|
||||
for (let it in data) {
|
||||
ret += encodeURIComponent(it) + '=' + encodeURIComponent(data[it]) + '&'
|
||||
}
|
||||
return ret
|
||||
}],
|
||||
headers: {
|
||||
'Content-Type': 'application/x-www-form-urlencoded',
|
||||
'X-Access-Token':_this.token
|
||||
}
|
||||
})
|
||||
.then( (res) =>{
|
||||
console.log(res)
|
||||
if (res.data.success) {
|
||||
_this.$message.success(res.data.result)
|
||||
_this.areaVisible = false
|
||||
_this.getTableList()
|
||||
_this.selectedRowKeysValue=[]
|
||||
}else{
|
||||
_this.$message.warning(res.data.result)
|
||||
}
|
||||
})
|
||||
.then( (res) =>{
|
||||
console.log(res)
|
||||
if (res.data.success) {
|
||||
_this.$message.success(res.data.result)
|
||||
_this.areaVisible = false
|
||||
_this.getTableList()
|
||||
_this.selectedRowKeysValue=[]
|
||||
}else{
|
||||
_this.$message.warning(res.data.result)
|
||||
}
|
||||
})
|
||||
.catch( (error) =>{
|
||||
console.log(error);
|
||||
});
|
||||
}
|
||||
.catch( (error) =>{
|
||||
console.log(error);
|
||||
});
|
||||
},
|
||||
// 添加
|
||||
handleAdd() {
|
||||
// 先判断是否有权限 认证工程师 待发起收集
|
||||
let permissionmoAndinitiated = this.permissionmoAndinitiated()
|
||||
if(permissionmoAndinitiated) {
|
||||
if(this.homo) {
|
||||
// 认证工程师 任意状态 都有此权限
|
||||
this.areaVisible = true
|
||||
}
|
||||
},
|
||||
// 提交
|
||||
handleSubmit() {
|
||||
let postDate = []
|
||||
this.selectedRowKeysValue.forEach((item, index) => {
|
||||
let postDateobj = {}
|
||||
Object.keys(item).forEach((itemIn, index) => {
|
||||
if(itemIn !== 'sdt') {
|
||||
if(item[itemIn] instanceof Object) {
|
||||
postDateobj[itemIn] = item[itemIn]
|
||||
// 先判断提交权限
|
||||
if(this.homo) {
|
||||
// 认证工程师 任意状态 都无此权限
|
||||
this.$message.warning(this.$t('operatethisbutton'))
|
||||
} else {
|
||||
// 提交数据
|
||||
let postDate = []
|
||||
this.selectedRowKeysValue.forEach((item, index) => {
|
||||
let postDateobj = {}
|
||||
Object.keys(item).forEach((itemIn, index) => {
|
||||
if(itemIn !== 'sdt') {
|
||||
if(item[itemIn] instanceof Object) {
|
||||
postDateobj[itemIn] = item[itemIn]
|
||||
}
|
||||
}
|
||||
}
|
||||
})
|
||||
postDateobj.id = item.id
|
||||
postDate.push(postDateobj)
|
||||
})
|
||||
let configDataList = { configDataList: postDate }
|
||||
if(this.selectedRowKeys.length == 0) {
|
||||
this.$message.warning(this.$t('selectLeastOne'))
|
||||
}else {
|
||||
postAction(this.url.add, configDataList).then((res) => {
|
||||
if (res.success) {
|
||||
this.$message.success(this.$t('OperationSuccessful'))
|
||||
} else {
|
||||
this.$message.warning(this.$t('operationFailed'))
|
||||
}
|
||||
})
|
||||
postDateobj.id = item.id
|
||||
postDate.push(postDateobj)
|
||||
})
|
||||
let configDataList = { configDataList: postDate }
|
||||
if(this.selectedRowKeys.length == 0) {
|
||||
this.$message.warning(this.$t('selectLeastOne'))
|
||||
}else {
|
||||
postAction(this.url.add, configDataList).then((res) => {
|
||||
if (res.success) {
|
||||
this.$message.success(this.$t('OperationSuccessful'))
|
||||
} else {
|
||||
this.$message.warning(this.$t('operationFailed'))
|
||||
}
|
||||
})
|
||||
}
|
||||
}
|
||||
},
|
||||
// 退回
|
||||
@@ -584,7 +589,12 @@ export default {
|
||||
},
|
||||
// 分配填写人
|
||||
assignedBy() {
|
||||
this.areaVisibleAssignedby = true
|
||||
if(this.homo) {
|
||||
// 认证工程师 任意状态 都无此权限
|
||||
this.$message.warning(this.$t('operatethisbutton'))
|
||||
} else {
|
||||
this.areaVisibleAssignedby = true
|
||||
}
|
||||
},
|
||||
// 分配填写人确定后弹框关闭
|
||||
areaVisibleAssignedbyflag(val) {
|
||||
@@ -592,7 +602,12 @@ export default {
|
||||
},
|
||||
// 截止时间
|
||||
TaskCutOffTime() {
|
||||
this.areaVisibleTaskCutOffTime = true
|
||||
if(this.homo) {
|
||||
// 认证工程师 任意状态 都无此权限
|
||||
this.$message.warning(this.$t('operatethisbutton'))
|
||||
} else {
|
||||
this.areaVisibleTaskCutOffTime = true
|
||||
}
|
||||
},
|
||||
// 截至时间确定弹框关闭
|
||||
areaVisibleTaskCutOffTimeflag(val) {
|
||||
@@ -601,7 +616,12 @@ export default {
|
||||
},
|
||||
//引用参数
|
||||
referenceparameter() {
|
||||
this.areaVisiblereferenceparameter = true
|
||||
if(this.homo) {
|
||||
// 认证工程师 任意状态 都无此权限
|
||||
this.$message.warning(this.$t('operatethisbutton'))
|
||||
} else {
|
||||
this.areaVisiblereferenceparameter = true
|
||||
}
|
||||
},
|
||||
handleModule() {
|
||||
|
||||
@@ -617,9 +637,6 @@ export default {
|
||||
this.$refs.CollectionTabel.getTableListReset()
|
||||
},
|
||||
handleDel(){
|
||||
// 先判断是否有权限 认证工程师 待发起收集
|
||||
let permissionmoAndinitiated = this.permissionmoAndinitiated()
|
||||
if(permissionmoAndinitiated) {
|
||||
let param={
|
||||
ids: this.selectedRowKeysArray
|
||||
}
|
||||
@@ -662,7 +679,6 @@ export default {
|
||||
} else {
|
||||
this.$message.warning(this.$t('selectLeastOne'))
|
||||
}
|
||||
}
|
||||
},
|
||||
pageOnChange() {
|
||||
|
||||
|
||||
Reference in New Issue
Block a user