[update] 联调企标收藏
This commit is contained in:
@@ -21,7 +21,9 @@ const initChange = (params) => getAction('', params)
|
|||||||
// 临时权限设置
|
// 临时权限设置
|
||||||
const temporaryPermissionSet = (params) => postAction('/laws/standard/enterprise/tempPermission', params)
|
const temporaryPermissionSet = (params) => postAction('/laws/standard/enterprise/tempPermission', params)
|
||||||
// 收藏企标
|
// 收藏企标
|
||||||
const collectStandard = (params) => getAction('', params)
|
const collectStandard = (params) => postAction('/personal/lawsStandardCollection/enterprise/add', params)
|
||||||
|
// 取消收藏企标
|
||||||
|
const cancelCollectStandard = (params) => postAction('/personal/lawsStandardCollection/enterprise/delete', params)
|
||||||
// 分享企标
|
// 分享企标
|
||||||
const shareStandard = (params) => getAction('', params)
|
const shareStandard = (params) => getAction('', params)
|
||||||
|
|
||||||
@@ -55,6 +57,7 @@ export {
|
|||||||
initChange,
|
initChange,
|
||||||
temporaryPermissionSet,
|
temporaryPermissionSet,
|
||||||
collectStandard,
|
collectStandard,
|
||||||
|
cancelCollectStandard,
|
||||||
shareStandard,
|
shareStandard,
|
||||||
|
|
||||||
setQualityStandard,
|
setQualityStandard,
|
||||||
|
|||||||
@@ -169,6 +169,6 @@ export default {
|
|||||||
|
|
||||||
<style scoped>
|
<style scoped>
|
||||||
.ant-calendar-picker {
|
.ant-calendar-picker {
|
||||||
min-width: 195px;
|
/*min-width: 195px;*/
|
||||||
}
|
}
|
||||||
</style>
|
</style>
|
||||||
|
|||||||
@@ -161,6 +161,7 @@ import {
|
|||||||
shiftStandard,
|
shiftStandard,
|
||||||
initChange,
|
initChange,
|
||||||
collectStandard,
|
collectStandard,
|
||||||
|
cancelCollectStandard,
|
||||||
shareStandard,
|
shareStandard,
|
||||||
deleteTreeNode
|
deleteTreeNode
|
||||||
} from '@api/enterpriseStandardLibraryApi'
|
} from '@api/enterpriseStandardLibraryApi'
|
||||||
@@ -415,15 +416,31 @@ export default {
|
|||||||
},
|
},
|
||||||
// 收藏
|
// 收藏
|
||||||
handleCollection (record) {
|
handleCollection (record) {
|
||||||
const params = {}
|
if (record.collectionFlag) {
|
||||||
params.id = record.id
|
const params = {}
|
||||||
collectStandard(params).then(res => {
|
params.id = record.id
|
||||||
if (res.success) {
|
// 说明已收藏,调取消收藏接口
|
||||||
this.$message.success(res.message)
|
cancelCollectStandard(params).then(res => {
|
||||||
} else {
|
if (res.success) {
|
||||||
this.$message.warning(res.message)
|
this.$message.success(res.message)
|
||||||
}
|
this.loadData()
|
||||||
})
|
} else {
|
||||||
|
this.$message.warning(res.message)
|
||||||
|
}
|
||||||
|
})
|
||||||
|
} else {
|
||||||
|
const params = {}
|
||||||
|
params.standardId = record.id
|
||||||
|
params.standardNumber = record.standard_no
|
||||||
|
collectStandard(params).then(res => {
|
||||||
|
if (res.success) {
|
||||||
|
this.$message.success(res.message)
|
||||||
|
this.loadData()
|
||||||
|
} else {
|
||||||
|
this.$message.warning(res.message)
|
||||||
|
}
|
||||||
|
})
|
||||||
|
}
|
||||||
},
|
},
|
||||||
// 分享
|
// 分享
|
||||||
handleShare (record) {
|
handleShare (record) {
|
||||||
|
|||||||
Reference in New Issue
Block a user