diff --git a/back/public/index.html b/back/public/index.html
index 1d32cc9d..d96dc6a3 100644
--- a/back/public/index.html
+++ b/back/public/index.html
@@ -1,8 +1,8 @@
@@ -44,7 +44,7 @@
// window.SITE_CONFIG['apiURL'] = 'http://15.2.21.166:8888/renren-admin';
// window.SITE_CONFIG['apiURL'] = 'http://124.222.94.39:8888/renren-admin';
// window.SITE_CONFIG['apiURL'] = 'http://10.16.5.35:8888/renren-admin';
- window.SITE_CONFIG['apiURL'] = 'http://15.2.21.239:8888/renren-admin';
+ window.SITE_CONFIG['apiURL'] = 'http://15.2.21.238:8888/renren-admin';
window.SITE_CONFIG['previewUrl'] = 'http://15.2.21.238:9796/';
// window.SITE_CONFIG['apiURL'] = 'http://15.2.23.141:8000/renren-admin';
// WebSocket地址
diff --git a/back/src/mixins/view-module.js b/back/src/mixins/view-module.js
index ae81da9b..b7b8b33e 100644
--- a/back/src/mixins/view-module.js
+++ b/back/src/mixins/view-module.js
@@ -109,6 +109,11 @@ export default {
}
console.log('数据列表', this.dataList, this.mixinViewModuleOptions.getDataListURL)
+ if (this.dataList[0].type === '组件服务') {
+ this.dataList.map(val => {
+ val.infoList = val.infoList.filter(item => item.attrType === '部署位置' || item.attrType === '组件类型' || item.attrType === '应用领域')
+ })
+ }
if (this.mixinViewModuleOptions.requestCallback) {
this.mixinViewModuleOptions.requestCallback(res.data)
}
diff --git a/back/src/views/modules/ability/bsabilityai.vue b/back/src/views/modules/ability/bsabilityai.vue
index 930685e1..c7a467c4 100644
--- a/back/src/views/modules/ability/bsabilityai.vue
+++ b/back/src/views/modules/ability/bsabilityai.vue
@@ -69,6 +69,14 @@
header-align="center"
align="center"
>
+
import { ref, reactive, defineProps } from 'vue'
import mybus from '@/myplugins/mybus'
- import { updateVisits } from '@/api/home'
+ import { updateVisits, browsingInsert } from '@/api/home'
const props = defineProps({
resourceList: { type: Array, default: null },
resourceTotal: { type: String, default: '' },
@@ -66,6 +66,9 @@
const openHref = (item) => {
console.log(item.id, 'wowowo')
console.log(item.visits, 'wowowo')
+ browsingInsert({ resourceId: item.id }).then((res) => {
+ // console.log(res)
+ })
const arrList = ref([])
arrList.value = JSON.parse(window.sessionStorage.getItem('visits'))
if (arrList.value.indexOf(item.id) === -1) {
diff --git a/front/src/views/personalCenter/components/MyBrowse.vue b/front/src/views/personalCenter/components/MyBrowse.vue
index 7cc980a6..eedeeb9b 100644
--- a/front/src/views/personalCenter/components/MyBrowse.vue
+++ b/front/src/views/personalCenter/components/MyBrowse.vue
@@ -44,7 +44,9 @@
>
@@ -142,6 +144,7 @@
import { onMounted, ref } from 'vue'
import { useRouter } from 'vue-router'
import { message } from 'ant-design-vue'
+ import { updateVisits, browsingInsert } from '@/api/home'
import mybus from '@/myplugins/mybus'
import { getBsList, BsDel, getTopCategory } from '@/api/personalCenter'
const router = useRouter()
@@ -171,7 +174,11 @@
console.log('编目一级=============>', res.data)
res.data.data.forEach((val) => {
// tabList.value.push(val.name)
- if (val.name == '应用资源' || val.name == '组件服务') {
+ if (
+ val.name == '应用资源' ||
+ val.name == '组件服务' ||
+ val.name == '知识库'
+ ) {
tabList.value.push(val.name)
}
})
@@ -234,7 +241,9 @@
name: val.resourceDTO.name,
id: val.id,
checked: false,
+ visits: val.resourceDTO.visits,
type: val.resourceDTO.type,
+ link: val.resourceDTO.link,
resourceId: val.resourceId,
createDate: val.createDate,
description: val.resourceDTO.description,
@@ -267,6 +276,28 @@
console.log('search======================>', name.value)
}
+ const openHref = (item) => {
+ browsingInsert({ resourceId: item.resourceId }).then((res) => {
+ // console.log(res)
+ })
+ const arrList = ref([])
+ arrList.value = JSON.parse(window.sessionStorage.getItem('visits'))
+ if (arrList.value.indexOf(item.resourceId) === -1) {
+ arrList.value.push(item.resourceId)
+ updateVisits({
+ id: item.resourceId,
+ visits: item.visits || '0',
+ }).then(() => {
+ window.sessionStorage.setItem('visits', JSON.stringify(arrList.value))
+ })
+ }
+ window.open(item.link)
+ // window.open(
+ // window.SITE_CONFIG.previewUrl +
+ // 'hisense_office/onlinePreview?url=' +
+ // btoa(encodeURI(item.fileHref))
+ // )
+ }
//申请id
const dataResourceId = ref([])
@@ -334,16 +365,20 @@
console.log(e)
}
// 详情
- const showItem = (id, type, delFlag) => {
+ const showItem = (id, type, delFlag, item) => {
if (delFlag == 0) {
- console.log('进入详情')
- mybus.emit('tabsChange', { flag: id })
- router.push({
- path: '/details',
- query: {
- id: id,
- },
- })
+ console.log('进入详情', item)
+ if (item.type === '知识库') {
+ openHref(item)
+ } else {
+ mybus.emit('tabsChange', { flag: id })
+ router.push({
+ path: '/details',
+ query: {
+ id: id,
+ },
+ })
+ }
}
}