提交 5201cafd authored 作者: coderBryanFu's avatar coderBryanFu

update

上级 95101793
import request from "@/api/request.js";
// 图表解读(流式)
/**
* @param {text}
*/
export function getChartAnalysis(data) {
return request({
method: 'POST',
url: `/aiAnalysis/chart_interpretation`,
data,
})
}
\ No newline at end of file
......@@ -2,7 +2,6 @@
import ZMGame from "@/views/ZMGame/index.vue";
const ZMGameRoutes = [
//创新主体
{
path: "/ZMGame",
name: "ZMGame",
......
......@@ -2,10 +2,9 @@
import ZMOverview from "@/views/ZMOverView/index.vue";
const ZMOverviewRoutes = [
//创新主体
{
path: "/ZMOerView",
name: "ZMOerView",
path: "/ZMOverView",
name: "ZMOverView",
component: ZMOverview,
meta: {
title: "ZM博弈概览"
......
......@@ -299,9 +299,10 @@
{{ news.newsDate ? news.newsDate.slice(5) : "" }} - {{ news.newsOrg }}
</div>
</div>
<CommonPrompt :content="news.newsContent">
<div class="right-footer">{{ news.newsContent }}</div>
</CommonPrompt>
<!-- <CommonPrompt :content="news.newsContent">
<div class="right-footer">{{ news.newsContent }}</div>
</CommonPrompt> -->
</div>
</div>
</div>
......@@ -597,7 +598,7 @@
<el-checkbox class="filter-checkbox" label="全部领域"> 全部领域 </el-checkbox>
<el-checkbox
v-for="(area, index) in cateKuList"
:key="area.id"
:key="index"
:label="area.id"
class="filter-checkbox"
>
......@@ -615,7 +616,7 @@
<el-checkbox-group class="checkbox-group" v-model="activeDpList" @change="handleDpChange">
<el-checkbox
v-for="(dp, index) in dpList"
:key="dp.id"
:key="index"
:label="dp.id"
class="filter-checkbox"
>
......@@ -633,7 +634,7 @@
<el-checkbox-group class="checkbox-group" v-model="activeYyList" @change="handleYyChange">
<el-checkbox
v-for="(yy, index) in yyList"
:key="yy.id"
:key="index"
:label="yy.id"
class="filter-checkbox"
>
......@@ -652,7 +653,7 @@
<el-checkbox-group class="checkbox-group" v-model="activePubTime" @change="handlePubTimeChange">
<el-checkbox
v-for="(time, index) in pubTime"
:key="time.id"
:key="index"
:label="time.id"
class="filter-checkbox"
>
......@@ -2936,7 +2937,7 @@ onUnmounted(() => {
justify-content: flex-end;
}
.box7-main {
height: 380px;
height: 390px;
}
}
.box8 {
......
......@@ -6,7 +6,7 @@ const getDoublePieChart = (data1, data2) => {
series: [
{
type: 'pie',
radius: [45, 88],
radius: [35, 78],
// height: '100%',
left: 'center',
// width: '100%',
......@@ -32,7 +32,7 @@ const getDoublePieChart = (data1, data2) => {
},
{
type: 'pie',
radius: [90, 120],
radius: [80, 110],
height: '100%',
left: 'center',
width: '98%',
......@@ -45,18 +45,20 @@ const getDoublePieChart = (data1, data2) => {
formatter: '{name|{b}}\n{time|{c} 条 {d}%}',
minMargin: 5,
edgeDistance: 10,
lineHeight: 24,
lineHeight: 20,
rich: {
name: {
color: 'rgba(59, 65, 75, 1)',
fontFamily: 'Microsoft YaHei',
fontSize: 16,
fontSize: 14,
fontWeight: 'bold',
padding: [10,0,10,0]
},
time: {
fontSize: 16,
fontSize: 14,
fontFamily: 'Microsoft YaHei',
color: '#rgba(95, 101, 108, 1)'
color: '#rgba(95, 101, 108, 1)',
padding: [10,0,10,0]
}
}
},
......
......@@ -17,18 +17,20 @@ const getPieChart = (data, colorList) => {
formatter: '{name|{b}}\n{time|{c} 条 {d}%}',
minMargin: 5,
edgeDistance: 10,
lineHeight: 25,
lineHeight: 22,
rich: {
name: {
color: 'rgba(59, 65, 75, 1)',
fontFamily: 'Microsoft YaHei',
fontSize: 16,
fontWeight: 'bold',
padding: [10, 0, 10, 0]
},
time: {
fontSize: 16,
fontFamily: 'Microsoft YaHei',
color: '#rgba(95, 101, 108, 1)'
color: '#rgba(95, 101, 108, 1)',
padding: [10, 0, 10, 0]
}
}
......@@ -36,10 +38,10 @@ const getPieChart = (data, colorList) => {
labelLine: {
length: 15,
length2: 0,
maxSurfaceAngle: 80
maxSurfaceAngle: 88
},
labelLayout: function (params) {
const isLeft = params.labelRect.x < params.viewWidth / 2;
const isLeft = params.labelRect.x < 556 / 2;
const points = params.labelLinePoints;
// Update the end point.
points[2][0] = isLeft
......
......@@ -16,7 +16,7 @@ const getPieChart = (data) => {
formatter: '{name|{b}}\n{time|{d}%}',
minMargin: 5,
edgeDistance: 10,
lineHeight: 24,
lineHeight: 22,
rich: {
name: {
color: 'rgba(59, 65, 75, 1)',
......@@ -27,7 +27,7 @@ const getPieChart = (data) => {
time: {
fontSize: 16,
fontFamily: 'Microsoft YaHei',
color: '#rgba(95, 101, 108, 1)'
color: '#rgba(95, 101, 108, 1)',
}
}
},
......
......@@ -78,7 +78,7 @@
</template>
<script setup>
import { ref, defineProps, defineEmits, computed, watch } from "vue";
import { ref, computed, watch } from "vue";
import router from "@/router";
import { Close } from "@element-plus/icons-vue";
import defaultIcon from "@/assets/icons/default-icon1.png";
......
......@@ -620,13 +620,13 @@
<div class="item-right-header">
<div class="tag" :class="{tag1: item.SORTCODE === '337', tag2: item.SORTCODE === '301', tag3: item.SORTCODE === '232' }">{{ item.SORTCODE }}</div>
<div class="title">{{ item.SEARCHNAME }}</div>
<div class="status">
<div class="status" v-if="item.CASESTATUS">
<div class="status-icon"></div>
<div class="status-text">{{ item.CASESTATUS }}</div>
</div>
</div>
<div class="item-right-content">
{{ item.content }}
<div class="item-right-content" v-if="item.CONTENT">
{{ item.CONTENT }}
</div>
<div class="item-right-footer">
<div class="area-box" v-for="(val, idx) in item.searchArea" :key="idx">
......@@ -1600,9 +1600,6 @@ const handleGetSurveyList = async () => {
if (res.code === 200 && res.data) {
totalDiscussNum.value = res.data.totalElements;
surveyInfoList.value = res.data.content;
surveyInfoList.value.forEach(item => {
item.SORTIMAGEURL = `http://${item.SORTIMAGEURL}`
})
} else {
surveyInfoList.value = [];
}
......@@ -3179,7 +3176,8 @@ onMounted(async () => {
border-bottom: 1px solid rgba(230, 231, 232, 1);
// height: 780px;
.item {
height: 154px;
// height: 154px;
min-height: 94px;
display: flex;
cursor: pointer;
&:hover {
......@@ -3199,17 +3197,21 @@ onMounted(async () => {
}
.item-center {
width: 30px;
height: 154px;
// height: 154px;
.icon {
width: 30px;
height: 30px;
border-radius: 15px;
background: orange;
img{
width: 100%;
height: 100%;
}
}
.line {
margin-left: 14px;
width: 2px;
height: 124px;
min-height: 64px;
max-height: 124px;
border-radius: 1.5px;
background: rgba(234, 236, 238, 1);
}
......@@ -3261,13 +3263,17 @@ onMounted(async () => {
line-height: 26px;
letter-spacing: 0px;
text-align: left;
overflow: hidden;
text-overflow: ellipsis;
white-space: nowrap;
}
.status {
margin-left: 9px;
display: flex;
width: 76px;
height: 24px;
justify-content: space-between;
justify-content: flex-end;
gap: 5px;
align-items: center;
.status-icon {
width: 4px;
......@@ -3323,16 +3329,23 @@ onMounted(async () => {
}
.flag-box {
display: flex;
position: relative;
.flag {
width: 24px;
height: 24px;
border-radius: 12px;
border: 2px solid #fff;
overflow: hidden;
position: absolute;
img{
width: 100%;
height: 100%;
}
}
:nth-child(1) {
left: 18px;
z-index: 99;
}
}
}
}
......
......@@ -54,24 +54,19 @@ const getBarChart = (nameList, valueList) => {
},
barWidth: 20,
markPoint: {
symbol: 'circle',
symbolSize: 0,
// symbol: 'circle',
// symbolSize: 0,
data: (function () {
const data = [];
nameList.forEach((item, index) => {
data.push({
name: 'icon',
// value: '',
xAxis: index,
yAxis: valueList[index],
symbol: `image://${item.img}`,
symbolSize: [20, 20],
symbolOffset: [0, 10],
// itemStyle: {
// borderRadius: 10, // 设置为圆形
// borderColor: '#fff',
// borderWidth: 2
// }
symbolCircle: 10
});
});
return data;
......
......@@ -2,24 +2,31 @@
<template>
<div class="source-library-container">
<div class="source-library-grid">
<div v-for="(item, index) in PersonResource" :key="index" class="source-library-card" @click="handleClcikToCharacter(item.id)">
<div
v-for="(item, index) in PersonResource"
:key="index"
class="source-library-card"
@click="handleClcikToCharacter(item.id)"
>
<div class="source-library-avatar-wrapper">
<img :src="item.avatar" alt="" class="source-library-avatar" />
</div>
<div class="source-library-text-content">
<div style="width: 240px;height: 120px;display: flex; flex-direction: column;">
<div style="width: 240px; height: 120px; display: flex; flex-direction: column">
<h3 class="source-library-name">{{ item.name }}</h3>
<p class="source-library-title">{{ item.title }}</p>
<div class="taglist">
<p
class="source-library-tag"
v-for="value in item.tag"
:class="{tag1: value.typeId === '001',
v-for="(value, index) in item.tag"
:key="index"
:class="{
tag1: value.typeId === '001',
tag2: value.typeId === '002',
tag3: value.typeId === '003',
tag4: value.typeId === '004',
tag5: value.typeId === '005',
tag6: value.typeId === '006',
tag6: value.typeId === '006'
}"
>
{{ value.typeName }}
......@@ -30,7 +37,7 @@
</div>
</div>
<div class="page">
<div class="count">{{ `共 ${total} 项`}}</div>
<div class="count">{{ `共 ${total} 项` }}</div>
<el-pagination
@current-change="handleCurrentChange"
:page-size="pageSize"
......@@ -46,12 +53,12 @@
<script setup>
// 导入数据(建议使用更具语义的变量名)
import sourceLibraryData from "../json/source.json";
import { ref,onMounted,defineProps,watch } from "vue";
import { ref, onMounted, watch } from "vue";
import { useRouter } from "vue-router";
import DefaultIcon1 from '@/assets/icons/default-icon1.png'
import DefaultIcon2 from '@/assets/icons/default-icon2.png'
import DefaultIcon1 from "@/assets/icons/default-icon1.png";
import DefaultIcon2 from "@/assets/icons/default-icon2.png";
import {getPersonResource,getPersonSummaryInfo } from "@/api/technologyFigures/technologyFigures";
import { getPersonResource, getPersonSummaryInfo } from "@/api/technologyFigures/technologyFigures";
const props = defineProps({
typeId: {
......@@ -60,11 +67,12 @@ const props = defineProps({
}
});
watch(() => props.typeId, (val) => {
watch(
() => props.typeId,
val => {
handlegetPersonResourceFn();
})
}
);
const router = useRouter();
......@@ -88,11 +96,11 @@ const handlegetPersonResourceFn = async () => {
currentPage: currentPage.value - 1, // Standard Spring Boot page index is 0-based
pageSize: pageSize.value
};
if(props.typeId !== '000'){
if (props.typeId !== "000") {
params.personTypeId = props.typeId;
}
try {
const res = await getPersonResource(params,abortController.value.signal);
const res = await getPersonResource(params, abortController.value.signal);
console.log("人物资源库", res);
if (res.code === 200) {
if (res.data && res.data.content) {
......@@ -104,7 +112,6 @@ const handlegetPersonResourceFn = async () => {
avatar: item.personImage || DefaultIcon1
}));
total.value = res.data.totalElements;
} else {
PersonResource.value = [];
total.value = 0;
......@@ -129,7 +136,7 @@ const handleCurrentChange = page => {
};
// 跳转人物主页
const handleClcikToCharacter = async (id) => {
const handleClcikToCharacter = async id => {
const personTypeList = JSON.parse(window.sessionStorage.getItem("personTypeList"));
let type = 0;
......@@ -186,10 +193,6 @@ onMounted(async () => {
handlegetPersonResourceFn();
});
const handlePageChange = p => {
currentPage.value = p;
};
......@@ -219,7 +222,6 @@ const handlePageChange = p => {
box-shadow: 0px 0px 20px 0px rgba(25, 69, 130, 0.1);
background: rgba(255, 255, 255, 1);
cursor: pointer;
}
.source-library-card:hover {
......@@ -263,7 +265,6 @@ const handlePageChange = p => {
.source-library-text-content {
width: 656px;
flex: 1;
}
.source-library-name {
......@@ -290,7 +291,7 @@ const handlePageChange = p => {
text-align: left;
}
.taglist{
.taglist {
display: flex;
gap: 10px;
margin-top: auto;
......
......@@ -129,6 +129,7 @@ import {
getThinkTankReportIndustry,
getThinkTankReportIndustryCloud
} from "@/api/thinkTank/overview";
import {getChartAnalysis} from '@/api/aiAnalysis/index'
import { useRouter } from "vue-router";
const router = useRouter();
......@@ -256,118 +257,6 @@ const majorOpinions = ref([
status: 2
}
]
},
{
id: 3,
title: "我是示例标题",
desc: "我是示例内容",
tagList: [
{
name: "半导体",
status: 4
}
]
},
{
id: 4,
title: "我是示例标题",
desc: "我是示例内容",
tagList: [
{
name: "关税",
status: 2
},
{
name: "跨境电商",
status: 1
}
]
},
{
id: 5,
title: "我是示例标题",
desc: "我是示例内容",
tagList: [
{
name: "关税",
status: 2
},
{
name: "跨境电商",
status: 1
}
]
},
{
id: 6,
title: "我是示例标题",
desc: "我是示例内容",
tagList: [
{
name: "关税",
status: 2
},
{
name: "跨境电商",
status: 1
}
]
},
{
id: 7,
title: "我是示例标题",
desc: "我是示例内容",
tagList: [
{
name: "产业脱钩",
status: 6
}
]
},
{
id: 8,
title: "我是示例标题",
desc: "我是示例内容",
tagList: [
{
name: "关税",
status: 2
},
{
name: "跨境电商",
status: 1
}
]
},
{
id: 9,
title: "我是示例标题",
desc: "我是示例内容",
tagList: [
{
name: "关税",
status: 2
},
{
name: "跨境电商",
status: 1
}
]
},
{
id: 10,
title: "我是示例标题",
desc: "我是示例内容",
tagList: [
{
name: "关税",
status: 2
},
{
name: "跨境电商",
status: 1
}
]
}
]);
// 处理页码改变事件
......@@ -384,12 +273,25 @@ const handleGetThinkTankReportContent = async () => {
console.log("主要观点", res.data);
if (res.code === 200 && res.data) {
majorOpinions.value = res.data.content;
handleGetBox3AnalysisContent(majorOpinions.value)
total.value = res.data.totalElements
}
} catch (error) {
console.error("获取主要观点error", error);
}
};
// 获取图表分析内容
const box3AnalysisContent = ref('')
const handleGetBox3AnalysisContent = async (textJson) => {
const params = {
text: textJson
}
const res = await getChartAnalysis(params)
console.log('图表解析内容', res);
}
onMounted(() => {
handleGetThinkTankReportAbstract();
handleGetThinkTankReportContent();
......
......@@ -75,6 +75,11 @@ export default defineConfig({
target: 'http://106.12.150.59:18826/',
changeOrigin: true,
rewrite: (path) => path.replace(/^\/temporarySearch/, '')
},
'/aiAnalysis': {
target: 'http://8.140.26.4:15000/',
changeOrigin: true,
rewrite: (path) => path.replace(/^\/temporarySearch/, '')
}
}
}
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论