[update 拆分] 查看和编辑验证企标权限
This commit is contained in:
@@ -465,7 +465,8 @@ module.exports = {
|
||||
addQuantity: 'Add Quantity',
|
||||
enterQuantity: 'Please enter quantity',
|
||||
numberRows: 'Number of rows',
|
||||
numberColumns: 'Number of columns'
|
||||
numberColumns: 'Number of columns',
|
||||
noPermission: 'You do not have permission to view this enterprise logo'
|
||||
},
|
||||
comparison: {
|
||||
oldDocumentTextNumber: 'Old document text number',
|
||||
@@ -593,11 +594,11 @@ module.exports = {
|
||||
noFileMsg: 'Please select a file'
|
||||
},
|
||||
// 属性标识管理
|
||||
attributeIdentification:{
|
||||
labelName:'Label Name',
|
||||
firstLabel:'First Label',
|
||||
secondLabel:'Second Label',
|
||||
thirdLabel:'Third Label',
|
||||
attributeIdentification: {
|
||||
labelName: 'Label Name',
|
||||
firstLabel: 'First Label',
|
||||
secondLabel: 'Second Label',
|
||||
thirdLabel: 'Third Label'
|
||||
},
|
||||
// 系统管理
|
||||
system,
|
||||
|
||||
@@ -480,7 +480,8 @@ module.exports = {
|
||||
numberRows: '行数',
|
||||
numberColumns: '列数',
|
||||
maximumSelection: '最多选择',
|
||||
pieceOfData: '条数据'
|
||||
pieceOfData: '条数据',
|
||||
noPermission: '您没有查看该企标的权限'
|
||||
},
|
||||
// 文档比对
|
||||
comparison: {
|
||||
@@ -644,7 +645,7 @@ module.exports = {
|
||||
fileFormatIncorrect: '文件格式不正确',
|
||||
uploadSuccessful: '上传成功',
|
||||
uploadMaximumATime: '一次最多上传二十张图片',
|
||||
deletedSuccessfully: '删除成功',
|
||||
deletedSuccessfully: '删除成功'
|
||||
},
|
||||
importWithTemplate: {
|
||||
chooseFile: '选择文件',
|
||||
|
||||
@@ -218,9 +218,7 @@ export default {
|
||||
},
|
||||
// 查询
|
||||
searchQuery () {
|
||||
const query = Object.assign({}, this.queryParam)
|
||||
query.serial_number = this.spiltInfo.serialNumber
|
||||
this.initDetailInfo(query)
|
||||
this.initDetailInfo(this.queryParam)
|
||||
},
|
||||
// 重置
|
||||
searchReset () {
|
||||
@@ -235,7 +233,9 @@ export default {
|
||||
},
|
||||
initDetailInfo (query) {
|
||||
this.loading = true
|
||||
const params = Object.assign({}, this.queryParams, query)
|
||||
const params = Object.assign({
|
||||
serial_number: this.spiltInfo.serialNumber
|
||||
}, this.queryParams, query)
|
||||
if (this.horizontalOverstep) {
|
||||
params.horizontalOverstep = true
|
||||
}
|
||||
@@ -247,6 +247,8 @@ export default {
|
||||
this.treeData = data.sarFileSplitMenuEO || []
|
||||
this.spiltInfo = data.documentSplitInfo || {}
|
||||
this.clauseContentList = data.documentSplitDetail || []
|
||||
} else {
|
||||
this.$message.warn(res.message)
|
||||
}
|
||||
}).finally(() => {
|
||||
this.loading = false
|
||||
|
||||
@@ -99,8 +99,9 @@ import { JeroListMixin } from '@/mixins/JeroListMixin'
|
||||
import { releaseSplitStandard, changePermission, withdraw } from '@api/documentToolApi'
|
||||
import ImportSplitResultModal from './modules/ImportSplitResultModal.vue'
|
||||
import UserSelectModal from '../../../components/selection/UserSelectModal.vue'
|
||||
import { SplitStatus, StandardSource } from '@/enums/commonEnums'
|
||||
import { SplitStandardSource, SplitStatus, StandardSource } from '@/enums/commonEnums'
|
||||
import { mapGetters } from 'vuex'
|
||||
import { isCanLookDetail } from '@api/enterpriseStandardLibraryApi'
|
||||
|
||||
export default {
|
||||
name: 'DocumentSplit',
|
||||
@@ -285,28 +286,56 @@ export default {
|
||||
}
|
||||
})
|
||||
},
|
||||
// 验证企标权限
|
||||
checkEnterpriseStandardAuth (record, callback) {
|
||||
// 不是企标直接执行回调
|
||||
if (record.splitStandardSource !== SplitStandardSource.ENTERPRISE.value) {
|
||||
callback && callback()
|
||||
return
|
||||
}
|
||||
// 企标需要校验权限
|
||||
this.loading = true
|
||||
// 判断是否有权限,没有权限不能进查看
|
||||
isCanLookDetail({ id: record.standardId }).then(res => {
|
||||
if (res.success) {
|
||||
if (res.result) {
|
||||
callback && callback()
|
||||
} else {
|
||||
this.$message.warn(this.$t('docTool.split.noPermission'))
|
||||
}
|
||||
} else {
|
||||
this.$message.warn(res.message)
|
||||
}
|
||||
}).finally(() => {
|
||||
this.loading = false
|
||||
})
|
||||
},
|
||||
// 编辑
|
||||
handleEdit (record) {
|
||||
this.$router.push({
|
||||
path: '/docTool/DocSplitDetail',
|
||||
query: {
|
||||
infoId: record.id,
|
||||
infoNumber: record.serialNumber,
|
||||
createBy: record.createBy,
|
||||
standardName: record.title
|
||||
}
|
||||
this.checkEnterpriseStandardAuth(record, () => {
|
||||
this.$router.push({
|
||||
path: '/docTool/DocSplitDetail',
|
||||
query: {
|
||||
infoId: record.id,
|
||||
infoNumber: record.serialNumber,
|
||||
createBy: record.createBy,
|
||||
standardName: record.title
|
||||
}
|
||||
})
|
||||
})
|
||||
},
|
||||
/**
|
||||
* 表格操作列的查看
|
||||
* @param id
|
||||
* @param record
|
||||
*/
|
||||
handleDetail ({ id }) {
|
||||
this.$openPageNewSheet({
|
||||
path: '/docTool/StandardSplitSheet',
|
||||
query: {
|
||||
id
|
||||
}
|
||||
async handleDetail (record) {
|
||||
this.checkEnterpriseStandardAuth(record, () => {
|
||||
this.$openPageNewSheet({
|
||||
path: '/docTool/StandardSplitSheet',
|
||||
query: {
|
||||
id: record.id
|
||||
}
|
||||
})
|
||||
})
|
||||
},
|
||||
splitTextVisible (val, num) {
|
||||
|
||||
Reference in New Issue
Block a user