提交 29448e2d authored 作者: 胡卉清's avatar 胡卉清

合并分支 'dev_hhq' 到 'master'

Dev hhq 查看合并请求 !60
// 企业主页接口信息
import request from "@/api/request.js";
// 企业基本信息:基本信息
export function getEnterprisePageInfo(params) {
return request({
method: 'GET',
url: `/api/enterprisePage/info/${params}`,
})
}
// 企业基本信息:主要人员
export function getEnterpriseKeyPerson(params) {
return request({
method: 'GET',
url: `/api/enterprisePage/keyPerson/${params}`,
})
}
//企业基本信息:分支机构
export function getEnterpriseBranch(params) {
return request({
method: 'GET',
url: `/api/enterprisePage/branch/${params}`,
})
}
//企业基本信息:最新动态
export function getEnterpriseNewDynamic(params) {
return request({
method: 'GET',
url: `/api/enterprisePage/newDynamic/${params}`,
})
}
//企业研发投入:年度研发投入对比
export function getEnterpriseStudy(params) {
return request({
method: 'GET',
url: `/api/enterprisePage/study/${params}`,
})
}
//企业研发投入:年度研发增长对比
export function getEnterpriseGrowth(params) {
return request({
method: 'GET',
url: `/api/enterprisePage/growth/${params}`,
})
}
//企业研究人员:人员数量
export function getEnterpriseResearcherNum(params) {
return request({
method: 'GET',
url: `/api/enterprisePage/researcherNum/${params}`,
})
}
//企业研究人员:人员学历
export function getEnterpriseResearcherDegree(params) {
return request({
method: 'GET',
url: `/api/enterprisePage/researcherDegree/${params}`,
})
}
//企业专利:地域分布
export function getEnterprisePatentRegion(params) {
return request({
method: 'GET',
url: `/api/enterprisePage/patentRegion/${params}`,
})
}
//企业专利:领域分布
export function getEnterprisPatentField(params) {
return request({
method: 'GET',
url: `/api/enterprisePage/patentField/${params}`,
})
}
...@@ -4,7 +4,7 @@ import companyPages from "@/views/companyPages/index.vue"; ...@@ -4,7 +4,7 @@ import companyPages from "@/views/companyPages/index.vue";
const companyPagesRoutes = [ const companyPagesRoutes = [
// 智库系统的主要路由 // 智库系统的主要路由
{ {
path: "/companyPages", path: "/companyPages/:id",
name: "companyPages", name: "companyPages",
component: companyPages, component: companyPages,
meta: { meta: {
......
...@@ -15,11 +15,11 @@ ...@@ -15,11 +15,11 @@
<div class="node" :style="leftOffset(i)"> <div class="node" :style="leftOffset(i)">
<!-- 圆环 --> <!-- 圆环 -->
<div class="dot" :class="linePos(i, flip)" :style="{ <div class="dot" :class="linePos(i, flip)" :style="{
marginTop: linePos(i, flip) === 'down' ? '35px' : '-10px' marginTop: linePos(i, flip) === 'down' ? '-5px' : '35px'
}"></div> }"></div>
<div class="time" :style="{ <div class="time" :style="{
marginTop: linePos(i, flip) === 'down' ? '10px' : '-40px' marginTop: linePos(i, flip) === 'down' ? '-50px' : '10px'
}" v-if="type === 'normal'"> }" v-if="type === 'normal'">
{{ item.time }} {{ item.time }}
</div> </div>
...@@ -37,9 +37,12 @@ ...@@ -37,9 +37,12 @@
{{ item.title }} {{ item.title }}
<!-- <img class="item-header-icon" src="@/assets/images/icon/copy.png" style="cursor: pointer;"></img> --> <!-- <img class="item-header-icon" src="@/assets/images/icon/copy.png" style="cursor: pointer;"></img> -->
</div> </div>
<div class="content"> <el-tooltip class="box-item" effect="dark" :content="item.content" placement="top">
{{ item.content }} <div class="content">
</div> {{ item.content }}
</div>
</el-tooltip>
</div> </div>
</div> </div>
</div> </div>
...@@ -86,7 +89,7 @@ export default { ...@@ -86,7 +89,7 @@ export default {
}, },
methods: { methods: {
leftOffset(i) { leftOffset(i) {
return this.type === 'normal' ? { left: `${(i * 100) / 5}%`, top: '50%' } : { left: `${(i * 100) / 5}%`, top: '100%' } return this.type === 'normal' ? { left: `${(i * 100) / 4}%`, top: '50%' } : { left: `${(i * 100) / 4}%`, top: '100%' }
}, },
...@@ -105,6 +108,7 @@ export default { ...@@ -105,6 +108,7 @@ export default {
<style scoped> <style scoped>
/* 样式与之前完全一致,不再重复 */ /* 样式与之前完全一致,不再重复 */
.timeline-wrapper { .timeline-wrapper {
font-family: Microsoft YaHei;
display: flex; display: flex;
align-items: center; align-items: center;
width: 100%; width: 100%;
...@@ -252,13 +256,46 @@ export default { ...@@ -252,13 +256,46 @@ export default {
line-height: 24px; line-height: 24px;
letter-spacing: 0px; letter-spacing: 0px;
text-align: justify; text-align: justify;
text-overflow: ellipsis;
display: -webkit-box;
-webkit-line-clamp: 4;
overflow: hidden;
-webkit-box-orient: vertical;
} }
.card.up { .card.up {
bottom: 50px; bottom: 80px;
margin-bottom: 20px;
margin-left: 160px;
} }
.card.down { .card.down {
top: 20px; top: -50px;
margin-top: 95px;
margin-left: 160px;
}
.box-item {
color: rgba(255, 255, 255, 1);
font-family: Microsoft YaHei;
font-style: Regular;
font-size: 16px;
font-weight: 400;
line-height: 30px;
letter-spacing: 0px;
text-align: left;
}
:deep(.el-popper.is-dark) {
color: rgba(255, 255, 255, 1);
font-family: Microsoft YaHei !important;
font-style: Regular;
font-size: 16px;
font-weight: 400;
line-height: 30px;
letter-spacing: 0px;
text-align: left;
} }
</style> </style>
\ No newline at end of file
import * as echarts from "echarts"; import * as echarts from "echarts";
const getBarChart = (nameList, valueList, isPer) => { /**
const option = { * 生成雷达图配置项(单系列)
title: { text: '' }, * @param {{name: string[], value: number[]}} data - 包含 name 和 value 的对象
* @param {string} seriesName - 系列名称(如“学历分布”),可选,默认为 ''
* @returns {Object} ECharts 配置项
*/
const getRadarChart = (data, seriesName = '') => {
const nameList = data.name
const valueList = data.value
console.log(nameList, valueList, 'datadatadatadata')
// 自动计算每个维度的 max:取 value 中的最大值 * 1.2 并向上取整到合适刻度
const maxValue = Math.max(...valueList);
// 简单处理:如果 maxValue <= 10,max 设为 10;否则按 1.2 倍并取整到百/十位
let max;
if (maxValue === 0) {
max = 10;
} else if (maxValue <= 10) {
max = 10;
} else if (maxValue <= 100) {
max = Math.ceil(maxValue * 1.2 / 10) * 10;
} else {
max = Math.ceil(maxValue * 1.2 / 100) * 100;
}
// 所有 indicator 使用相同的 max(也可每个维度单独设,但你没提供)
const indicators = nameList.map(name => ({ name, max }));
const option = {
title: { text: '' },
radar: { radar: {
radius: '50%', // 关键:缩小整个雷达 radius: '50%',
center: ['50%', '50%'], // 可选:再往下挪一点,避免图例挤在一起 center: ['50%', '50%'],
indicator: [ indicator: indicators,
{ name: '5G通信', max: 6500 },
{ name: '生物科技', max: 16000 },
{ name: '人工智能', max: 30000 },
{ name: '物联网', max: 38000 },
{ name: '量子科技', max: 52000 },
{ name: '智能汽车', max: 25000 }
],
axisName: { axisName: {
formatter: '{value}', formatter: '{value}',
color: 'rgba(59, 65, 75, 1)', color: 'rgba(59, 65, 75, 1)',
...@@ -25,26 +43,25 @@ const getBarChart = (nameList, valueList, isPer) => { ...@@ -25,26 +43,25 @@ const getBarChart = (nameList, valueList, isPer) => {
}, },
series: [ series: [
{ {
name: 'Budget vs spending', name: seriesName,
type: 'radar', type: 'radar',
symbol: 'none', symbol: 'none',
// 添加或修改 lineStyle 属性来控制线条粗细
lineStyle: { lineStyle: {
width: 1, // 调整这个值可以改变线条的粗细,数值越大线条越粗 width: 1,
color: '#69B1FF' color: '#69B1FF'
}, },
data: [ data: [
{ {
value: [4200, 3000, 20000, 35000, 50000, 18000], value: valueList,
name: '美国', name: seriesName,
areaStyle: { color: 'rgba(105, 177, 255, 0.1)' } areaStyle: { color: 'rgba(105, 177, 255, 0.1)' }
}, }
] ]
} }
] ]
} };
return option
} return option;
};
export default getBarChart export default getRadarChart;
\ No newline at end of file \ No newline at end of file
...@@ -4,7 +4,7 @@ ...@@ -4,7 +4,7 @@
<div class="box1"> <div class="box1">
<div class="box-header"> <div class="box-header">
<div class="header-left"></div> <div class="header-left"></div>
<div class="title">政策建议落实情况</div> <div class="title">政策建议相关情况</div>
<div class="header-right"> <div class="header-right">
<div class="icon"> <div class="icon">
<img src="@/assets/icons/box-header-icon2.png" alt="" /> <img src="@/assets/icons/box-header-icon2.png" alt="" />
...@@ -108,7 +108,7 @@ import { ...@@ -108,7 +108,7 @@ import {
} from "@/api/thinkTank/overview"; } from "@/api/thinkTank/overview";
import { useRouter } from "vue-router"; import { useRouter } from "vue-router";
const router = useRouter(); const router = useRouter();
// 政策建议落实情况 // 政策建议相关情况
const box1Data = ref([ const box1Data = ref([
{ {
id: 1, id: 1,
...@@ -265,12 +265,12 @@ const box1Data = ref([ ...@@ -265,12 +265,12 @@ const box1Data = ref([
const handleGetThinkTankReportPolicy = async () => { const handleGetThinkTankReportPolicy = async () => {
try { try {
const res = await getThinkTankReportPolicy(router.currentRoute._value.params.id); const res = await getThinkTankReportPolicy(router.currentRoute._value.params.id);
console.log("政策建议落实情况", res); console.log("政策建议相关情况", res);
if (res.code === 200 && res.data) { if (res.code === 200 && res.data) {
box1Data.value = res.data box1Data.value = res.data
} }
} catch (error) { } catch (error) {
console.error("获取政策建议落实情况rror", error); console.error("获取政策建议相关情况rror", error);
} }
}; };
......
...@@ -17,12 +17,12 @@ ...@@ -17,12 +17,12 @@
<div class="box1-main"> <div class="box1-main">
{{ box1Data }} {{ box1Data }}
</div> </div>
<div class="box1-footer"> <!-- <div class="box1-footer">
<div class="text">{{ "查看更多" }}</div> <div class="text">{{ "查看更多" }}</div>
<div class="icon"> <div class="icon">
<img src="@/assets/images/icon-double-down.png" alt="" /> <img src="@/assets/images/icon-double-down.png" alt="" />
</div> </div>
</div> </div> -->
</div> </div>
<div class="box2"> <div class="box2">
<div class="box-header"> <div class="box-header">
...@@ -53,14 +53,14 @@ ...@@ -53,14 +53,14 @@
<div class="box-header"> <div class="box-header">
<div class="header-left"></div> <div class="header-left"></div>
<div class="title">主要观点</div> <div class="title">主要观点</div>
<div class="header-btn-box"> <!-- <div class="header-btn-box">
<div class="btn btnActive"> <div class="btn btnActive">
{{ "核心发现" }} {{ "核心发现" }}
</div> </div>
<div class="btn"> <div class="btn">
{{ "政策建议" }} {{ "政策建议" }}
</div> </div>
</div> </div> -->
<div class="header-right"> <div class="header-right">
<div class="icon"> <div class="icon">
<img src="@/assets/icons/box-header-icon2.png" alt="" /> <img src="@/assets/icons/box-header-icon2.png" alt="" />
...@@ -78,7 +78,7 @@ ...@@ -78,7 +78,7 @@
</div> </div>
<div class="center"> <div class="center">
<div class="title">{{ item.content }}</div> <div class="title">{{ item.content }}</div>
<div class="desc">{{ item.econtent }}</div> <!-- <div class="desc">{{ item.econtent }}</div> -->
</div> </div>
<div class="right"> <div class="right">
<div class="tag" v-for="(val, idx) in item.hylyList" :key="idx"> <div class="tag" v-for="(val, idx) in item.hylyList" :key="idx">
...@@ -489,7 +489,7 @@ onMounted(() => { ...@@ -489,7 +489,7 @@ onMounted(() => {
.box1-main { .box1-main {
margin: 5px auto; margin: 5px auto;
width: 428px; width: 428px;
height: 282px; height: 315px;
/* 9行 * 30px/行 = 270px,这里可以稍微调整 */ /* 9行 * 30px/行 = 270px,这里可以稍微调整 */
color: rgba(59, 65, 75, 1); color: rgba(59, 65, 75, 1);
font-family: Microsoft YaHei; font-family: Microsoft YaHei;
......
...@@ -7,7 +7,7 @@ ...@@ -7,7 +7,7 @@
<img src="./images/box-header-icon1.png" alt="" /> <img src="./images/box-header-icon1.png" alt="" />
</div> </div>
<div class="title">{{ "提出建议领域分布" }}</div> <div class="title">{{ "提出建议领域分布" }}</div>
<div class="box-header-right">{{ "查看数据源 >" }}</div> <!-- <div class="box-header-right">{{ "查看数据源 >" }}</div> -->
</div> </div>
<div class="box-main"> <div class="box-main">
<div class="select-box"> <div class="select-box">
...@@ -19,7 +19,7 @@ ...@@ -19,7 +19,7 @@
<div id="box1Chart"></div> <div id="box1Chart"></div>
</div> </div>
</div> </div>
<div class="box2 box"> <!-- <div class="box2 box">
<div class="box-header"> <div class="box-header">
<div class="icon"> <div class="icon">
<img src="./images/box-header-icon2.png" alt="" /> <img src="./images/box-header-icon2.png" alt="" />
...@@ -42,20 +42,17 @@ ...@@ -42,20 +42,17 @@
:percentage="item.percent" /> :percentage="item.percent" />
<div class="num">{{ item.amount + "项" }} / {{ item.totalAmount + "项" }}</div> <div class="num">{{ item.amount + "项" }} / {{ item.totalAmount + "项" }}</div>
<div class="per">{{ item.percent + "%" }}</div> <div class="per">{{ item.percent + "%" }}</div>
</div> </div>
<!-- <div class="box2-item">
<el-progress :percentage="50" />
</div> -->
</div> </div>
</div> </div>
</div> </div> -->
<div class="box3 box"> <div class="box3 box">
<div class="box-header"> <div class="box-header">
<div class="icon"> <div class="icon">
<img src="./images/box-header-icon2.png" alt="" /> <img src="./images/box-header-icon2.png" alt="" />
</div> </div>
<div class="title">{{ "热门研究方向变化趋势" }}</div> <div class="title">{{ "热门研究方向变化趋势" }}</div>
<div class="box-header-right">{{ "查看数据源 >" }}</div> <!-- <div class="box-header-right">{{ "查看数据源 >" }}</div> -->
</div> </div>
<div class="box-main"> <div class="box-main">
<div class="select-box"> <div class="select-box">
...@@ -141,7 +138,7 @@ ...@@ -141,7 +138,7 @@
</div> </div>
</div> </div>
<div class="right-footer"> <div class="right-footer">
<div class="info">{{ total }}项调查</div> <div class="info">{{ total }}智库报告</div>
<div class="page-box"> <div class="page-box">
<el-pagination :page-size="12" background layout="prev, pager, next" :total="total" <el-pagination :page-size="12" background layout="prev, pager, next" :total="total"
@current-change="handleCurrentChange" :current-page="currentPage" /> @current-change="handleCurrentChange" :current-page="currentPage" />
...@@ -577,7 +574,7 @@ onMounted(() => { ...@@ -577,7 +574,7 @@ onMounted(() => {
gap: 16px; gap: 16px;
.box { .box {
width: 520px; width: 790px;
height: 420px; height: 420px;
box-sizing: border-box; box-sizing: border-box;
border: 1px solid rgba(234, 236, 238, 1); border: 1px solid rgba(234, 236, 238, 1);
...@@ -586,7 +583,7 @@ onMounted(() => { ...@@ -586,7 +583,7 @@ onMounted(() => {
background: rgba(255, 255, 255, 1); background: rgba(255, 255, 255, 1);
.box-header { .box-header {
width: 520px; width: 790px;
height: 48px; height: 48px;
border-bottom: 1px solid rgba(234, 236, 238, 1); border-bottom: 1px solid rgba(234, 236, 238, 1);
display: flex; display: flex;
......
...@@ -23,7 +23,7 @@ ...@@ -23,7 +23,7 @@
</div> </div>
<div class="main-content"> <div class="main-content">
<div class="left"> <div class="left">
<div class="select-box"> <!-- <div class="select-box">
<div class="select-box-header"> <div class="select-box-header">
<div class="icon"></div> <div class="icon"></div>
<div class="title">{{ "报告类型" }}</div> <div class="title">{{ "报告类型" }}</div>
...@@ -36,7 +36,7 @@ ...@@ -36,7 +36,7 @@
</el-checkbox> </el-checkbox>
</div> </div>
</div> </div>
</div> </div> -->
<div class="select-box"> <div class="select-box">
<div class="select-box-header"> <div class="select-box-header">
<div class="icon"></div> <div class="icon"></div>
...@@ -331,7 +331,7 @@ const handleGetThinkDynamicsReport = async () => { ...@@ -331,7 +331,7 @@ const handleGetThinkDynamicsReport = async () => {
authorName: author.value ? author.value : null, authorName: author.value ? author.value : null,
currentPage: currentPage.value - 1, currentPage: currentPage.value - 1,
pageSize: 12, pageSize: 12,
reportTypeIds: arrayToString(selectedReportTypeList.value) === '' ? null : arrayToString(selectedResearchTypeList.value), // reportTypeIds: arrayToString(selectedReportTypeList.value) === '' ? null : arrayToString(selectedResearchTypeList.value),
researchTypeIds: arrayToString(selectedResearchTypeList.value) === '' ? null : arrayToString(selectedResearchTypeList.value) researchTypeIds: arrayToString(selectedResearchTypeList.value) === '' ? null : arrayToString(selectedResearchTypeList.value)
} }
......
...@@ -86,11 +86,11 @@ ...@@ -86,11 +86,11 @@
</div> </div>
<div class="card2"> <div class="card2">
<div class="card-title">{{ "政府部门" }}</div> <div class="card-title">{{ "政府部门" }}</div>
<div class="card-num">{{ box1LeftData.zfJe }}亿美元</div> <div class="card-num">{{ box1LeftData.zfJe / 100000000 }}亿美元</div>
</div> </div>
<div class="card3"> <div class="card3">
<div class="card-title">{{ "其他机构" }}</div> <div class="card-title">{{ "其他机构" }}</div>
<div class="card-num">{{ box1LeftData.otherJe }}亿美元</div> <div class="card-num">{{ box1LeftData.otherJ / 100000000 }}亿美元</div>
</div> </div>
</div> </div>
<div class="box1-main-right" id="box1Chart"></div> <div class="box1-main-right" id="box1Chart"></div>
......
...@@ -2,51 +2,51 @@ const getPieChart = (data) => { ...@@ -2,51 +2,51 @@ const getPieChart = (data) => {
let option = { let option = {
series: [ series: [
{ {
type: 'pie', type: 'pie',
radius: [70, 100], radius: [70, 100],
height: '100%', height: '100%',
left: 'center', left: 'center',
width: '100%', width: '100%',
itemStyle: { itemStyle: {
borderColor: '#fff', borderColor: '#fff',
borderWidth: 1 borderWidth: 1
}, },
label: { label: {
alignTo: 'edge', alignTo: 'edge',
formatter: '{name|{b}}\n{time|{c} 条 {d}%}', formatter: '{name|{b}}\n{time|{c} 个 {d}%}',
minMargin: 15, minMargin: 15,
edgeDistance: 10, edgeDistance: 10,
lineHeight: 15, lineHeight: 15,
rich: { rich: {
name: { name: {
fontSize: 16, fontSize: 16,
color: 'rgba(59, 65, 75, 1)', color: 'rgba(59, 65, 75, 1)',
fontWeight: 700, fontWeight: 700,
}, },
time: { time: {
fontSize: 14, fontSize: 14,
color: 'rgba(59, 65, 75, 1)', color: 'rgba(59, 65, 75, 1)',
}
} }
} },
}, labelLine: {
labelLine: { length: 15,
length: 15, length2: 0,
length2: 0, maxSurfaceAngle: 80
maxSurfaceAngle: 80 },
}, labelLayout: function (params) {
labelLayout: function (params) { const isLeft = params.labelRect.x < 556 / 2;
const isLeft = params.labelRect.x < 556 / 2; const points = params.labelLinePoints;
const points = params.labelLinePoints; // Update the end point.
// Update the end point. points[2][0] = isLeft
points[2][0] = isLeft ? params.labelRect.x
? params.labelRect.x : params.labelRect.x + params.labelRect.width;
: params.labelRect.x + params.labelRect.width; return {
return { labelLinePoints: points
labelLinePoints: points };
}; },
}, data: data
data: data }]
}]
} }
return option return option
} }
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论