[update] 修改企标操作完成的更新有的刷树有的不刷,临时权限设置字段修改,企标详情下载加水印

This commit is contained in:
lideqin
2023-09-27 15:59:52 +08:00
parent b7a60b1fe9
commit a8213042ed
3 changed files with 27 additions and 7 deletions
@@ -134,7 +134,7 @@
<!-- 新增编辑弹框 --> <!-- 新增编辑弹框 -->
<enterprise-standard-modal ref="modalForm" @ok="modalFormOk"></enterprise-standard-modal> <enterprise-standard-modal ref="modalForm" @ok="modalFormOk"></enterprise-standard-modal>
<!-- 配置标准-标准选择弹框 --> <!-- 配置标准-标准选择弹框 -->
<allocation-standard-drawer ref="allocationStandardDrawer" @ok="modalFormOk"></allocation-standard-drawer> <allocation-standard-drawer ref="allocationStandardDrawer" @ok="modalOkDoNotRefreshTree"></allocation-standard-drawer>
<!-- 临时权限设置 --> <!-- 临时权限设置 -->
<temporary-permission-set ref="temporaryPermissionSet" @ok="modalFormOk"></temporary-permission-set> <temporary-permission-set ref="temporaryPermissionSet" @ok="modalFormOk"></temporary-permission-set>
<!-- 左侧树节点的新增和编辑 --> <!-- 左侧树节点的新增和编辑 -->
@@ -412,7 +412,7 @@ export default {
}, },
// 移出标准 // 移出标准
handleShiftOutStandard () { handleShiftOutStandard () {
// 没选择左侧树节点,需要提示“请先选择二级及以下体系” // 没选择左侧树节点,需要提示“请先选择左侧体系”
if (!this.currentTreeNode || this.currentTreeNode.length === 0) { if (!this.currentTreeNode || this.currentTreeNode.length === 0) {
this.$message.warn(this.$t('enterpriseStandardLibrary.standard.pleaseSelectLeastOneNode')) this.$message.warn(this.$t('enterpriseStandardLibrary.standard.pleaseSelectLeastOneNode'))
return return
@@ -430,7 +430,11 @@ export default {
shiftStandard(params).then(res => { shiftStandard(params).then(res => {
if (res.success) { if (res.success) {
this.$message.success(res.message) this.$message.success(res.message)
this.modalFormOk() // 判断当前删除的数据是否是最后一页的最后一条数据,如果是的话页码减一
if (this.ipagination.current > 1 && ((this.ipagination.current - 1) * this.ipagination.pageSize) + 1 === this.ipagination.total) {
this.ipagination.current -= 1
}
this.modalOkDoNotRefreshTree()
} else { } else {
this.$message.warn(res.message) this.$message.warn(res.message)
} }
@@ -540,6 +544,22 @@ export default {
id: record.id id: record.id
} }
}) })
},
// 操作完需要刷树的回调
modalFormOk () {
this.selectedTreeKeys = []
this.filters.nodeCode = null
this.initTreeData()
// 新增/修改 成功时,重载列表
this.loadData()
// 清空列表选中
this.onClearSelected()
},
modalOkDoNotRefreshTree () {
// 新增/修改 成功时,重载列表
this.loadData()
// 清空列表选中
this.onClearSelected()
} }
} }
} }
@@ -272,11 +272,11 @@ export default {
}, },
handleDownload (file) { handleDownload (file) {
// 下载文件 // 下载文件
downloadFile(`/sys/common/download/${file.id}`, file.fileName) downloadFile(`/laws/standard/common/downloadWithWaterMark/${file.id}`, file.fileName)
}, },
// 过程稿件里的无水印下载 // 过程稿件里的无水印下载
downloadDraftNoWater (fileId, fileName) { downloadDraftNoWater (file) {
downloadFile(`/sys/common/download/${file.id}`, file.fileName)
}, },
// 企标评价 // 企标评价
handleEvaluate () { handleEvaluate () {
@@ -102,7 +102,7 @@ export default {
if (!err) { if (!err) {
this.confirmLoading = true this.confirmLoading = true
const param = Object.assign({}, values) const param = Object.assign({}, values)
param.standardNos = this.model.standards param.standardIds = this.model.standards
temporaryPermissionSet(param).then(res => { temporaryPermissionSet(param).then(res => {
if (res.success) { if (res.success) {
this.$message.success(res.message) this.$message.success(res.message)