From 4c85700094b1f4f4696ed2fb0d5985f0f2602ae0 Mon Sep 17 00:00:00 2001 From: gaoyuanwei <2826352639@qq.com> Date: Tue, 5 Jul 2022 10:11:50 +0800 Subject: [PATCH 1/4] =?UTF-8?q?=E5=85=B3=E8=81=94=E7=BB=84=E4=BB=B6?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- front/src/api/personalCenter.js | 8 ++++ .../components/PutOnTheShelf.vue | 38 ++++++++++++++++--- 2 files changed, 41 insertions(+), 5 deletions(-) diff --git a/front/src/api/personalCenter.js b/front/src/api/personalCenter.js index d6a61432..67079961 100644 --- a/front/src/api/personalCenter.js +++ b/front/src/api/personalCenter.js @@ -223,3 +223,11 @@ export function queryApplicationRelByResourceId(params) { params, }) } +// 获取关联组件列表 +export function queryResourceRelByKeyId(params) { + return request({ + url: '/dataResourceRel/queryResourceRelByKeyId', + method: 'get', + params, + }) +} diff --git a/front/src/views/capacityOnTheShelf/components/PutOnTheShelf.vue b/front/src/views/capacityOnTheShelf/components/PutOnTheShelf.vue index 789dabd6..96eae8fe 100644 --- a/front/src/views/capacityOnTheShelf/components/PutOnTheShelf.vue +++ b/front/src/views/capacityOnTheShelf/components/PutOnTheShelf.vue @@ -79,6 +79,9 @@ 请选择来源应用 + + 请选择关联组件 +
- +
+ :data-source="mockData" :titles="titles" :render="(item) => item.title" @change="handleChange" + @selectChange="handleSelectChange" />
@@ -120,6 +123,7 @@ import { message } from 'ant-design-vue' import { getCategoryTreePage, queryApplicationRelByResourceId, + queryResourceRelByKeyId, } from '@/api/personalCenter' import { useRouter } from 'vue-router' @@ -327,6 +331,8 @@ const ApplicationArea = (item, itemson) => { // 来源应用 const visibleAssociatedApplication = ref(false) const mockData = ref([]) +const titles = ref(['未关联的应用名称', '已关联的应用名称']) +const titleName = ref('关联应用') const sourceClick = () => { visibleAssociatedApplication.value = true @@ -344,6 +350,28 @@ const sourceClick = () => { }) }) } +// 关联组件 +const componentsClick = () => { + titles.value = ['未关联的组件名称', '已关联的组件名称'] + titleName.value = '关联组件' + + visibleAssociatedApplication.value = true + queryResourceRelByKeyId({ + keyId: 0, + type: '组件服务', + referenceName: '', + }).then((res) => { + // console.log(res.data.data.notLinked) + res.data.data.notLinked.forEach((val, index) => { + // console.log(val, index) + mockData.value.push({ + key: val.id, + title: val.name, + description: val.id, + }) + }) + }) +} const targetKeys = ref([]) const selectedKeys = ref([]) @@ -362,7 +390,7 @@ const handleOk = (e) => { visibleAssociatedApplication.value = false // console.log('2222222222222', props.refData) data.value.list.map((item) => { - if (item.name === '来源应用') { + if (item.name === '来源应用' || item.name === '关联组件信息') { item.note1 = targetKeys.value + '' } }) From a6488d0c9293e06336c857bad3976a4e6de2df1b Mon Sep 17 00:00:00 2001 From: a0049873 <79py69t9wb@privaterelay.appleid.com> Date: Tue, 5 Jul 2022 10:39:59 +0800 Subject: [PATCH 2/4] =?UTF-8?q?=E4=BF=AE=E6=94=B9=E6=95=B0=E6=8D=AE?= =?UTF-8?q?=E8=B5=84=E6=BA=90=E5=88=A4=E6=96=AD?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- front/src/views/home/components/searchResultList.vue | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/front/src/views/home/components/searchResultList.vue b/front/src/views/home/components/searchResultList.vue index db9ced7a..9d40a781 100644 --- a/front/src/views/home/components/searchResultList.vue +++ b/front/src/views/home/components/searchResultList.vue @@ -37,7 +37,7 @@ :class=" item.type == '应用资源' ? 'yyzy' - : item.type == '数据资源' + : !item.type ? 'sjzy' : item.infoList && item.infoList.filter((val) => val.attrType == '组件类型')[0] From ae188ef656e6d3a2de28b54d8df6071f2195ac8f Mon Sep 17 00:00:00 2001 From: a0049873 <79py69t9wb@privaterelay.appleid.com> Date: Tue, 5 Jul 2022 11:28:30 +0800 Subject: [PATCH 3/4] =?UTF-8?q?=E8=B5=8B=E8=83=BD=E6=A1=88=E4=BE=8B=20?= =?UTF-8?q?=E6=BB=9A=E5=8A=A8=E6=9D=A1=E8=81=94=E5=8A=A8?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../components/AssignCaseDetailPage.vue | 154 ++++++++++-------- 1 file changed, 89 insertions(+), 65 deletions(-) diff --git a/front/src/views/assignCase/components/AssignCaseDetailPage.vue b/front/src/views/assignCase/components/AssignCaseDetailPage.vue index dd6bf0a5..fdde065e 100644 --- a/front/src/views/assignCase/components/AssignCaseDetailPage.vue +++ b/front/src/views/assignCase/components/AssignCaseDetailPage.vue @@ -2,7 +2,7 @@ * @Author: hisense.zhangfeihu * @Date: 2022-06-13 10:22:27 * @LastEditors: hisense.liangjunhua - * @LastEditTime: 2022-07-04 15:32:52 + * @LastEditTime: 2022-07-05 11:25:25 * @Description: 赋能案例-详情页 -->