diff --git a/front/src/api/home.js b/front/src/api/home.js index 2f536134..8a0d6787 100644 --- a/front/src/api/home.js +++ b/front/src/api/home.js @@ -199,7 +199,14 @@ export function updateVisits(params) { params, }) } - +// 保存浏览记录 +export function browsingInsert(data) { + return request({ + url: '/resourceBrowse/insert', + method: 'post', + data, + }) +} // 最新能力 export function selectNewest(data) { return request({ diff --git a/front/src/views/detailsAll/AlgorithmDetails.vue b/front/src/views/detailsAll/AlgorithmDetails.vue index b870c33b..bb7a9b71 100644 --- a/front/src/views/detailsAll/AlgorithmDetails.vue +++ b/front/src/views/detailsAll/AlgorithmDetails.vue @@ -10,182 +10,159 @@ - + + - + - + - + - - + + + + - + - + + - + - + + diff --git a/front/src/views/detailsAll/ApplicationDetails.vue b/front/src/views/detailsAll/ApplicationDetails.vue index 262063d5..7eee09d3 100644 --- a/front/src/views/detailsAll/ApplicationDetails.vue +++ b/front/src/views/detailsAll/ApplicationDetails.vue @@ -52,7 +52,12 @@ import ApplicationPresentation from '@/views/detailsAll/components/Application/A import ApplicationCommonProblem from '@/views/detailsAll/components/Application/ApplicationCommonProblem' //常见问题 import { ref, onMounted, onBeforeUnmount, reactive } from 'vue' import { useRouter } from 'vue-router' -import { updateVisits, selectOne, queryPartAppByKeyId } from '@/api/home' +import { + updateVisits, + selectOne, + queryPartAppByKeyId, + browsingInsert, +} from '@/api/home' import mybus from '@/myplugins/mybus' const associatedComponents = ref([{ type: '组件服务', dataList: [] }]) let loading = ref(true) @@ -124,6 +129,12 @@ const init = (id) => { ) }) } + // 浏览记录 + browsingInsert({ + resourceId: res.data.data.id, + }).then(() => { + console.log('浏览记录+1') + }) }) associatedComponents.value.map((item, index) => { let queryPartAppByKeyIdParams = { diff --git a/front/src/views/detailsAll/BusinessDetails.vue b/front/src/views/detailsAll/BusinessDetails.vue index c630e25c..cb14bfd2 100644 --- a/front/src/views/detailsAll/BusinessDetails.vue +++ b/front/src/views/detailsAll/BusinessDetails.vue @@ -10,165 +10,149 @@ - + - + - + + - + + - + + - + + - + - + diff --git a/front/src/views/detailsAll/DeveloperComponents.vue b/front/src/views/detailsAll/DeveloperComponents.vue index e7f0a403..be9c7f40 100644 --- a/front/src/views/detailsAll/DeveloperComponents.vue +++ b/front/src/views/detailsAll/DeveloperComponents.vue @@ -10,175 +10,157 @@ - + - + - + + - + + - + + - + + - + - + - + + diff --git a/front/src/views/detailsAll/LayerService.vue b/front/src/views/detailsAll/LayerService.vue index 799c98b1..6228798c 100644 --- a/front/src/views/detailsAll/LayerService.vue +++ b/front/src/views/detailsAll/LayerService.vue @@ -8,176 +8,156 @@