@@ -112,11 +112,11 @@
import { addDocument, updateDocument, getDocument } from "@/api/document/document";
import { deptTreeSelect } from "@/api/system/user";
import { documentTree } from "@/api/documentCategory/documentCategory.js";
- import { listDiscussions, addDiscussions } from "@/api/tool/discussions.js";
import { listReplies, addReplies} from "@/api/tool/replies.js";
import { listAttachment } from "@/api/attachment/attachment";
import { addCount } from "@/api/tool/downloadCount";
import previewUtil from '@/components/PreviewUtil/previewUtil.vue'
+ import { listDiscussions, addDiscussions } from "@/api/tool/discussions.js";
export default {
name: 'editDocument',
@@ -217,6 +217,7 @@
created(){
// this.getDeptTree();
this.getDocumentTree();
+ // this.getDiscussionsList()
},
mounted(){
},
@@ -311,6 +312,7 @@
self.dataFile.push(fileData) */
self.getAttachmentList()
+ self.getDiscussionsList()
setTimeout(() => {
self.$set(self.form, "docCategoryName" , self.findLabelById(self.docCategory, self.form.docCategoryId) )
@@ -343,7 +345,7 @@
type:'success', //类型是成功
duration:1200, //显示时间, 毫秒。设为 0 则不会自动关闭,建议1200
});
- self.getAttachmentList()
+ self.getDiscussionsList()
}).catch(err =>{
this.discussionContent = null
console.error("handleDiscussions==err==", err)
@@ -411,7 +413,7 @@
duration:1200, //显示时间, 毫秒。设为 0 则不会自动关闭,建议1200
});
self.cancelReplySon(parentIndex, repIndex)
- self.getAttachmentList()
+ self.getDiscussionsList()
}).catch(err =>{
console.error("submitReplySon==err==", err)
self.$modal.msgError("发布失败");
@@ -447,7 +449,7 @@
duration:1200, //显示时间, 毫秒。设为 0 则不会自动关闭,建议1200
});
self.cancelReply(index)
- self.getAttachmentList()
+ self.getDiscussionsList()
}).catch(err =>{
console.error("handleDiscussions==err==", err)
self.$modal.msgError("发布失败");
@@ -574,7 +576,22 @@
}
}
return null;
- }
+ },
+ getDiscussionsList() {
+ let self = this
+ listDiscussions({businessId:self.form.docId}).then(res => {
+ self.discussionsList = res.rows
+ self.discussionsList.forEach(item => {
+ if(item.repliesList && item.repliesList.length > 0){
+ self.$set(item, 'showReplyFormSon', new Array(item.repliesList.length).fill(false))
+ self.$set(item, 'replyContentSon', new Array(item.repliesList.length).fill(''))
+ }else{
+ self.$set(item, 'showReplyFormSon', false)
+ self.$set(item, 'replyContentSon', '')
+ }
+ });
+ });
+ },
}
}
diff --git a/src/views/document/downloadFileDetail.vue b/src/views/document/downloadFileDetail.vue
index 74a57b9..d7d085f 100644
--- a/src/views/document/downloadFileDetail.vue
+++ b/src/views/document/downloadFileDetail.vue
@@ -2,7 +2,7 @@
-
+
diff --git a/src/views/document/editDocument.vue b/src/views/document/editDocument.vue
index 51a8b9b..8dc94cd 100644
--- a/src/views/document/editDocument.vue
+++ b/src/views/document/editDocument.vue
@@ -128,7 +128,7 @@
-
diff --git a/src/views/tool/AddDoc.vue b/src/views/tool/AddDoc.vue
index 475e772..8d5481d 100644
--- a/src/views/tool/AddDoc.vue
+++ b/src/views/tool/AddDoc.vue
@@ -2,8 +2,8 @@
diff --git a/src/views/tool/downloadFileDetail.vue b/src/views/tool/downloadFileDetail.vue
index 9a14c2c..f343e17 100644
--- a/src/views/tool/downloadFileDetail.vue
+++ b/src/views/tool/downloadFileDetail.vue
@@ -2,7 +2,7 @@
-
+
diff --git a/src/views/tool/index.vue b/src/views/tool/index.vue
index ed83ee6..1229c36 100644
--- a/src/views/tool/index.vue
+++ b/src/views/tool/index.vue
@@ -89,9 +89,10 @@
icon="el-icon-plus"
@click="handleAdd"
>工具发布
+ 全量导出
+ 批量导出
批量删除
- 全量导出
- 批量导出
+
@@ -114,7 +115,7 @@
-
-
+
-
+
- 引用工具 ({{ scope.row.relationToolList.length }})
+ 关联工具 ({{ scope.row.relationToolList.length }})
@@ -184,7 +185,8 @@
-
+
-
+
+
+
+
+
+
+
@@ -144,6 +184,7 @@
import { addCount } from "@/api/tool/downloadCount";
import { listAttachment } from "@/api/attachment/attachment";
import previewUtil from '@/components/PreviewUtil/previewUtil.vue'
+ import { getDataThree } from '@/api/tool/toolRelation'
export default {
name: 'toolDetail',
@@ -208,7 +249,17 @@
previewLoading:false,
previewUseFront: "txt,doc,docx,pdf",
isPreviewDisable: false,
- total: 0
+ total: 0,
+ //工具树显示
+ toolTreeVisible: false,
+ toolTreeLoading: false,
+ toolDataList: [],
+ defaultProps: {
+ children: 'children',
+ label: 'label'
+ },
+ //工具关系选择项
+ toolRelationOptions: [],
}
},
@@ -445,6 +496,7 @@
self.detailLoading = true
getTool(self.toolDetail.toolId).then((res) => {
self.detailData = res.data
+ self.detailData.association = JSON.parse(res.data.association)
/*let formData = res.data;
formData.type = _this.form.type
_this.form = formData*/
@@ -470,6 +522,45 @@
const extension = parts.pop();
return extension;
},
+ /** 获取工具关联树展示 */
+ getToolRelationTree() {
+ let self = this
+ let toolRelation ={
+ resourceId: "",
+ }
+ let toolIds = []
+ if(self.detailData.toolId){
+ self.$set(toolRelation,"resourceIds",[self.detailData.toolId])
+ }else if(self.detailData.association && self.detailData.association.length > 0){
+ self.detailData.association.forEach(item=>{
+ toolIds.push(item.toolId)
+ })
+ self.$set(toolRelation,"resourceIds",toolIds)
+ }
+
+ self.toolTreeVisible = true;
+ self.toolTreeLoading = true;
+ getDataThree(toolRelation).then(res => {
+ if(self.detailData.toolName){
+ let treeArray = []
+ let treeData = {
+ "id": "20240908001",
+ "label": self.detailData.toolName,
+ "types": null,
+ "children": res.data
+ }
+ treeArray.push(treeData)
+ this.toolRelationOptions = treeArray;
+ self.toolTreeLoading = false;
+ return
+ }
+ this.toolRelationOptions = res.data;
+ self.toolTreeLoading = false;
+ }).catch(err => {
+ console.error("err========", err)
+ self.toolTreeLoading = false;
+ });
+ },
}
}
diff --git a/src/views/workflowList/addWorkflow/tool_release.vue b/src/views/workflowList/addWorkflow/tool_release.vue
index bac13eb..ca983ab 100644
--- a/src/views/workflowList/addWorkflow/tool_release.vue
+++ b/src/views/workflowList/addWorkflow/tool_release.vue
@@ -191,8 +191,11 @@
-
-
+ 查看
+ 新增关联工具
+ 编辑关联工具
+
@@ -243,7 +246,7 @@
-
+
@@ -297,9 +300,7 @@
>
@@ -307,7 +308,7 @@
v-if="monitorDrawerVisible"
ref="monitorDrawer"
>
-
+
@@ -315,11 +316,85 @@
+
+
+
+
+
+
+
+
+
+
+ 删除
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+