bug fixed
This commit is contained in:
69
info.ts
Normal file
69
info.ts
Normal file
@ -0,0 +1,69 @@
|
||||
export interface User {
|
||||
userId: number;
|
||||
userName: string;
|
||||
nickName: string;
|
||||
email: string;
|
||||
mobile: string;
|
||||
sex: string;
|
||||
post?: any;
|
||||
phone: string;
|
||||
avatar: string;
|
||||
password: string;
|
||||
status: string;
|
||||
loginIp: string;
|
||||
loginDate?: any;
|
||||
createBy: string;
|
||||
createTime: string;
|
||||
updateBy: string;
|
||||
updateTime?: any;
|
||||
remark?: any;
|
||||
}
|
||||
|
||||
export interface Enterprise {
|
||||
id: number;
|
||||
tenantId: number;
|
||||
area?: any;
|
||||
inviterId: number;
|
||||
uid: number;
|
||||
username: string;
|
||||
phone: string;
|
||||
email: string;
|
||||
kind: string;
|
||||
name: string;
|
||||
code: string;
|
||||
image: string;
|
||||
product: string;
|
||||
province: string;
|
||||
city: string;
|
||||
cityStr: string;
|
||||
district: string;
|
||||
address: string;
|
||||
url: string;
|
||||
license: string;
|
||||
industry: string;
|
||||
industrys?: any;
|
||||
industryStr: string;
|
||||
keyword: string;
|
||||
keywords: string[];
|
||||
direction: string;
|
||||
directions?: any;
|
||||
introduce: string;
|
||||
examineStatus: string;
|
||||
examineRemark: string;
|
||||
examineAt: string;
|
||||
isDeleted: string;
|
||||
createdAt: string;
|
||||
updatedAt: string;
|
||||
}
|
||||
|
||||
export interface Data {
|
||||
vip?: any;
|
||||
user: User;
|
||||
enterprise: Enterprise;
|
||||
}
|
||||
|
||||
export interface RootObject {
|
||||
msg: string;
|
||||
code: number;
|
||||
data: Data;
|
||||
}
|
@ -2,82 +2,96 @@ import request from "@/utils/request";
|
||||
|
||||
// 专家想合作企业列表
|
||||
export const expertWantEnterpriseList = (params) => {
|
||||
return request({
|
||||
url: `/app/expert/expertWantEnterpriseList`,
|
||||
method: "GET",
|
||||
params
|
||||
});
|
||||
return request({
|
||||
url: `/app/expert/expertWantEnterpriseList`,
|
||||
method: "GET",
|
||||
params,
|
||||
});
|
||||
};
|
||||
// 新增想合作企业
|
||||
export const insertExpertWantEnterprise = (data) => {
|
||||
return request({
|
||||
url: `/app/expert/insertExpertWantEnterprise`,
|
||||
method: "POST",
|
||||
data
|
||||
});
|
||||
return request({
|
||||
url: `/app/expert/insertExpertWantEnterprise`,
|
||||
method: "POST",
|
||||
data,
|
||||
});
|
||||
};
|
||||
// 修改想合作企业
|
||||
export const updateExpertWantEnterprise = (data) => {
|
||||
return request({
|
||||
url: `/app/expert/updateExpertWantEnterprise`,
|
||||
method: "PUT",
|
||||
data
|
||||
});
|
||||
return request({
|
||||
url: `/app/expert/updateExpertWantEnterprise`,
|
||||
method: "PUT",
|
||||
data,
|
||||
});
|
||||
};
|
||||
// 删除想合作企业
|
||||
export const deleteExpertWantEnterpriseByIds = (data) => {
|
||||
return request({
|
||||
url: `/app/expert/deleteExpertWantEnterpriseByIds`,
|
||||
method: "DELETE",
|
||||
data
|
||||
});
|
||||
return request({
|
||||
url: `/app/expert/deleteExpertWantEnterpriseByIds`,
|
||||
method: "DELETE",
|
||||
data,
|
||||
});
|
||||
};
|
||||
|
||||
|
||||
// 专家服务需求列表
|
||||
export const demandList = (params) => {
|
||||
return request({
|
||||
url: `/app/expert/demandList`,
|
||||
method: "GET",
|
||||
params
|
||||
});
|
||||
return request({
|
||||
url: `/app/expert/demandList`,
|
||||
method: "GET",
|
||||
params,
|
||||
});
|
||||
};
|
||||
// 新增服务需求
|
||||
export const insertDemand = (data) => {
|
||||
return request({
|
||||
url: `/app/expert/insertDemand`,
|
||||
method: "POST",
|
||||
data
|
||||
});
|
||||
return request({
|
||||
url: `/app/expert/insertDemand`,
|
||||
method: "POST",
|
||||
data,
|
||||
});
|
||||
};
|
||||
// 专家已合作企业列表
|
||||
export const getExpertCooperateEnterpriseList = (params) => {
|
||||
return request({
|
||||
url: `/app/expert/getExpertCooperateEnterpriseList`,
|
||||
method: "GET",
|
||||
params
|
||||
});
|
||||
return request({
|
||||
url: `/app/expert/getExpertCooperateEnterpriseList`,
|
||||
method: "GET",
|
||||
params,
|
||||
});
|
||||
};
|
||||
// 专家新增已合作企业
|
||||
export const insertExpertCooperateEnterprise = (data) => {
|
||||
return request({
|
||||
url: `/app/expert/insertExpertCooperateEnterprise`,
|
||||
method: "POST",
|
||||
data
|
||||
});
|
||||
return request({
|
||||
url: `/app/expert/insertExpertCooperateEnterprise`,
|
||||
method: "POST",
|
||||
data,
|
||||
});
|
||||
};
|
||||
// 专家修改已合作企业
|
||||
export const updateExpertCooperateEnterprise = (data) => {
|
||||
return request({
|
||||
url: `/app/expert/updateExpertCooperateEnterprise`,
|
||||
method: "PUT",
|
||||
data
|
||||
});
|
||||
return request({
|
||||
url: `/app/expert/updateExpertCooperateEnterprise`,
|
||||
method: "PUT",
|
||||
data,
|
||||
});
|
||||
};
|
||||
// 删除已合作
|
||||
export const deleteExpertCooperateEnterpriseByIds = (ids) => {
|
||||
return request({
|
||||
url: `/app/expert/deleteExpertCooperateEnterpriseByIds/${ids}`,
|
||||
method: "DELETE",
|
||||
});
|
||||
};
|
||||
return request({
|
||||
url: `/app/expert/deleteExpertCooperateEnterpriseByIds/${ids}`,
|
||||
method: "DELETE",
|
||||
});
|
||||
};
|
||||
// 获取服务需求详情
|
||||
export const getDemandById = (id) => {
|
||||
return request({
|
||||
url: `/app/expert/getDemand/${id}`,
|
||||
method: "GET",
|
||||
});
|
||||
};
|
||||
// 修改服务需求
|
||||
export const updateDemand = (data) => {
|
||||
return request({
|
||||
url: `/app/expert/updateDemand`,
|
||||
method: "PUT",
|
||||
data,
|
||||
});
|
||||
};
|
||||
|
@ -91,6 +91,13 @@ export function searchAchievementDetail(id) {
|
||||
method: "get",
|
||||
});
|
||||
}
|
||||
// 客户端实验室搜索结果详情
|
||||
export function searchLaboratoryDetail(id) {
|
||||
return request({
|
||||
url: `/search/laboratory/${id}`,
|
||||
method: "get",
|
||||
});
|
||||
}
|
||||
// 客户端专家搜索结果详情
|
||||
export function searchExpertDetail(id) {
|
||||
return request({
|
||||
@ -222,3 +229,10 @@ export function countAchievementByArea(cityCode) {
|
||||
},
|
||||
});
|
||||
}
|
||||
// 获取尾部导航
|
||||
export function getCasNavigation() {
|
||||
return request({
|
||||
url: "/app/about/getCasNavigation",
|
||||
method: "get",
|
||||
});
|
||||
}
|
||||
|
@ -48,6 +48,7 @@
|
||||
import request from "@/utils/request";
|
||||
import { onMounted, reactive, watch } from "vue";
|
||||
import { getCategory } from "@/api/website/solution";
|
||||
import { getCasNavigation } from "@/api/website/home";
|
||||
|
||||
function navigation() {
|
||||
return request({
|
||||
@ -66,178 +67,179 @@ const state = reactive({
|
||||
email: "",
|
||||
address: "",
|
||||
});
|
||||
function getNavigation() {
|
||||
async function getNavigation() {
|
||||
// navigation().then((res) => {
|
||||
// if (200 == res.code) {
|
||||
// state.list = res.data;
|
||||
// }
|
||||
// });
|
||||
const res = {
|
||||
msg: "操作成功",
|
||||
code: 200,
|
||||
data: [
|
||||
{
|
||||
id: 21,
|
||||
tenantId: 3,
|
||||
parentId: 0,
|
||||
title: "创新服务",
|
||||
link: "/",
|
||||
targetFlag: "0",
|
||||
sort: 0,
|
||||
status: "1",
|
||||
createTime: "2022-02-21 14:03:28",
|
||||
updateTime: "2022-02-21 14:03:28",
|
||||
children: [
|
||||
{
|
||||
id: 22,
|
||||
tenantId: 1,
|
||||
parentId: 21,
|
||||
title: "中科院设备共享平台",
|
||||
link: "http://samp.cas.cn",
|
||||
targetFlag: "0",
|
||||
sort: 0,
|
||||
status: "1",
|
||||
createTime: "2022-02-21 14:03:47",
|
||||
updateTime: "2022-02-21 14:03:47",
|
||||
children: [],
|
||||
},
|
||||
{
|
||||
id: 23,
|
||||
tenantId: 1,
|
||||
parentId: 21,
|
||||
title: "中科院文献情报中心",
|
||||
link: "https://www.las.ac.cn",
|
||||
targetFlag: "0",
|
||||
sort: 0,
|
||||
status: "1",
|
||||
createTime: "2022-02-21 14:04:52",
|
||||
updateTime: "2022-02-21 14:04:52",
|
||||
children: [],
|
||||
},
|
||||
{
|
||||
id: 25,
|
||||
tenantId: 1,
|
||||
parentId: 21,
|
||||
title: "中国科学院",
|
||||
link: "https://www.cas.cn",
|
||||
targetFlag: "0",
|
||||
sort: 0,
|
||||
status: "1",
|
||||
createTime: "2022-02-21 14:05:59",
|
||||
updateTime: "2022-02-21 14:05:59",
|
||||
children: [],
|
||||
},
|
||||
{
|
||||
id: 26,
|
||||
tenantId: 1,
|
||||
parentId: 21,
|
||||
title: "中科院重庆院合肥分院",
|
||||
link: "http://www.caszl.cn",
|
||||
targetFlag: "0",
|
||||
sort: 0,
|
||||
status: "1",
|
||||
createTime: "2022-02-21 14:06:29",
|
||||
updateTime: "2022-02-21 14:06:29",
|
||||
children: [],
|
||||
},
|
||||
],
|
||||
},
|
||||
{
|
||||
id: 29,
|
||||
tenantId: 3,
|
||||
parentId: 0,
|
||||
title: "联系我们",
|
||||
link: "/",
|
||||
targetFlag: "0",
|
||||
sort: 0,
|
||||
status: "1",
|
||||
createTime: "2022-11-15 16:20:19",
|
||||
updateTime: null,
|
||||
children: [
|
||||
{
|
||||
id: 30,
|
||||
tenantId: 3,
|
||||
parentId: 29,
|
||||
title: "客服电话:18156053255",
|
||||
link: "/",
|
||||
targetFlag: "0",
|
||||
sort: 0,
|
||||
status: "1",
|
||||
createTime: "2022-11-15 16:20:39",
|
||||
updateTime: null,
|
||||
children: [],
|
||||
},
|
||||
{
|
||||
id: 31,
|
||||
tenantId: 3,
|
||||
parentId: 29,
|
||||
title: "邮箱:zky@gmail.com",
|
||||
link: "/",
|
||||
targetFlag: "0",
|
||||
sort: 0,
|
||||
status: "1",
|
||||
createTime: "2022-11-15 16:20:56",
|
||||
updateTime: null,
|
||||
children: [],
|
||||
},
|
||||
{
|
||||
id: 32,
|
||||
tenantId: 3,
|
||||
parentId: 29,
|
||||
title: "地址:安徽省合肥市高新区创新产业园D1南楼",
|
||||
link: "/",
|
||||
targetFlag: "0",
|
||||
sort: 0,
|
||||
status: "1",
|
||||
createTime: "2022-11-15 16:21:43",
|
||||
updateTime: null,
|
||||
children: [],
|
||||
},
|
||||
],
|
||||
},
|
||||
{
|
||||
id: 33,
|
||||
tenantId: 3,
|
||||
parentId: 0,
|
||||
title: "解决方案",
|
||||
link: "/",
|
||||
targetFlag: "0",
|
||||
sort: 0,
|
||||
status: "1",
|
||||
createTime: "2022-11-15 16:22:41",
|
||||
updateTime: null,
|
||||
children: [
|
||||
{
|
||||
id: 34,
|
||||
tenantId: 3,
|
||||
parentId: 33,
|
||||
title: "企业创新升级",
|
||||
link: "/",
|
||||
targetFlag: "0",
|
||||
sort: 0,
|
||||
status: "1",
|
||||
createTime: "2022-11-15 16:22:58",
|
||||
updateTime: null,
|
||||
children: [],
|
||||
},
|
||||
{
|
||||
id: 35,
|
||||
tenantId: 3,
|
||||
parentId: 33,
|
||||
title: "成果转化",
|
||||
link: "/",
|
||||
targetFlag: "0",
|
||||
sort: 0,
|
||||
status: "1",
|
||||
createTime: "2022-11-15 16:23:21",
|
||||
updateTime: null,
|
||||
children: [],
|
||||
},
|
||||
],
|
||||
},
|
||||
],
|
||||
};
|
||||
state.list = res.data;
|
||||
const resp = await getCasNavigation();
|
||||
// const res = {
|
||||
// msg: "操作成功",
|
||||
// code: 200,
|
||||
// data: [
|
||||
// {
|
||||
// id: 21,
|
||||
// tenantId: 3,
|
||||
// parentId: 0,
|
||||
// title: "创新服务",
|
||||
// link: "/",
|
||||
// targetFlag: "0",
|
||||
// sort: 0,
|
||||
// status: "1",
|
||||
// createTime: "2022-02-21 14:03:28",
|
||||
// updateTime: "2022-02-21 14:03:28",
|
||||
// children: [
|
||||
// {
|
||||
// id: 22,
|
||||
// tenantId: 1,
|
||||
// parentId: 21,
|
||||
// title: "中科院设备共享平台",
|
||||
// link: "http://samp.cas.cn",
|
||||
// targetFlag: "0",
|
||||
// sort: 0,
|
||||
// status: "1",
|
||||
// createTime: "2022-02-21 14:03:47",
|
||||
// updateTime: "2022-02-21 14:03:47",
|
||||
// children: [],
|
||||
// },
|
||||
// {
|
||||
// id: 23,
|
||||
// tenantId: 1,
|
||||
// parentId: 21,
|
||||
// title: "中科院文献情报中心",
|
||||
// link: "https://www.las.ac.cn",
|
||||
// targetFlag: "0",
|
||||
// sort: 0,
|
||||
// status: "1",
|
||||
// createTime: "2022-02-21 14:04:52",
|
||||
// updateTime: "2022-02-21 14:04:52",
|
||||
// children: [],
|
||||
// },
|
||||
// {
|
||||
// id: 25,
|
||||
// tenantId: 1,
|
||||
// parentId: 21,
|
||||
// title: "中国科学院",
|
||||
// link: "https://www.cas.cn",
|
||||
// targetFlag: "0",
|
||||
// sort: 0,
|
||||
// status: "1",
|
||||
// createTime: "2022-02-21 14:05:59",
|
||||
// updateTime: "2022-02-21 14:05:59",
|
||||
// children: [],
|
||||
// },
|
||||
// {
|
||||
// id: 26,
|
||||
// tenantId: 1,
|
||||
// parentId: 21,
|
||||
// title: "中科院重庆院合肥分院",
|
||||
// link: "http://www.caszl.cn",
|
||||
// targetFlag: "0",
|
||||
// sort: 0,
|
||||
// status: "1",
|
||||
// createTime: "2022-02-21 14:06:29",
|
||||
// updateTime: "2022-02-21 14:06:29",
|
||||
// children: [],
|
||||
// },
|
||||
// ],
|
||||
// },
|
||||
// {
|
||||
// id: 29,
|
||||
// tenantId: 3,
|
||||
// parentId: 0,
|
||||
// title: "联系我们",
|
||||
// link: "/",
|
||||
// targetFlag: "0",
|
||||
// sort: 0,
|
||||
// status: "1",
|
||||
// createTime: "2022-11-15 16:20:19",
|
||||
// updateTime: null,
|
||||
// children: [
|
||||
// {
|
||||
// id: 30,
|
||||
// tenantId: 3,
|
||||
// parentId: 29,
|
||||
// title: "客服电话:18156053255",
|
||||
// link: "/",
|
||||
// targetFlag: "0",
|
||||
// sort: 0,
|
||||
// status: "1",
|
||||
// createTime: "2022-11-15 16:20:39",
|
||||
// updateTime: null,
|
||||
// children: [],
|
||||
// },
|
||||
// {
|
||||
// id: 31,
|
||||
// tenantId: 3,
|
||||
// parentId: 29,
|
||||
// title: "邮箱:zky@gmail.com",
|
||||
// link: "/",
|
||||
// targetFlag: "0",
|
||||
// sort: 0,
|
||||
// status: "1",
|
||||
// createTime: "2022-11-15 16:20:56",
|
||||
// updateTime: null,
|
||||
// children: [],
|
||||
// },
|
||||
// {
|
||||
// id: 32,
|
||||
// tenantId: 3,
|
||||
// parentId: 29,
|
||||
// title: "地址:安徽省合肥市高新区创新产业园D1南楼",
|
||||
// link: "/",
|
||||
// targetFlag: "0",
|
||||
// sort: 0,
|
||||
// status: "1",
|
||||
// createTime: "2022-11-15 16:21:43",
|
||||
// updateTime: null,
|
||||
// children: [],
|
||||
// },
|
||||
// ],
|
||||
// },
|
||||
// {
|
||||
// id: 33,
|
||||
// tenantId: 3,
|
||||
// parentId: 0,
|
||||
// title: "解决方案",
|
||||
// link: "/",
|
||||
// targetFlag: "0",
|
||||
// sort: 0,
|
||||
// status: "1",
|
||||
// createTime: "2022-11-15 16:22:41",
|
||||
// updateTime: null,
|
||||
// children: [
|
||||
// {
|
||||
// id: 34,
|
||||
// tenantId: 3,
|
||||
// parentId: 33,
|
||||
// title: "企业创新升级",
|
||||
// link: "/",
|
||||
// targetFlag: "0",
|
||||
// sort: 0,
|
||||
// status: "1",
|
||||
// createTime: "2022-11-15 16:22:58",
|
||||
// updateTime: null,
|
||||
// children: [],
|
||||
// },
|
||||
// {
|
||||
// id: 35,
|
||||
// tenantId: 3,
|
||||
// parentId: 33,
|
||||
// title: "成果转化",
|
||||
// link: "/",
|
||||
// targetFlag: "0",
|
||||
// sort: 0,
|
||||
// status: "1",
|
||||
// createTime: "2022-11-15 16:23:21",
|
||||
// updateTime: null,
|
||||
// children: [],
|
||||
// },
|
||||
// ],
|
||||
// },
|
||||
// ],
|
||||
// };
|
||||
state.list = resp.data;
|
||||
}
|
||||
async function getConfig() {
|
||||
// const mobileData = await config({ key: "mobile" });
|
||||
@ -275,7 +277,7 @@ async function getConfig() {
|
||||
// });
|
||||
}
|
||||
getNavigation();
|
||||
getConfig();
|
||||
// getConfig();
|
||||
|
||||
const solutionCategoryList = ref([]);
|
||||
const loadsolutionCategoryList = async () => {
|
||||
|
@ -73,6 +73,21 @@ export const constantRoutes = [
|
||||
searchType: 2,
|
||||
},
|
||||
},
|
||||
{
|
||||
path: "searchList/lab",
|
||||
component: () => import("../views/website/searchList/lab.vue"),
|
||||
meta: {
|
||||
searchType: 8,
|
||||
},
|
||||
},
|
||||
{
|
||||
path: "searchList/lab/detail/:id",
|
||||
component: () =>
|
||||
import("../views/website/searchList/laboratoryDetail.vue"),
|
||||
meta: {
|
||||
searchType: 8,
|
||||
},
|
||||
},
|
||||
{
|
||||
path: "searchList/patent",
|
||||
component: () => import("../views/website/searchList/patent.vue"),
|
||||
|
28
src/utils/city.js
Normal file
28
src/utils/city.js
Normal file
@ -0,0 +1,28 @@
|
||||
import request from "@/utils/request";
|
||||
|
||||
export const getCity = async (provinceCode, cityCode, areaCode) => {
|
||||
const resps = await Promise.all([
|
||||
request({
|
||||
url: `/region/allProvince`,
|
||||
}),
|
||||
request({
|
||||
url: `/region/allCity`,
|
||||
params: {
|
||||
provinceCode,
|
||||
},
|
||||
}),
|
||||
request({
|
||||
url: `/region/allArea`,
|
||||
params: {
|
||||
cityCode,
|
||||
},
|
||||
}),
|
||||
]);
|
||||
const provinceStr = resps[0].data.find(
|
||||
(el) => el.provinceCode == provinceCode
|
||||
).provinceName;
|
||||
// console.log(provinceStr);
|
||||
const cityStr = resps[1].data.find((el) => el.cityCode == cityCode).cityName;
|
||||
const areaStr = resps[2].data.find((el) => el.areaCode == areaCode).areaName;
|
||||
return `${provinceStr} ${cityStr} ${areaStr}`;
|
||||
};
|
@ -35,6 +35,27 @@ export const enterpriseOptions = [
|
||||
{ key: "104", value: "高新技术企业" },
|
||||
{ key: "105", value: "科技企业" },
|
||||
];
|
||||
// 需求类型
|
||||
export const demandCategoryList = [
|
||||
{ id: 1, name: "基金对接" },
|
||||
{ id: 2, name: "贷款" },
|
||||
{ id: 3, name: "对接专家院士" },
|
||||
{ id: 4, name: "人才培养" },
|
||||
{ id: 5, name: "一带一路国际合作" },
|
||||
{ id: 6, name: "上市辅导" },
|
||||
{ id: 7, name: "成果产业化" },
|
||||
{ id: 8, name: "国家级科研平台合作" },
|
||||
{ id: 9, name: "研发项目立项评估" },
|
||||
{ id: 10, name: "科技查新" },
|
||||
{ id: 11, name: "产业链上下游对接" },
|
||||
{ id: 12, name: "委托研发" },
|
||||
{ id: 13, name: "对接政府项目落地" },
|
||||
{ id: 14, name: "技术咨询" },
|
||||
{ id: 15, name: "高价值专利培育" },
|
||||
{ id: 16, name: "知识产权布局" },
|
||||
{ id: 17, name: "设立院士工作站" },
|
||||
{ id: 18, name: "海外留学生培养" },
|
||||
];
|
||||
// export const enterpriseOptions = [
|
||||
// { key: "101", value: '上市企业' },
|
||||
// { key: "102", value: '优质企业' },
|
||||
|
@ -120,6 +120,7 @@ import {
|
||||
// import CityOptions from "@/views/components/CityOptions";
|
||||
import { ElMessage } from "element-plus";
|
||||
import { onActivated } from "vue";
|
||||
import { demandCategoryList } from "@/utils/parameter";
|
||||
// import { onActivated } from "vue";
|
||||
import { useRoute, useRouter } from "vue-router";
|
||||
|
||||
@ -154,24 +155,7 @@ const data = reactive({
|
||||
const { form, rules } = toRefs(data);
|
||||
|
||||
const labelWidth = 140;
|
||||
const checkList = reactive([
|
||||
{
|
||||
id: 1,
|
||||
name: "成果推广",
|
||||
},
|
||||
{
|
||||
id: 2,
|
||||
name: "关键成果解决",
|
||||
},
|
||||
{
|
||||
id: 3,
|
||||
name: "对接专家院士",
|
||||
},
|
||||
{
|
||||
id: 4,
|
||||
name: "上市辅导",
|
||||
},
|
||||
]);
|
||||
const checkList = reactive([...demandCategoryList]);
|
||||
const checkInput = ref("");
|
||||
// const cityFormRef = ref();
|
||||
const formRef = ref();
|
||||
@ -215,6 +199,8 @@ function addCheck() {
|
||||
onMounted(() => {
|
||||
formRef.value.resetFields();
|
||||
if (route.query.id) {
|
||||
const obj = Object.assign({}, route, { title: "修改服务需求" });
|
||||
tab.updatePage(obj);
|
||||
getDemand({ id: route.query.id }).then((resp) => {
|
||||
if (resp.data.kinds) {
|
||||
resp.data.kinds.forEach((el, index) => {
|
||||
|
@ -310,19 +310,19 @@ const submitForm = async (status) => {
|
||||
// }
|
||||
// });
|
||||
};
|
||||
function addCheck() {
|
||||
if (!checkInput.value.trim().length) return proxy.$modal.msgError("请输入");
|
||||
const flag = checkList.some((item) => {
|
||||
return item.name.trim() == checkInput.value.trim();
|
||||
});
|
||||
if (!flag) {
|
||||
checkList.push({
|
||||
id: checkList.length + 1,
|
||||
name: checkInput.value,
|
||||
});
|
||||
checkInput.value = "";
|
||||
}
|
||||
}
|
||||
// function addCheck() {
|
||||
// if (!checkInput.value.trim().length) return proxy.$modal.msgError("请输入");
|
||||
// const flag = checkList.some((item) => {
|
||||
// return item.name.trim() == checkInput.value.trim();
|
||||
// });
|
||||
// if (!flag) {
|
||||
// checkList.push({
|
||||
// id: checkList.length + 1,
|
||||
// name: checkInput.value,
|
||||
// });
|
||||
// checkInput.value = "";
|
||||
// }
|
||||
// }
|
||||
// 返回技术需求列表
|
||||
const backToList = () => {
|
||||
tab.closeOpenPage({ path: "/demand/technology" });
|
||||
@ -332,6 +332,8 @@ onMounted(() => {
|
||||
formRef.value.resetFields();
|
||||
|
||||
if (route.query.id) {
|
||||
const obj = Object.assign({}, route, { title: "修改技术需求" });
|
||||
tab.updatePage(obj);
|
||||
getTechnologyDemand({ id: route.query.id }).then((resp) => {
|
||||
form.value = resp.data;
|
||||
|
||||
|
@ -13,7 +13,7 @@
|
||||
<el-radio-button label="5">专家</el-radio-button>
|
||||
<!-- <el-radio-button label="6">服务需求</el-radio-button> -->
|
||||
<!-- <el-radio-button label="7">技术需求</el-radio-button> -->
|
||||
<!-- <el-radio-button label="4">实验室</el-radio-button> -->
|
||||
<el-radio-button label="8">实验室</el-radio-button>
|
||||
</el-radio-group>
|
||||
|
||||
<div v-if="dataList.length" style="margin-top: 20px" v-loading="loading">
|
||||
@ -79,6 +79,7 @@ const loading = ref(true);
|
||||
const total = ref(0);
|
||||
|
||||
const queryType = computed(() => {
|
||||
console.log(queryParams.value.searchType);
|
||||
if (queryParams.value.searchType == 1) {
|
||||
return 2;
|
||||
} else if (queryParams.value.searchType == 2) {
|
||||
@ -87,9 +88,9 @@ const queryType = computed(() => {
|
||||
return 2;
|
||||
} else if (queryParams.value.searchType == 5) {
|
||||
return 2;
|
||||
} else if (queryParams.value.searchType == 8) {
|
||||
return 2;
|
||||
}
|
||||
// else if (queryParams.value.searchType == 6) {
|
||||
// return 1;
|
||||
// } else if (queryParams.value.searchType == 7) {
|
||||
// return 1;
|
||||
// }
|
||||
|
@ -12,8 +12,10 @@
|
||||
<el-radio-button label="4">专利</el-radio-button>
|
||||
<el-radio-button label="5">专家</el-radio-button>
|
||||
<!-- <el-radio-button label="6">服务需求</el-radio-button> -->
|
||||
<el-radio-button label="7">技术需求</el-radio-button>
|
||||
<!-- <el-radio-button label="4">实验室</el-radio-button> -->
|
||||
<el-radio-button label="8">实验室</el-radio-button>
|
||||
<el-radio-button label="7" v-if="route.path != '/demand/results'"
|
||||
>技术需求</el-radio-button
|
||||
>
|
||||
</el-radio-group>
|
||||
|
||||
<!-- <el-row :gutter="20">
|
||||
@ -80,6 +82,10 @@
|
||||
:data="item"
|
||||
v-else-if="queryParams.searchType == 7"
|
||||
></TechnologyDemandItem>
|
||||
<LaboratoryItem
|
||||
:data="item"
|
||||
v-else-if="queryParams.searchType == 8"
|
||||
></LaboratoryItem>
|
||||
</div>
|
||||
</section>
|
||||
</div>
|
||||
@ -102,16 +108,20 @@ import expertItem from "@/views/website/searchList/components/expertItem.vue";
|
||||
import serviceDemandItem from "@/views/website/searchList/components/serviceDemandItem.vue";
|
||||
import enterpriseItem from "../../components/enterpriseItem.vue";
|
||||
import TechnologyDemandItem from "@/views/website/searchList/components/technologyDemandItem.vue";
|
||||
|
||||
import AchievementItem from "@/views/website/searchList/components/achievementItem.vue";
|
||||
import { useRoute, useRouter } from "vue-router";
|
||||
import useUserStore from "@/store/modules/user";
|
||||
import LaboratoryItem from "@/views/website/searchList/components/laboratoryItem.vue";
|
||||
const route = useRoute();
|
||||
|
||||
const router = useRouter();
|
||||
const dataList = ref([]);
|
||||
const loading = ref(true);
|
||||
const total = ref(0);
|
||||
const userStore = useUserStore();
|
||||
const queryType = computed(() => {
|
||||
console.log(queryParams.value.searchType);
|
||||
if (queryParams.value.searchType == 1) {
|
||||
return 2;
|
||||
} else if (queryParams.value.searchType == 2) {
|
||||
@ -124,6 +134,8 @@ const queryType = computed(() => {
|
||||
return 1;
|
||||
} else if (queryParams.value.searchType == 7) {
|
||||
return 1;
|
||||
} else if (queryParams.value.searchType == 8) {
|
||||
return 2;
|
||||
}
|
||||
});
|
||||
|
||||
@ -134,6 +146,7 @@ const data = reactive({
|
||||
query: route.query.keyword,
|
||||
searchType: "1",
|
||||
queryType: queryType,
|
||||
isMatch: true,
|
||||
},
|
||||
});
|
||||
|
||||
@ -158,17 +171,17 @@ async function getList() {
|
||||
// console.log(userStore.enterprise.id);
|
||||
dataList.value = resp.list;
|
||||
// 排除自己企业
|
||||
if (queryParams.value.searchType === "1") {
|
||||
dataList.value = dataList.value.filter(
|
||||
(el) => el.id != userStore.enterprise?.id
|
||||
);
|
||||
}
|
||||
// if (queryParams.value.searchType === "1") {
|
||||
// dataList.value = dataList.value.filter(
|
||||
// (el) => el.id != userStore.enterprise?.id
|
||||
// );
|
||||
// }
|
||||
// 成果排除专家自己
|
||||
else if (queryParams.value.searchType === "2") {
|
||||
dataList.value = dataList.value.filter(
|
||||
(el) => el.expertId != userStore.userId
|
||||
);
|
||||
}
|
||||
// if (queryParams.value.searchType === "2") {
|
||||
// dataList.value = dataList.value.filter(
|
||||
// (el) => el.expertId != userStore.userId
|
||||
// );
|
||||
// }
|
||||
total.value = resp.total;
|
||||
loading.value = false;
|
||||
}
|
||||
|
@ -8,7 +8,10 @@
|
||||
{{ vipData.vipType == 1 ? "VIP" : "SVIP" }}
|
||||
</div> -->
|
||||
<!-- <div class="text-right">续期</div> -->
|
||||
<div v-if="vipData.vipType == 1">升级SVIP</div>
|
||||
<div v-if="vipData.vipType == 1">
|
||||
<div>VIP</div>
|
||||
<div>升级SVIP</div>
|
||||
</div>
|
||||
<div v-else-if="!vipData.vipType">普通会员</div>
|
||||
</div>
|
||||
<div
|
||||
|
@ -85,7 +85,11 @@
|
||||
ref="customersFormRef"
|
||||
/>
|
||||
|
||||
<CityOptions v-model="modelValue" :labelWidth="labelWidth"></CityOptions>
|
||||
<CityOptions
|
||||
ref="cityFormRef"
|
||||
v-model="modelValue"
|
||||
:labelWidth="labelWidth"
|
||||
></CityOptions>
|
||||
<el-row>
|
||||
<el-col :span="24">
|
||||
<el-form-item label="成果成熟度:" prop="maturity">
|
||||
@ -168,6 +172,7 @@
|
||||
<el-form-item label="所属单位:" prop="unit">
|
||||
<el-input
|
||||
v-model="modelValue.unit"
|
||||
placeholder="请输入所属单位"
|
||||
></el-input> </el-form-item></el-col
|
||||
></el-row>
|
||||
<el-row>
|
||||
@ -253,11 +258,22 @@ const props = defineProps({
|
||||
const { modelValue, isAdd, showTitle, labelWidth } = toRefs(props);
|
||||
const data = reactive({
|
||||
rules: {
|
||||
title: [{ required: true, message: "请输入", trigger: "blur" }],
|
||||
maturity: [{ required: true, message: "请选择", trigger: "change" }],
|
||||
leadStandard: [{ required: true, message: "请选择", trigger: "change" }],
|
||||
description: [{ required: true, message: "请输入", trigger: "blur" }],
|
||||
image: [{ required: true, message: "请上传", trigger: ["change", "blur"] }],
|
||||
title: [{ required: true, message: "请输入成果名称", trigger: "blur" }],
|
||||
maturity: [{ required: true, message: "请选择成熟度", trigger: "change" }],
|
||||
leadStandard: [
|
||||
{ required: true, message: "请选择领先情况", trigger: "change" },
|
||||
],
|
||||
description: [
|
||||
{ required: true, message: "请输入成果简介", trigger: "blur" },
|
||||
],
|
||||
image: [
|
||||
{
|
||||
required: true,
|
||||
message: "请上传成果图片",
|
||||
trigger: ["change", "blur"],
|
||||
},
|
||||
],
|
||||
unit: [{ required: true, message: "请输入所属单位", trigger: "blur" }],
|
||||
},
|
||||
});
|
||||
const { rules } = toRefs(data);
|
||||
@ -266,6 +282,7 @@ const formRef = ref();
|
||||
const fieldFormRef = ref();
|
||||
const customersFormRef = ref();
|
||||
const directionsFormRef = ref();
|
||||
const cityFormRef = ref();
|
||||
const keywordsFormRef = ref();
|
||||
const validateForm = async () => {
|
||||
let formValid;
|
||||
@ -277,13 +294,15 @@ const validateForm = async () => {
|
||||
const fieldFormValid = await fieldFormRef.value.validateForm(); // 城市选择表单验证
|
||||
const customersValid = await customersFormRef.value.validateForm(); // 领域选择表单验证
|
||||
// const directionsFormRef = await customersFormRef.value.validateForm(); // 领域选择表单验证
|
||||
const keywordsFormRef = await customersFormRef.value.validateForm(); // 领域选择表单验证
|
||||
|
||||
const cityFormValid = await cityFormRef.value.validateForm();
|
||||
const keywordsFormValid = await keywordsFormRef.value.validateForm(); // 关键词
|
||||
return (
|
||||
formValid &&
|
||||
fieldFormValid &&
|
||||
customersValid &&
|
||||
// directionsFormRef &&
|
||||
keywordsFormRef
|
||||
cityFormValid &&
|
||||
keywordsFormValid
|
||||
);
|
||||
};
|
||||
defineExpose({
|
||||
|
@ -112,23 +112,18 @@
|
||||
</template>
|
||||
<script setup>
|
||||
// import { expert } from "@/api/identity/index";
|
||||
import { insertDemand } from "@/api/admin/expert/demand";
|
||||
import {
|
||||
insertDemand,
|
||||
getDemandById,
|
||||
updateDemand,
|
||||
} from "@/api/admin/expert/demand";
|
||||
import { demandCategoryList } from "@/utils/parameter";
|
||||
import { uniqueId } from "lodash";
|
||||
import tab from "@/plugins/tab";
|
||||
// import CityOptions from "@/views/components/CityOptions";
|
||||
import { ElMessage } from "element-plus";
|
||||
import { useRoute, useRouter } from "vue-router";
|
||||
|
||||
const validateWangEditor = (rule, value, callback) => {
|
||||
console.log(rule);
|
||||
if (wangEditorRef.value.isEmpty()) {
|
||||
callback(new Error(rule.message));
|
||||
} else {
|
||||
callback();
|
||||
}
|
||||
};
|
||||
const testBlur = () => {
|
||||
console.log("fsd");
|
||||
};
|
||||
const data = reactive({
|
||||
formData: {
|
||||
check: [],
|
||||
@ -173,38 +168,15 @@ const data = reactive({
|
||||
|
||||
const { queryParams, formData, rules } = toRefs(data);
|
||||
|
||||
const { proxy } = getCurrentInstance();
|
||||
const route = useRoute();
|
||||
const router = useRouter();
|
||||
// const cityFormRef = ref();
|
||||
const formRef = ref();
|
||||
|
||||
if (route.query.id) {
|
||||
}
|
||||
|
||||
const back = () => {
|
||||
tab.closeOpenPage({ path: "/demand/serviceDemand" });
|
||||
};
|
||||
const labelWidth = 140;
|
||||
// const isContainOther = ref(false);
|
||||
const checkList = reactive([
|
||||
{
|
||||
id: 1,
|
||||
name: "成果推广",
|
||||
},
|
||||
{
|
||||
id: 2,
|
||||
name: "关键成果解决",
|
||||
},
|
||||
{
|
||||
id: 3,
|
||||
name: "对接专家院士",
|
||||
},
|
||||
{
|
||||
id: 4,
|
||||
name: "上市辅导",
|
||||
},
|
||||
]);
|
||||
const checkList = reactive([...demandCategoryList]);
|
||||
const wangEditorRef = ref();
|
||||
const checkInput = ref("");
|
||||
async function submitForm() {
|
||||
@ -212,19 +184,16 @@ async function submitForm() {
|
||||
await formRef.value.validate();
|
||||
if (formData.value.id) {
|
||||
// TODO: 修改专家需求
|
||||
// updatePost(form.value).then((response) => {
|
||||
// proxy.$modal.msgSuccess("修改成功");
|
||||
// proxy.$router.go(-1);
|
||||
// });
|
||||
await updateDemand(formData.value);
|
||||
ElMessage.success("修改成功");
|
||||
} else {
|
||||
await insertDemand(formData.value);
|
||||
ElMessage.success("新增成功");
|
||||
// router.back();
|
||||
}
|
||||
tab.closeOpenPage({ path: "/demand/serviceDemand" });
|
||||
}
|
||||
function addCheck() {
|
||||
if (!checkInput.value.trim().length) return proxy.$modal.msgError("请输入");
|
||||
if (!checkInput.value.trim().length) return ElMessage.error("请输入");
|
||||
const flag = checkList.some((item) => {
|
||||
return item.name.trim() == checkInput.value.trim();
|
||||
});
|
||||
@ -236,4 +205,18 @@ function addCheck() {
|
||||
checkInput.value = "";
|
||||
}
|
||||
}
|
||||
const getDetail = async () => {
|
||||
const resp = await getDemandById(route.query.id);
|
||||
formData.value = resp.data;
|
||||
for (const item of resp.data.kinds) {
|
||||
if (!checkList.find((el) => el.name === item)) {
|
||||
checkList.push({ id: uniqueId("unq-"), name: item });
|
||||
}
|
||||
}
|
||||
};
|
||||
if (route.query.id) {
|
||||
const obj = Object.assign({}, route, { title: "修改需求" });
|
||||
tab.updatePage(obj);
|
||||
getDetail();
|
||||
}
|
||||
</script>
|
||||
|
@ -24,7 +24,7 @@
|
||||
</el-radio-group>
|
||||
|
||||
<el-table v-loading="loading" :data="dataList" style="margin-top: 20px">
|
||||
<el-table-column label="需求名称" align="center" prop="title" />
|
||||
<!-- <el-table-column label="需求名称" align="center" prop="title" /> -->
|
||||
<el-table-column label="需求类别" align="center" prop="kind" />
|
||||
<el-table-column label="状态" align="center" prop="status" />
|
||||
<el-table-column label="联系人" align="center" prop="name" />
|
||||
|
@ -44,7 +44,7 @@
|
||||
v-if="queryParams.status == 1"
|
||||
size="small"
|
||||
type="text"
|
||||
icon="Download"
|
||||
:icon="row.shelfStatus == 1 ? `Download` : `Upload`"
|
||||
@click="handleShelf(row)"
|
||||
>{{ row.shelfStatus == 1 ? "下架" : "上架" }}</el-button
|
||||
>
|
||||
|
@ -136,9 +136,9 @@
|
||||
></el-input>
|
||||
</el-form-item>
|
||||
<!-- //TODO:上传论文添加字段 -->
|
||||
<el-form-item label="上传论文:" prop="paper">
|
||||
<el-form-item label="上传论文:" prop="fileUrl">
|
||||
<FileUpload
|
||||
v-model="form.paper"
|
||||
v-model="form.fileUrl"
|
||||
:limit="1"
|
||||
:fileType="['docx', 'doc', 'pdf']"
|
||||
></FileUpload>
|
||||
|
@ -20,6 +20,7 @@ import {
|
||||
expertAchievementInfo,
|
||||
updateExpertAchievement,
|
||||
} from "@/api/admin/expert/achievement";
|
||||
import tab from "@/plugins/tab";
|
||||
import { ElMessage } from "element-plus";
|
||||
import { reactive, ref, toRefs } from "vue";
|
||||
import { useRoute, useRouter } from "vue-router";
|
||||
@ -27,7 +28,7 @@ import ReleaseForm from "../components/ReleaseForm";
|
||||
const labelWidth = 140;
|
||||
|
||||
const data = reactive({
|
||||
form: { mode: 1 },
|
||||
form: { mode: 1, shelfStatus: "2" },
|
||||
});
|
||||
const formData = reactive({});
|
||||
|
||||
@ -38,6 +39,8 @@ const releaseFormRef = ref();
|
||||
const { id } = route.query;
|
||||
|
||||
if (id) {
|
||||
const obj = Object.assign({}, route, { title: "修改成果" });
|
||||
tab.updatePage(obj);
|
||||
expertAchievementInfo({ id }).then((resp) => {
|
||||
form.value = resp.data;
|
||||
form.value.keywords =
|
||||
@ -52,12 +55,13 @@ const submitForm = async (status) => {
|
||||
if (id) {
|
||||
await updateExpertAchievement({ ...form.value, status });
|
||||
ElMessage.success("修改成果成功");
|
||||
router.back();
|
||||
// router.back();
|
||||
} else {
|
||||
await insertAchievement({ ...form.value, status });
|
||||
ElMessage.success("新增成果成功");
|
||||
router.back();
|
||||
// router.back();
|
||||
}
|
||||
tab.closeOpenPage({ path: "/technology/achievement" });
|
||||
} else {
|
||||
console.log("校验未通过");
|
||||
}
|
||||
|
@ -187,13 +187,19 @@
|
||||
<!-- //TODO:添加项目简介字段 -->
|
||||
<el-row>
|
||||
<el-col :span="24">
|
||||
<el-form-item label="项目简介:" prop="kind">
|
||||
<el-input
|
||||
<el-form-item label="项目简介:" prop="introduce">
|
||||
<WangEditor
|
||||
v-model="form.introduce"
|
||||
width="100%"
|
||||
min-height="150px"
|
||||
@blur="researchRef.validateField(`introduce`)"
|
||||
></WangEditor>
|
||||
<!-- <el-input
|
||||
type="textarea"
|
||||
v-model="form.kind"
|
||||
placeholder="请输入项目简介"
|
||||
:autosize="{ minRows: 8, maxRows: 16 }"
|
||||
/>
|
||||
/> -->
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
</el-row>
|
||||
@ -259,6 +265,9 @@ const data = reactive({
|
||||
director: [
|
||||
{ required: true, message: "课题负责人不能为空", trigger: "blur" },
|
||||
],
|
||||
introduce: [
|
||||
{ required: true, message: "项目简介不能为空", trigger: "blur" },
|
||||
],
|
||||
},
|
||||
});
|
||||
|
||||
|
@ -181,7 +181,10 @@ watch(
|
||||
() => modelValue.value.province,
|
||||
(val) => {
|
||||
console.log("changed province");
|
||||
getCityListByProvinceId(val);
|
||||
val && getCityListByProvinceId(val);
|
||||
},
|
||||
{
|
||||
immediate: true,
|
||||
}
|
||||
);
|
||||
|
||||
@ -189,7 +192,10 @@ watch(
|
||||
() => modelValue.value.city,
|
||||
(val) => {
|
||||
console.log("changed city");
|
||||
getAreaListByCityId(val);
|
||||
val && getAreaListByCityId(val);
|
||||
},
|
||||
{
|
||||
immediate: true,
|
||||
}
|
||||
);
|
||||
getProvinceList();
|
||||
|
@ -7,7 +7,8 @@
|
||||
>
|
||||
<div class="form_title" v-if="showTitle">基本信息</div>
|
||||
|
||||
<el-row v-if="isAdd">
|
||||
<!-- <el-row v-if="isAdd"> -->
|
||||
<el-row>
|
||||
<el-col :span="24">
|
||||
<el-form-item label="企业logo:">
|
||||
<ImageUpload v-model="modelValue.image" :limit="1" />
|
||||
@ -153,7 +154,7 @@
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
</el-row>
|
||||
<el-row v-if="isAdd">
|
||||
<!-- <el-row v-if="isAdd">
|
||||
<el-col :span="24">
|
||||
<el-form-item label="营业执照:" prop="license">
|
||||
<ImageUpload
|
||||
@ -163,7 +164,7 @@
|
||||
/>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
</el-row>
|
||||
</el-row> -->
|
||||
|
||||
<el-row>
|
||||
<el-col :span="24">
|
||||
|
@ -173,13 +173,19 @@
|
||||
<el-row>
|
||||
<el-col :span="24">
|
||||
<el-form-item label="个人简介:" prop="introduce">
|
||||
<el-input
|
||||
<!-- <el-input
|
||||
v-model="modelValue.introduce"
|
||||
placeholder="请输入研究方向、核心技术及产品、代表专利和论文、承担科研项目名称及项目摘要"
|
||||
type="textarea"
|
||||
:autosize="{ minRows: 16, maxRows: 20 }"
|
||||
show-word-limit
|
||||
/>
|
||||
/> -->
|
||||
<WangEditor
|
||||
v-model="modelValue.introduce"
|
||||
width="100%"
|
||||
min-height="150px"
|
||||
@blur="formRef.validateField(`introduce`)"
|
||||
></WangEditor>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
</el-row>
|
||||
|
@ -10,10 +10,10 @@
|
||||
<div class="tab">
|
||||
<div
|
||||
v-for="(v, index) in state.tabList"
|
||||
:style="v == '找实验室' ? `display:none` : ''"
|
||||
:class="{ active: state.tabIndex == index }"
|
||||
@click="switchTab(index)"
|
||||
>
|
||||
<!-- :style="v == '找实验室' ? `display:none` : ''" -->
|
||||
{{ v }}
|
||||
</div>
|
||||
</div>
|
||||
@ -28,7 +28,7 @@
|
||||
v-model.trim="queryParams.keyword"
|
||||
placeholder="请输入检索词"
|
||||
>
|
||||
<template #suffix>
|
||||
<template #suffix v-if="false">
|
||||
<el-form-item prop="queryType">
|
||||
<el-select
|
||||
v-model="queryParams.queryType"
|
||||
@ -166,8 +166,15 @@ const queryTypeList = [
|
||||
value: "1",
|
||||
label: "通过成果名称搜索",
|
||||
},
|
||||
{
|
||||
value: "2",
|
||||
label: "通过成果简介搜索",
|
||||
},
|
||||
],
|
||||
[
|
||||
{ value: "1", label: "通过实验室名称搜索" },
|
||||
{ value: "2", label: "通过实验室简介搜索" },
|
||||
],
|
||||
[],
|
||||
[
|
||||
{ value: "1", label: "通过标题搜索" },
|
||||
{ value: "2", label: "通过摘要搜索" },
|
||||
@ -179,11 +186,20 @@ const queryTypeList = [
|
||||
{ value: "2", label: "通过个人简介搜索" },
|
||||
{ value: "3", label: "通过关键词搜索" },
|
||||
],
|
||||
[{ value: "1", label: "通过标题搜索" }],
|
||||
[
|
||||
{ value: "1", label: "通过需求标题搜索" },
|
||||
{ value: "2", label: "通过需求简介搜索" },
|
||||
],
|
||||
[],
|
||||
[
|
||||
{ value: "1", label: "通过实验室名称搜索" },
|
||||
{ value: "2", label: "通过实验室简介搜索" },
|
||||
],
|
||||
// [{ value: "1", label: "通过标题搜索" }],
|
||||
];
|
||||
|
||||
const handleDetail = async (mode, keyword, queryType) => {
|
||||
console.log(mode);
|
||||
await queryRef.value.validate();
|
||||
const routeData = router.resolve({
|
||||
path: `/searchList/${mode}`,
|
||||
@ -232,15 +248,15 @@ const switchTab = (index) => {
|
||||
queryRef.value.resetFields("queryType");
|
||||
};
|
||||
|
||||
watch(
|
||||
() => state.tabIndex,
|
||||
(val) => {
|
||||
console.log(val);
|
||||
// return [2, 0][val];
|
||||
queryParams.queryType = ["2", "1", "0", "2", "2", "1"][val];
|
||||
},
|
||||
{ immediate: true }
|
||||
);
|
||||
// watch(
|
||||
// () => state.tabIndex,
|
||||
// (val) => {
|
||||
// console.log(val);
|
||||
// // return [2, 0][val];
|
||||
// queryParams.queryType = ["2", "2", "2", "2", "2", "2"][val];
|
||||
// },
|
||||
// { immediate: true }
|
||||
// );
|
||||
onMounted(() => {
|
||||
banner({ locals: "首页背景" }).then((resp) => {
|
||||
// console.log(resp);
|
||||
|
@ -20,23 +20,23 @@
|
||||
<div class="b">暂无</div>
|
||||
</div>
|
||||
</div>
|
||||
<!-- <div class="rightBox">
|
||||
<div class="rightBox">
|
||||
<div class="head">
|
||||
<div class="a">领域</div>
|
||||
<div class="b">专家数量</div>
|
||||
</div>
|
||||
<div
|
||||
v-if="Object.keys(getIndustry(snapTree)).length > 0"
|
||||
v-for="(v, k) in getIndustry(snapTree)"
|
||||
v-if="Object.keys(industryTree).length > 0"
|
||||
v-for="(v, k) in industryTree"
|
||||
>
|
||||
<div class="a" :title="k">{{ k }}</div>
|
||||
<div class="b">{{ v }}</div>
|
||||
<div class="b">{{ v ?? 0 }}</div>
|
||||
</div>
|
||||
<div v-else>
|
||||
<div class="a">暂无</div>
|
||||
<div class="b">暂无</div>
|
||||
</div>
|
||||
</div> -->
|
||||
</div>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
@ -50,13 +50,14 @@ import {
|
||||
// return;
|
||||
// console.log(echarts);
|
||||
import * as echarts from "echarts";
|
||||
import { ElMessage } from "element-plus";
|
||||
// import { ElMessage } from "element-plus";
|
||||
|
||||
const { proxy } = getCurrentInstance();
|
||||
const loading = shallowRef(true);
|
||||
|
||||
let treeData = [];
|
||||
let treeData = {};
|
||||
const snapTree = shallowRef({});
|
||||
const industryTree = shallowRef({});
|
||||
|
||||
const searchRegionData = async (code, level) => {
|
||||
if (level == "province") {
|
||||
@ -71,8 +72,9 @@ const searchRegionData = async (code, level) => {
|
||||
data = snapTree.value;
|
||||
} else {
|
||||
const resp = await countExpertByCity(provcode);
|
||||
snapTree.value = resp.data;
|
||||
data = resp.data;
|
||||
snapTree.value = resp.count;
|
||||
industryTree.value = resp.industry ?? {};
|
||||
data = resp.count;
|
||||
}
|
||||
return data.find((item) => item.code == code) || false;
|
||||
} else if (level == "city") {
|
||||
@ -86,16 +88,20 @@ const searchRegionData = async (code, level) => {
|
||||
data = snapTree.value;
|
||||
} else {
|
||||
const resp = await countExpertByArea(ctcode);
|
||||
snapTree.value = resp.data;
|
||||
data = resp.data;
|
||||
snapTree.value = resp.count;
|
||||
industryTree.value = resp.industry ?? {};
|
||||
data = resp.count;
|
||||
}
|
||||
return data.find((item) => item.code == code) || false;
|
||||
} else {
|
||||
if (treeData.length) {
|
||||
return treeData.find((item) => item.code == code) || false;
|
||||
if (Object.keys(treeData).length) {
|
||||
industryTree.value = treeData.industry ?? {};
|
||||
snapTree.value = treeData.count ?? {};
|
||||
return treeData.count.find((item) => item.code == code) || false;
|
||||
} else {
|
||||
const { data } = await countExpertByProvince();
|
||||
return data.find((item) => item.code == code) || false;
|
||||
const { count, industry } = await countExpertByProvince();
|
||||
industryTree.value = industry ?? {};
|
||||
return count.find((item) => item.code == code) || false;
|
||||
}
|
||||
}
|
||||
};
|
||||
@ -123,33 +129,35 @@ function deepFindTree(code, tree) {
|
||||
return snap;
|
||||
}
|
||||
|
||||
function getIndustry(object) {
|
||||
let snap = {};
|
||||
for (const key in object) {
|
||||
if (Object.hasOwnProperty.call(object, key)) {
|
||||
const element = object[key];
|
||||
if (element["industry"] != null) {
|
||||
for (const ek in element["industry"]) {
|
||||
if (Object.hasOwnProperty.call(element["industry"], ek)) {
|
||||
const ele = element["industry"][ek];
|
||||
if (!Object.hasOwnProperty.call(snap, ek)) {
|
||||
snap[ek] = 0;
|
||||
}
|
||||
snap[ek] += ele;
|
||||
}
|
||||
}
|
||||
// for (let index = 0; index < element['industry'].length; index++) {
|
||||
// const ele = element['industry'][index];
|
||||
// if(Object.hasOwnProperty.call(snap, ele)) {
|
||||
const getIndustry = () => {};
|
||||
|
||||
// }
|
||||
// function getIndustry(object) {
|
||||
// let snap = {};
|
||||
// for (const key in object) {
|
||||
// if (Object.hasOwnProperty.call(object, key)) {
|
||||
// const element = object[key];
|
||||
// if (element["industry"] != null) {
|
||||
// for (const ek in element["industry"]) {
|
||||
// if (Object.hasOwnProperty.call(element["industry"], ek)) {
|
||||
// const ele = element["industry"][ek];
|
||||
// if (!Object.hasOwnProperty.call(snap, ek)) {
|
||||
// snap[ek] = 0;
|
||||
// }
|
||||
// snap[ek] += ele;
|
||||
// }
|
||||
// }
|
||||
// // for (let index = 0; index < element['industry'].length; index++) {
|
||||
// // const ele = element['industry'][index];
|
||||
// // if(Object.hasOwnProperty.call(snap, ele)) {
|
||||
|
||||
// }
|
||||
}
|
||||
}
|
||||
}
|
||||
return snap;
|
||||
}
|
||||
// // }
|
||||
|
||||
// // }
|
||||
// }
|
||||
// }
|
||||
// }
|
||||
// return snap;
|
||||
// }
|
||||
|
||||
const state = reactive({
|
||||
loading: false,
|
||||
@ -190,8 +198,9 @@ onMounted(() => {
|
||||
// 数据接口
|
||||
countExpertByProvince().then((resp) => {
|
||||
// const data = formatData(resp.data);
|
||||
treeData = resp.data;
|
||||
snapTree.value = resp.data;
|
||||
treeData = resp;
|
||||
snapTree.value = resp.count;
|
||||
industryTree.value = resp.industry ?? {};
|
||||
loading.value = false;
|
||||
});
|
||||
|
||||
@ -228,7 +237,7 @@ function goBack() {
|
||||
state.district.search("中国", async (status, result) => {
|
||||
if (status == "complete") {
|
||||
await getData(result.districtList[0], "", 100000);
|
||||
snapTree.value = formatData(treeData);
|
||||
snapTree.value = formatData(treeData.count);
|
||||
}
|
||||
});
|
||||
}
|
||||
@ -243,7 +252,8 @@ async function echartsMapClick(params) {
|
||||
}
|
||||
if (params.data.level == "street") return; //此处的params.data为state.mapData里的数据
|
||||
console.log(params.data.level, params.data.cityCode);
|
||||
let snap = await searchRegionData(params.data.cityCode, params.data.level);
|
||||
// let snap =
|
||||
await searchRegionData(params.data.cityCode, params.data.level);
|
||||
// snapTree.value = {};
|
||||
// console.log(snap, "-----------****---------");
|
||||
// ElMessage.success(snap);
|
||||
|
@ -1,6 +1,6 @@
|
||||
<template>
|
||||
<div class="box3" v-loading="loading">
|
||||
<div class="tit">专利与成果分布地图</div>
|
||||
<div class="tit">技术分布地图</div>
|
||||
<div v-if="state.isShowGoBack" class="close-back" @click="goBack">
|
||||
<img src="./img/back_button.png" />
|
||||
</div>
|
||||
@ -20,14 +20,14 @@
|
||||
<div class="b">暂无</div>
|
||||
</div>
|
||||
</div>
|
||||
<!-- <div class="rightBox">
|
||||
<div class="rightBox">
|
||||
<div class="head">
|
||||
<div class="a">领域</div>
|
||||
<div class="b">成果数量</div>
|
||||
</div>
|
||||
<div
|
||||
v-if="Object.keys(getIndustry(snapTree)).length > 0"
|
||||
v-for="(v, k) in getIndustry(snapTree)"
|
||||
v-if="Object.keys(industryTree).length > 0"
|
||||
v-for="(v, k) in industryTree"
|
||||
>
|
||||
<div class="a" :title="k">{{ k }}</div>
|
||||
<div class="b">{{ v }}</div>
|
||||
@ -36,7 +36,7 @@
|
||||
<div class="a">暂无</div>
|
||||
<div class="b">暂无</div>
|
||||
</div>
|
||||
</div> -->
|
||||
</div>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
@ -52,8 +52,9 @@ import * as echarts from "echarts";
|
||||
|
||||
const { proxy } = getCurrentInstance();
|
||||
const loading = shallowRef(true);
|
||||
let treeData = [];
|
||||
const snapTree = shallowRef([]);
|
||||
let treeData = {};
|
||||
const snapTree = shallowRef({});
|
||||
const industryTree = shallowRef({});
|
||||
|
||||
const searchRegionData = async (code, level) => {
|
||||
if (level == "province") {
|
||||
@ -68,8 +69,9 @@ const searchRegionData = async (code, level) => {
|
||||
data = snapTree.value;
|
||||
} else {
|
||||
const resp = await countAchievementByCity(provcode);
|
||||
snapTree.value = resp.data;
|
||||
data = resp.data;
|
||||
snapTree.value = resp.count;
|
||||
industryTree.value = resp.industry ?? {};
|
||||
data = resp.count;
|
||||
}
|
||||
return data.find((item) => item.code == code) || false;
|
||||
} else if (level == "city") {
|
||||
@ -83,16 +85,20 @@ const searchRegionData = async (code, level) => {
|
||||
data = snapTree.value;
|
||||
} else {
|
||||
const resp = await countAchievementByArea(ctcode);
|
||||
snapTree.value = resp.data;
|
||||
data = resp.data;
|
||||
snapTree.value = resp.count;
|
||||
industryTree.value = resp.industry ?? {};
|
||||
data = resp.count;
|
||||
}
|
||||
return data.find((item) => item.code == code) || false;
|
||||
} else {
|
||||
if (treeData.length) {
|
||||
return treeData.find((item) => item.code == code) || false;
|
||||
if (Object.keys(treeData).length) {
|
||||
industryTree.value = treeData.industry ?? {};
|
||||
snapTree.value = treeData.count ?? {};
|
||||
return treeData.count.find((item) => item.code == code) || false;
|
||||
} else {
|
||||
const { data } = await countAchievementByProvince();
|
||||
return data.find((item) => item.code == code) || false;
|
||||
const { count, industry } = await countAchievementByProvince();
|
||||
industryTree.value = industry ?? {};
|
||||
return count.find((item) => item.code == code) || false;
|
||||
}
|
||||
}
|
||||
};
|
||||
@ -174,10 +180,11 @@ const state = reactive({
|
||||
|
||||
onMounted(() => {
|
||||
// 数据接口
|
||||
const res = [];
|
||||
// const res = [];
|
||||
countAchievementByProvince().then((resp) => {
|
||||
treeData = resp.data;
|
||||
snapTree.value = resp.data;
|
||||
treeData = resp;
|
||||
snapTree.value = resp.count;
|
||||
industryTree.value = resp.industry ?? {};
|
||||
loading.value = false;
|
||||
});
|
||||
|
||||
@ -214,7 +221,8 @@ function goBack() {
|
||||
state.district.search("中国", async (status, result) => {
|
||||
if (status == "complete") {
|
||||
await getData(result.districtList[0], "", 100000);
|
||||
snapTree.value = treeData;
|
||||
// snapTree.value = treeData.count;
|
||||
snapTree.value = treeData.count;
|
||||
}
|
||||
});
|
||||
}
|
||||
|
@ -20,14 +20,14 @@
|
||||
<div class="b">暂无</div>
|
||||
</div>
|
||||
</div>
|
||||
<!-- <div class="rightBox">
|
||||
<div class="rightBox">
|
||||
<div class="head">
|
||||
<div class="a">领域</div>
|
||||
<div class="b">需求数量</div>
|
||||
</div>
|
||||
<div
|
||||
v-if="Object.keys(getIndustry(snapTree)).length > 0"
|
||||
v-for="(v, k) in getIndustry(snapTree)"
|
||||
v-if="Object.keys(industryTree).length > 0"
|
||||
v-for="(v, k) in industryTree"
|
||||
>
|
||||
<div class="a" :title="k">{{ k }}</div>
|
||||
<div class="b">{{ v }}</div>
|
||||
@ -36,7 +36,7 @@
|
||||
<div class="a">暂无</div>
|
||||
<div class="b">暂无</div>
|
||||
</div>
|
||||
</div> -->
|
||||
</div>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
@ -52,8 +52,10 @@ import {
|
||||
|
||||
const { proxy } = getCurrentInstance();
|
||||
const loading = shallowRef(true);
|
||||
let treeData = [];
|
||||
const snapTree = shallowRef([]);
|
||||
|
||||
let treeData = {};
|
||||
const snapTree = shallowRef({});
|
||||
const industryTree = shallowRef({});
|
||||
|
||||
const searchRegionData = async (code, level) => {
|
||||
if (level == "province") {
|
||||
@ -67,8 +69,9 @@ const searchRegionData = async (code, level) => {
|
||||
data = snapTree.value;
|
||||
} else {
|
||||
const resp = await countDemandByCity(provcode);
|
||||
snapTree.value = resp.data;
|
||||
data = resp.data;
|
||||
snapTree.value = resp.count;
|
||||
industryTree.value = resp.industry ?? {};
|
||||
data = resp.count;
|
||||
}
|
||||
return data.find((item) => item.code == code) || false;
|
||||
} else if (level == "city") {
|
||||
@ -82,16 +85,20 @@ const searchRegionData = async (code, level) => {
|
||||
data = snapTree.value;
|
||||
} else {
|
||||
const resp = await countDemandByArea(ctcode);
|
||||
snapTree.value = resp.data;
|
||||
data = resp.data;
|
||||
snapTree.value = resp.count;
|
||||
industryTree.value = resp.industry ?? {};
|
||||
data = resp.count;
|
||||
}
|
||||
return data.find((item) => item.code == code) || false;
|
||||
} else {
|
||||
if (treeData.length) {
|
||||
return treeData.find((item) => item.code == code) || false;
|
||||
if (Object.keys(treeData).length) {
|
||||
industryTree.value = treeData.industry ?? {};
|
||||
snapTree.value = treeData.count ?? {};
|
||||
return treeData.count.find((item) => item.code == code) || false;
|
||||
} else {
|
||||
const { data } = await countDemandByProvince();
|
||||
return data.find((item) => item.code == code) || false;
|
||||
const { count, industry } = await countDemandByProvince();
|
||||
industryTree.value = industry ?? {};
|
||||
return count.find((item) => item.code == code) || false;
|
||||
}
|
||||
}
|
||||
};
|
||||
@ -173,10 +180,10 @@ const state = reactive({
|
||||
|
||||
onMounted(() => {
|
||||
// 数据接口
|
||||
const res = { code: 200, message: "ok", data: {} };
|
||||
countDemandByProvince().then((res) => {
|
||||
treeData = res.data;
|
||||
snapTree.value = res.data;
|
||||
countDemandByProvince().then((resp) => {
|
||||
treeData = resp;
|
||||
snapTree.value = resp.count;
|
||||
industryTree.value = resp.industry ?? {};
|
||||
loading.value = false;
|
||||
});
|
||||
// let echartsDomList = document.querySelectorAll('.echartsDom');
|
||||
@ -223,7 +230,7 @@ function goBack() {
|
||||
state.district.search("中国", async (status, result) => {
|
||||
if (status == "complete") {
|
||||
await getData(result.districtList[0], "", 100000);
|
||||
snapTree.value = treeData;
|
||||
snapTree.value = treeData.count;
|
||||
}
|
||||
});
|
||||
}
|
||||
|
@ -20,14 +20,14 @@
|
||||
<div class="b">暂无</div>
|
||||
</div>
|
||||
</div>
|
||||
<!-- <div class="rightBox">
|
||||
<div class="rightBox">
|
||||
<div class="head">
|
||||
<div class="a">领域</div>
|
||||
<div class="b">企业数量</div>
|
||||
</div>
|
||||
<div
|
||||
v-if="Object.keys(getIndustry(snapTree)).length > 0"
|
||||
v-for="(v, k) in getIndustry(snapTree)"
|
||||
v-if="Object.keys(industryTree).length > 0"
|
||||
v-for="(v, k) in industryTree"
|
||||
>
|
||||
<div class="a" :title="k">{{ k }}</div>
|
||||
<div class="b">{{ v }}</div>
|
||||
@ -36,7 +36,7 @@
|
||||
<div class="a">暂无</div>
|
||||
<div class="b">暂无</div>
|
||||
</div>
|
||||
</div> -->
|
||||
</div>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
@ -52,8 +52,9 @@ import {
|
||||
|
||||
const { proxy } = getCurrentInstance();
|
||||
const loading = shallowRef(true);
|
||||
let treeData = [];
|
||||
const snapTree = shallowRef([]);
|
||||
let treeData = {};
|
||||
const snapTree = shallowRef({});
|
||||
const industryTree = shallowRef({});
|
||||
|
||||
const searchRegionData = async (code, level) => {
|
||||
if (level == "province") {
|
||||
@ -68,8 +69,9 @@ const searchRegionData = async (code, level) => {
|
||||
data = snapTree.value;
|
||||
} else {
|
||||
const resp = await countEnterpriseByCity(provcode);
|
||||
snapTree.value = resp.data;
|
||||
data = resp.data;
|
||||
snapTree.value = resp.count;
|
||||
industryTree.value = resp.industry ?? {};
|
||||
data = resp.count;
|
||||
}
|
||||
return data.find((item) => item.code == code) || false;
|
||||
} else if (level == "city") {
|
||||
@ -83,16 +85,20 @@ const searchRegionData = async (code, level) => {
|
||||
data = snapTree.value;
|
||||
} else {
|
||||
const resp = await countEnterpriseByArea(ctcode);
|
||||
snapTree.value = resp.data;
|
||||
data = resp.data;
|
||||
snapTree.value = resp.count;
|
||||
industryTree.value = resp.industry ?? {};
|
||||
data = resp.count;
|
||||
}
|
||||
return data.find((item) => item.code == code) || false;
|
||||
} else {
|
||||
if (treeData.length) {
|
||||
return treeData.find((item) => item.code == code) || false;
|
||||
if (Object.keys(treeData).length) {
|
||||
industryTree.value = treeData.industry ?? {};
|
||||
snapTree.value = treeData.count ?? {};
|
||||
return treeData.count.find((item) => item.code == code) || false;
|
||||
} else {
|
||||
const { data } = await countEnterpriseByProvince();
|
||||
return data.find((item) => item.code == code) || false;
|
||||
const { count, industry } = await countEnterpriseByProvince();
|
||||
industryTree.value = industry ?? {};
|
||||
return count.find((item) => item.code == code) || false;
|
||||
}
|
||||
}
|
||||
};
|
||||
@ -177,8 +183,9 @@ onMounted(() => {
|
||||
|
||||
countEnterpriseByProvince().then((resp) => {
|
||||
// if (200 == res.code) {
|
||||
treeData = resp.data;
|
||||
snapTree.value = resp.data;
|
||||
treeData = resp;
|
||||
snapTree.value = resp.count;
|
||||
industryTree.value = resp.industry ?? {};
|
||||
loading.value = false;
|
||||
// }
|
||||
});
|
||||
@ -226,7 +233,7 @@ function goBack() {
|
||||
state.district.search("中国", async (status, result) => {
|
||||
if (status == "complete") {
|
||||
await getData(result.districtList[0], "", 100000);
|
||||
snapTree.value = treeData;
|
||||
snapTree.value = treeData.count;
|
||||
}
|
||||
});
|
||||
}
|
||||
|
@ -36,6 +36,50 @@
|
||||
<div class="pointTit">成果简介</div>
|
||||
</div>
|
||||
<div class="html" v-html="state.expertDetail.description"></div>
|
||||
<div style="padding: 20px 0">
|
||||
<div class="pointTit">成果领先性</div>
|
||||
</div>
|
||||
<section>
|
||||
<div>
|
||||
{{
|
||||
leadOptions.find(
|
||||
(el) => el.key == state.expertDetail.leadStandard
|
||||
)?.value
|
||||
}}
|
||||
</div>
|
||||
</section>
|
||||
<div style="padding: 20px 0">
|
||||
<div class="pointTit">合作模式</div>
|
||||
</div>
|
||||
<section>
|
||||
<div>
|
||||
{{
|
||||
cooperationOptions.find(
|
||||
(el) => el.key == state.expertDetail.cooperationMode
|
||||
)?.value
|
||||
}}
|
||||
</div>
|
||||
</section>
|
||||
<div style="padding: 20px 0">
|
||||
<div class="pointTit">应用客户</div>
|
||||
</div>
|
||||
<section>
|
||||
<div>
|
||||
{{ state.expertDetail.customer }}
|
||||
</div>
|
||||
</section>
|
||||
<div style="padding: 20px 0">
|
||||
<div class="pointTit">所在地</div>
|
||||
</div>
|
||||
<section>
|
||||
{{ state.localtion }}
|
||||
</section>
|
||||
<div style="padding: 20px 0">
|
||||
<div class="pointTit">所属单位</div>
|
||||
</div>
|
||||
<section>
|
||||
{{ state.expertDetail.unit }}
|
||||
</section>
|
||||
</div>
|
||||
</div>
|
||||
<div class="r">
|
||||
@ -55,14 +99,18 @@ import loadMore from "./components/loadMore.vue";
|
||||
import request from "@/utils/request";
|
||||
// import { onMounted } from "vue";
|
||||
import searchContainer from "./components/searchContainer.vue";
|
||||
|
||||
import wordcloud from "./components/wordcloud.vue";
|
||||
import productItem from "./components/productItem.vue";
|
||||
import { searchAchievementDetail } from "../../../api/website/home";
|
||||
import { searchAchievementDetail } from "@/api/website/home";
|
||||
import { useRoute, useRouter } from "vue-router";
|
||||
import { reactive, ref } from "vue";
|
||||
import docking from "./components/docking.vue";
|
||||
import { getCity } from "@/utils/city";
|
||||
import { leadOptions, cooperationOptions } from "@/utils/parameter";
|
||||
const showDocking = ref(false);
|
||||
const loading = ref(true);
|
||||
// import {lead}
|
||||
const state = reactive({
|
||||
pageNum: 1,
|
||||
pageSize: 4,
|
||||
@ -152,10 +200,15 @@ function getDataList() {
|
||||
if (!id) return;
|
||||
searchAchievementDetail(id)
|
||||
// achievementDetail(id)
|
||||
.then((res) => {
|
||||
.then(async (resp) => {
|
||||
// if (200 == res.code) {
|
||||
console.log(res.data);
|
||||
state.expertDetail = res.data;
|
||||
console.log(resp.data);
|
||||
state.expertDetail = resp.data;
|
||||
state.localtion = await getCity(
|
||||
resp.data.province,
|
||||
resp.data.city,
|
||||
resp.data.district
|
||||
);
|
||||
loading.value = false;
|
||||
// }
|
||||
});
|
||||
|
@ -1,141 +1,178 @@
|
||||
<!-- to do 实验室后台模块未开发 2022/02/17 -->
|
||||
<template>
|
||||
<div class="box">
|
||||
<div class="wrap">
|
||||
<div class="img">
|
||||
<!-- <img :src="data.image" alt /> -->
|
||||
<img src="https://t7.baidu.com/it/u=1951548898,3927145&fm=193&f=GIF" />
|
||||
</div>
|
||||
<div class="content">
|
||||
<div class="tit" @click="handleDetail(data.id)">{{ data.title }}</div>
|
||||
<slot name="des" />
|
||||
<div class="box">
|
||||
<div class="wrap">
|
||||
<div class="type">实验室</div>
|
||||
<div class="content">
|
||||
<div class="tit" @click="handleDetail(data.id)">{{ data.name }}</div>
|
||||
<slot name="des" />
|
||||
|
||||
<div v-if="data.industrys" class="line">
|
||||
所属领域:
|
||||
<span>{{ data.industrys[data.industrys.length - 1] }}</span>
|
||||
</div>
|
||||
<div class="line">
|
||||
依托管理部门:
|
||||
<span>{{ data.mode_title }}</span>
|
||||
</div>
|
||||
<div class="line">
|
||||
<div v-if="data.industryStr" class="line">
|
||||
所属领域:
|
||||
<span>{{ data.industryStr }}</span>
|
||||
</div>
|
||||
<div class="line">
|
||||
网址:
|
||||
<span>{{ data.url }}</span>
|
||||
</div>
|
||||
<div class="line">
|
||||
所属院所或高校:
|
||||
<span>{{ data.school }}</span>
|
||||
</div>
|
||||
<!-- <div class="line">
|
||||
合作模式:
|
||||
<span>{{ data.mode_title }}</span>
|
||||
</div>
|
||||
<div class="line">
|
||||
技术成熟度:
|
||||
<span>{{ data.maturity_title }}</span>
|
||||
</div>
|
||||
</div>
|
||||
<div>
|
||||
<div class="keywords">
|
||||
<wordcloud v-if="data.keywords" :data="createdData(data.customers)"></wordcloud>
|
||||
</div>
|
||||
<collectAndVisit :is_collect="data.is_collect" :collect_count="data.collect_count" :visit_count="data.visit_count" :object_id="data.id" :kind="1005"/>
|
||||
</div>
|
||||
</div> -->
|
||||
</div>
|
||||
<div>
|
||||
<div class="keywords">
|
||||
<wordcloud
|
||||
v-if="data.keyword"
|
||||
:data="createdData(data.keyword)"
|
||||
></wordcloud>
|
||||
</div>
|
||||
<!-- <collectAndVisit
|
||||
:is_collect="data.is_collect"
|
||||
:collect_count="data.collect_count"
|
||||
:visit_count="data.visit_count"
|
||||
:object_id="data.id"
|
||||
:kind="1005"
|
||||
/> -->
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script setup>
|
||||
import wordcloud from './wordcloud.vue'
|
||||
import collectAndVisit from './collectAndVisit.vue'
|
||||
import wordcloud from "./wordcloud.vue";
|
||||
import collectAndVisit from "./collectAndVisit.vue";
|
||||
import { useRoute, useRouter } from "vue-router";
|
||||
const router = useRouter();
|
||||
const route = useRoute();
|
||||
const props = defineProps({
|
||||
data: {
|
||||
type: Object,
|
||||
required: true,
|
||||
},
|
||||
data: {
|
||||
type: Object,
|
||||
required: true,
|
||||
},
|
||||
});
|
||||
|
||||
function handleDetail (id) {
|
||||
let routeData = router.resolve({ path: `/searchList/1/detail/${id}` });
|
||||
window.open(routeData.href, '_blank');
|
||||
function handleDetail(id) {
|
||||
let routeData = router.resolve({
|
||||
path: `/searchList/lab/detail/${id}`,
|
||||
query: {
|
||||
keyword: route.query.keyword,
|
||||
queryType: route.query.queryType,
|
||||
},
|
||||
});
|
||||
// window.open(routeData.href, "_blank");
|
||||
router.push(routeData);
|
||||
}
|
||||
|
||||
function createdData (arr) {
|
||||
let l = [];
|
||||
let snap = JSON.parse(JSON.stringify(arr))
|
||||
snap.map(e => {
|
||||
l.push({ name: e, value: 30 })
|
||||
return { name: e, value: 30 }
|
||||
})
|
||||
return l;
|
||||
function createdData(arr) {
|
||||
let l = [];
|
||||
arr = arr ? arr.split(",") : [];
|
||||
let snap = JSON.parse(JSON.stringify(arr));
|
||||
snap.map((e) => {
|
||||
l.push({ name: e, value: 30 });
|
||||
return { name: e, value: 30 };
|
||||
});
|
||||
return l;
|
||||
}
|
||||
|
||||
</script>
|
||||
|
||||
<style lang="scss" scoped>
|
||||
.box {
|
||||
width: 100%;
|
||||
// height: 190px;
|
||||
background: #ffffff;
|
||||
padding: 20px;
|
||||
box-sizing: border-box;
|
||||
.wrap {
|
||||
display: flex;
|
||||
flex-direction: row;
|
||||
.img {
|
||||
width: 200px;
|
||||
height: 150px;
|
||||
margin-right: 10px;
|
||||
img {
|
||||
display: block;
|
||||
margin: 0;
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
}
|
||||
}
|
||||
.keywords {
|
||||
width: 129px;
|
||||
height: 129px;
|
||||
}
|
||||
.content {
|
||||
flex: 1;
|
||||
overflow: hidden;
|
||||
|
||||
.labelList {
|
||||
overflow: hidden;
|
||||
div {
|
||||
padding: 2px 4px;
|
||||
float: left;
|
||||
background: #0054ff;
|
||||
border-radius: 4px;
|
||||
margin-right: 5px;
|
||||
margin-bottom: 5px;
|
||||
font-size: 14px;
|
||||
font-family: Source Han Sans CN;
|
||||
font-weight: 400;
|
||||
color: #ffffff;
|
||||
}
|
||||
}
|
||||
|
||||
.line {
|
||||
font-size: 16px;
|
||||
font-family: Source Han Sans CN;
|
||||
font-weight: 400;
|
||||
color: #666666;
|
||||
margin: 10px 0;
|
||||
span {
|
||||
font-size: 16px;
|
||||
font-family: Source Han Sans CN;
|
||||
font-weight: 500;
|
||||
color: #333;
|
||||
}
|
||||
}
|
||||
.tit {
|
||||
overflow: hidden;
|
||||
text-overflow: ellipsis;
|
||||
white-space: nowrap;
|
||||
width: 100%;
|
||||
font-size: 20px;
|
||||
font-family: Source Han Sans CN;
|
||||
font-weight: bold;
|
||||
color: #333333;
|
||||
overflow: hidden;
|
||||
cursor: pointer;
|
||||
}
|
||||
}
|
||||
width: 100%;
|
||||
// height: 190px;
|
||||
background: #ffffff;
|
||||
padding: 20px;
|
||||
box-sizing: border-box;
|
||||
.wrap {
|
||||
display: flex;
|
||||
flex-direction: row;
|
||||
.type {
|
||||
width: 200px;
|
||||
height: 150px;
|
||||
margin-right: 10px;
|
||||
background-color: #417bff;
|
||||
color: white;
|
||||
font-size: 36px;
|
||||
font-weight: bold;
|
||||
display: flex;
|
||||
justify-content: center;
|
||||
align-items: center;
|
||||
// img {
|
||||
// display: block;
|
||||
// margin: 0;
|
||||
// width: 100%;
|
||||
// height: 100%;
|
||||
// }
|
||||
}
|
||||
.img {
|
||||
width: 200px;
|
||||
height: 150px;
|
||||
margin-right: 10px;
|
||||
img {
|
||||
display: block;
|
||||
margin: 0;
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
}
|
||||
}
|
||||
.keywords {
|
||||
width: 129px;
|
||||
height: 129px;
|
||||
}
|
||||
.content {
|
||||
flex: 1;
|
||||
overflow: hidden;
|
||||
|
||||
.labelList {
|
||||
overflow: hidden;
|
||||
div {
|
||||
padding: 2px 4px;
|
||||
float: left;
|
||||
background: #0054ff;
|
||||
border-radius: 4px;
|
||||
margin-right: 5px;
|
||||
margin-bottom: 5px;
|
||||
font-size: 14px;
|
||||
font-family: Source Han Sans CN;
|
||||
font-weight: 400;
|
||||
color: #ffffff;
|
||||
}
|
||||
}
|
||||
|
||||
.line {
|
||||
font-size: 16px;
|
||||
font-family: Source Han Sans CN;
|
||||
font-weight: 400;
|
||||
color: #666666;
|
||||
margin: 10px 0;
|
||||
span {
|
||||
font-size: 16px;
|
||||
font-family: Source Han Sans CN;
|
||||
font-weight: 500;
|
||||
color: #333;
|
||||
}
|
||||
}
|
||||
.tit {
|
||||
overflow: hidden;
|
||||
text-overflow: ellipsis;
|
||||
white-space: nowrap;
|
||||
width: 100%;
|
||||
font-size: 20px;
|
||||
font-family: Source Han Sans CN;
|
||||
font-weight: bold;
|
||||
color: #333333;
|
||||
overflow: hidden;
|
||||
cursor: pointer;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
</style>
|
||||
</style>
|
||||
|
@ -13,7 +13,7 @@
|
||||
v-model.trim="state.currentKeyword"
|
||||
placeholder="请输入检索词"
|
||||
>
|
||||
<template #suffix>
|
||||
<template #suffix v-if="false">
|
||||
<el-form-item prop="queryType">
|
||||
<el-select
|
||||
v-model="state.queryType"
|
||||
@ -99,7 +99,10 @@ const queryTypeList = [
|
||||
label: "通过成果名称搜索",
|
||||
},
|
||||
],
|
||||
[],
|
||||
[
|
||||
{ value: "1", label: "通过实验室名称名称搜索" },
|
||||
{ value: "2", label: "通过实验室名称简介搜索" },
|
||||
],
|
||||
[
|
||||
{ value: "1", label: "通过标题搜索" },
|
||||
{ value: "2", label: "通过摘要搜索" },
|
||||
@ -112,6 +115,10 @@ const queryTypeList = [
|
||||
],
|
||||
[{ value: "1", label: "通过标题搜索" }],
|
||||
[{ value: "1", label: "通过标题搜索" }],
|
||||
[
|
||||
{ value: "1", label: "通过实验室名称搜索" },
|
||||
{ value: "2", label: "通过实验室简介搜索" },
|
||||
],
|
||||
];
|
||||
async function handleQuery() {
|
||||
// state.queryType = route.query.queryType;
|
||||
|
@ -79,10 +79,10 @@
|
||||
|
||||
<script setup>
|
||||
import WebContact from "@/components/webContact/index.vue";
|
||||
import request from "@/utils/request";
|
||||
// import request from "@/utils/request";
|
||||
import { enterpriseOptions } from "@/utils/parameter";
|
||||
import { search } from "@/api/website/home/index";
|
||||
import { onMounted } from "vue";
|
||||
// import { onMounted } from "vue";
|
||||
import searchContainer from "./components/searchContainer.vue";
|
||||
// import industrySelect from "./components/industrySelect.vue";
|
||||
import wordcloud from "./components/wordcloud.vue";
|
||||
@ -92,6 +92,7 @@ const route = useRoute();
|
||||
const router = useRouter();
|
||||
const searchResults = ref([]);
|
||||
const total = ref(0);
|
||||
|
||||
const queryParams = reactive({
|
||||
pageNum: 1,
|
||||
pageSize: 5,
|
||||
|
@ -69,7 +69,6 @@
|
||||
</div>
|
||||
</el-row>
|
||||
</div>
|
||||
|
||||
<div class="product">
|
||||
<div style="padding: 20px 0">
|
||||
<div class="pointTit">企业简介</div>
|
||||
@ -87,6 +86,25 @@
|
||||
{{ item }}
|
||||
</div>
|
||||
</section> -->
|
||||
<div style="padding: 20px 0">
|
||||
<div class="pointTit">联系人</div>
|
||||
</div>
|
||||
<section v-if="state.companyDetail.username">
|
||||
{{ state.companyDetail.username }}
|
||||
</section>
|
||||
<div style="padding: 20px 0">
|
||||
<div class="pointTit">联系方式</div>
|
||||
</div>
|
||||
<section v-if="state.companyDetail.phone">
|
||||
{{ state.companyDetail.phone }}
|
||||
</section>
|
||||
<div style="padding: 20px 0">
|
||||
<div class="pointTit">邮箱</div>
|
||||
</div>
|
||||
<section v-if="state.companyDetail.email">
|
||||
{{ state.companyDetail.email }}
|
||||
</section>
|
||||
|
||||
<div style="padding: 20px 0">
|
||||
<div class="pointTit">所属领域</div>
|
||||
</div>
|
||||
@ -103,8 +121,8 @@
|
||||
<div style="padding: 20px 0">
|
||||
<div class="pointTit">所在地</div>
|
||||
</div>
|
||||
<section v-if="state.companyDetail.address">
|
||||
{{ state.companyDetail.address }}
|
||||
<section>
|
||||
{{ state.localtion }}
|
||||
</section>
|
||||
<div style="padding: 20px 0">
|
||||
<div class="pointTit">详细地址</div>
|
||||
@ -192,15 +210,16 @@
|
||||
<script setup>
|
||||
import docking from "./components/docking.vue";
|
||||
import webContact from "@/components/webContact/index.vue";
|
||||
import request from "@/utils/request";
|
||||
// import request from "@/utils/request";
|
||||
import { searchEnterpriseDetail } from "@/api/website/home";
|
||||
import { enterpriseOptions } from "@/utils/parameter";
|
||||
import { onMounted, reactive, ref } from "vue";
|
||||
// import { onMounted, reactive, ref } from "vue";
|
||||
import searchContainer from "./components/searchContainer.vue";
|
||||
import wordcloud from "./components/wordcloud.vue";
|
||||
import productItem from "./components/productItem.vue";
|
||||
// import productItem from "./components/productItem.vue";
|
||||
import { useRoute, useRouter } from "vue-router";
|
||||
import { search } from "../../../api/website/home";
|
||||
import { getCity } from "../../../utils/city";
|
||||
const router = useRouter();
|
||||
const route = useRoute();
|
||||
const loading = ref(true);
|
||||
@ -212,6 +231,9 @@ const state = reactive({
|
||||
val: 3,
|
||||
companyDetail: {},
|
||||
companyProduct: [],
|
||||
// 获取所在地
|
||||
localtion: "",
|
||||
// const location = ref("");
|
||||
arr: [
|
||||
{
|
||||
name: "Cat",
|
||||
@ -224,36 +246,6 @@ const state = reactive({
|
||||
],
|
||||
});
|
||||
|
||||
// 建议 列表前4条
|
||||
function recommend() {
|
||||
return request({
|
||||
url: "/v1/search",
|
||||
method: "post",
|
||||
data: {
|
||||
mode: 1,
|
||||
pageNum: state.pageNum,
|
||||
pageSize: state.pageSize,
|
||||
keyword: state.keyword,
|
||||
},
|
||||
});
|
||||
}
|
||||
|
||||
// 公司详情
|
||||
function company(id) {
|
||||
return request({
|
||||
url: "/v1/manage/company",
|
||||
method: "post",
|
||||
data: { company_id: id },
|
||||
});
|
||||
}
|
||||
function companyProduct(id) {
|
||||
return request({
|
||||
url: "/v1/manage/company/product",
|
||||
method: "post",
|
||||
data: { company_id: id, page_num: 1, page_size: 10 },
|
||||
});
|
||||
}
|
||||
|
||||
function createdData(arr) {
|
||||
let l = [];
|
||||
let snap = JSON.parse(JSON.stringify(arr));
|
||||
@ -305,8 +297,13 @@ function getDataList() {
|
||||
let id = route.params.id;
|
||||
if (!id) return;
|
||||
searchEnterpriseDetail(id)
|
||||
.then((resp) => {
|
||||
.then(async (resp) => {
|
||||
state.companyDetail = resp.data;
|
||||
state.localtion = await getCity(
|
||||
resp.data.province,
|
||||
resp.data.city,
|
||||
resp.data.district
|
||||
);
|
||||
loading.value = false;
|
||||
})
|
||||
.catch((err) => {
|
||||
|
@ -29,6 +29,68 @@
|
||||
<div class="pointTit">个人简介</div>
|
||||
</div>
|
||||
<div class="html" v-html="state.expertDetail.introduce"></div>
|
||||
<div style="padding: 20px 0">
|
||||
<div class="pointTit">性别</div>
|
||||
</div>
|
||||
<section>
|
||||
<div>
|
||||
{{
|
||||
state.expertDetail.gender == "1"
|
||||
? "男"
|
||||
: state.expertDetail.gender == "2"
|
||||
? "女"
|
||||
: "未知"
|
||||
}}
|
||||
</div>
|
||||
</section>
|
||||
<div style="padding: 20px 0">
|
||||
<div class="pointTit">手机号</div>
|
||||
</div>
|
||||
<section>
|
||||
<div>
|
||||
{{ state.expertDetail.mobile }}
|
||||
</div>
|
||||
</section>
|
||||
<div style="padding: 20px 0">
|
||||
<div class="pointTit">主修专业</div>
|
||||
</div>
|
||||
<section>
|
||||
<div>
|
||||
{{ state.expertDetail.major }}
|
||||
</div>
|
||||
</section>
|
||||
<div style="padding: 20px 0">
|
||||
<div class="pointTit">毕业院校</div>
|
||||
</div>
|
||||
<section>
|
||||
<div>
|
||||
{{ state.expertDetail.school }}
|
||||
</div>
|
||||
</section>
|
||||
<div style="padding: 20px 0">
|
||||
<div class="pointTit">职称</div>
|
||||
</div>
|
||||
<section>
|
||||
<div>
|
||||
{{ state.expertDetail.title }}
|
||||
</div>
|
||||
</section>
|
||||
<div style="padding: 20px 0">
|
||||
<div class="pointTit">所属领域</div>
|
||||
</div>
|
||||
<section>
|
||||
<div>
|
||||
{{ state.expertDetail.industryStr }}
|
||||
</div>
|
||||
</section>
|
||||
<div style="padding: 20px 0">
|
||||
<div class="pointTit">最高学历</div>
|
||||
</div>
|
||||
<section>
|
||||
<div>
|
||||
{{ state.expertDetail.education }}
|
||||
</div>
|
||||
</section>
|
||||
<div style="padding: 20px 0">
|
||||
<div class="pointTit">研究方向</div>
|
||||
</div>
|
||||
@ -40,6 +102,14 @@
|
||||
{{ item }}
|
||||
</div>
|
||||
</section>
|
||||
<div style="padding: 20px 0">
|
||||
<div class="pointTit">从业时间</div>
|
||||
</div>
|
||||
<section>
|
||||
<div>
|
||||
{{ state.expertDetail.workTime }}
|
||||
</div>
|
||||
</section>
|
||||
<!-- <div style="padding: 20px 0">
|
||||
<div class="pointTit">联系方式</div>
|
||||
</div>
|
||||
|
202
src/views/website/searchList/lab.vue
Normal file
202
src/views/website/searchList/lab.vue
Normal file
@ -0,0 +1,202 @@
|
||||
<template>
|
||||
<div class="index">
|
||||
<searchContainer
|
||||
bannerKey="首页>实验室库>实验室列表"
|
||||
title="实验室库"
|
||||
@handleQuery="handleQuery"
|
||||
>
|
||||
<template v-slot>
|
||||
<el-row type="flex" style="padding: 20px 0">
|
||||
<div style="flex: 1">
|
||||
<div style="position: relative">
|
||||
<!-- <industrySelect @industryChange="industryChange"></industrySelect> -->
|
||||
<div class="total">
|
||||
共找到
|
||||
<span>{{ total }}</span> 个实验室
|
||||
</div>
|
||||
<div v-loading="loading">
|
||||
<section v-for="item in searchResults" :key="item.id">
|
||||
<div style="border: 1px solid #dcdcdc; margin-bottom: 10px">
|
||||
<!-- <gainItem :data="item"></gainItem> -->
|
||||
<LaboratoryItem :data="item"></LaboratoryItem>
|
||||
</div>
|
||||
</section>
|
||||
</div>
|
||||
|
||||
<pagination
|
||||
class="pagination"
|
||||
:total="total"
|
||||
:pageSizes="[10, 10 << 1, 10 << 2, 10 << 3]"
|
||||
v-model:page="queryParams.pageNum"
|
||||
v-model:limit="queryParams.pageSize"
|
||||
:autoScroll="false"
|
||||
@pagination="getDataList"
|
||||
/>
|
||||
</div>
|
||||
</div>
|
||||
<div class="r">
|
||||
<WebContact />
|
||||
</div>
|
||||
</el-row>
|
||||
</template>
|
||||
</searchContainer>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script setup>
|
||||
// import request from "@/utils/request";
|
||||
import { onMounted, reactive } from "vue";
|
||||
import { search } from "@/api/website/home/index";
|
||||
import WebContact from "@/components/webContact/index.vue";
|
||||
import searchContainer from "./components/searchContainer.vue";
|
||||
// import industrySelect from "./components/industrySelect.vue";
|
||||
import gainItem from "./components/gainItem.vue";
|
||||
import wordcloud from "./components/wordcloud.vue";
|
||||
import { useRoute, useRouter } from "vue-router";
|
||||
import LaboratoryItem from "./components/laboratoryItem.vue";
|
||||
// const router = useRouter();
|
||||
const route = useRoute();
|
||||
const queryParams = reactive({
|
||||
pageNum: 1,
|
||||
pageSize: 5,
|
||||
searchType: 8,
|
||||
queryType: route.query.queryType,
|
||||
query: route.query.keyword,
|
||||
});
|
||||
// function handleDetail(id) {
|
||||
// let routeData = router.resolve({
|
||||
// path: `/searchList/0/detail/${id}`,
|
||||
// query: { keyword: queryParams.query },
|
||||
// });
|
||||
// window.open(routeData.href, "_blank");
|
||||
// }
|
||||
|
||||
const loading = ref(false);
|
||||
|
||||
const searchResults = ref([]);
|
||||
const total = ref(0);
|
||||
function createdData(arr) {
|
||||
let l = [];
|
||||
let snap = JSON.parse(JSON.stringify(arr));
|
||||
snap.map((e) => {
|
||||
l.push({ name: e, value: 30 });
|
||||
return { name: e, value: 30 };
|
||||
});
|
||||
return l;
|
||||
}
|
||||
|
||||
// const getSearchResult = async () => {
|
||||
// const resp = await search(queryParams);
|
||||
// console.log(resp);
|
||||
// };
|
||||
function handleQuery(state) {
|
||||
// state.keyword = keyword;
|
||||
queryParams.query = state.currentKeyword;
|
||||
queryParams.queryType = state.queryType;
|
||||
getDataList();
|
||||
}
|
||||
// function industryChange(industry) {
|
||||
// if (industry.id1) {
|
||||
// state.id1 = industry.id1;
|
||||
// }
|
||||
// if (industry.id2) {
|
||||
// state.id2 = industry.id2;
|
||||
// }
|
||||
// if (industry.id3) {
|
||||
// state.id3 = industry.id3;
|
||||
// }
|
||||
// getDataList();
|
||||
// }
|
||||
|
||||
const getDataList = async () => {
|
||||
loading.value = true;
|
||||
try {
|
||||
const resp = await search(queryParams);
|
||||
searchResults.value = resp.list;
|
||||
total.value = resp.total;
|
||||
loading.value = false;
|
||||
} catch (error) {
|
||||
loading.value = false;
|
||||
}
|
||||
};
|
||||
</script>
|
||||
|
||||
<style lang="scss" scoped>
|
||||
.total {
|
||||
font-size: 16px;
|
||||
font-family: Source Han Sans CN;
|
||||
font-weight: 500;
|
||||
color: #333333;
|
||||
margin-bottom: 20px;
|
||||
span {
|
||||
font-size: 30px;
|
||||
color: #0054ff;
|
||||
}
|
||||
}
|
||||
|
||||
.r {
|
||||
display: inline-block;
|
||||
width: 325px;
|
||||
margin-left: 14px;
|
||||
min-height: 200px;
|
||||
// background-color: #fff;
|
||||
}
|
||||
|
||||
.item {
|
||||
height: 200px;
|
||||
overflow: hidden;
|
||||
background-color: #fff;
|
||||
margin-bottom: 16px;
|
||||
|
||||
.img {
|
||||
width: 90px;
|
||||
margin-right: 12px;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
img {
|
||||
width: 90px;
|
||||
height: 90px;
|
||||
border-radius: 50%;
|
||||
}
|
||||
}
|
||||
.content {
|
||||
display: inline-block;
|
||||
width: 390px;
|
||||
.line {
|
||||
font-size: 16px;
|
||||
font-family: Source Han Sans CN;
|
||||
font-weight: 400;
|
||||
color: #666666;
|
||||
margin: 10px 0;
|
||||
span {
|
||||
font-size: 16px;
|
||||
font-family: Source Han Sans CN;
|
||||
font-weight: 500;
|
||||
color: #333;
|
||||
}
|
||||
}
|
||||
}
|
||||
.keywords {
|
||||
flex: 1;
|
||||
width: 129px;
|
||||
height: 129px;
|
||||
}
|
||||
.tit {
|
||||
width: 100%;
|
||||
overflow: hidden;
|
||||
cursor: pointer;
|
||||
.text {
|
||||
margin-right: 200px;
|
||||
overflow: hidden;
|
||||
|
||||
text-overflow: ellipsis;
|
||||
white-space: nowrap;
|
||||
font-size: 20px;
|
||||
font-family: Source Han Sans CN;
|
||||
font-weight: bold;
|
||||
color: #333333;
|
||||
}
|
||||
}
|
||||
}
|
||||
</style>
|
338
src/views/website/searchList/laboratoryDetail.vue
Normal file
338
src/views/website/searchList/laboratoryDetail.vue
Normal file
@ -0,0 +1,338 @@
|
||||
<template>
|
||||
<div v-loading="loading">
|
||||
<searchContainer
|
||||
bannerKey="首页>实验室库>实验室详情"
|
||||
title="实验室库"
|
||||
@handleQuery="handleQuery"
|
||||
>
|
||||
<template v-slot>
|
||||
<div class="head">
|
||||
<el-breadcrumb separator="/">
|
||||
<el-breadcrumb-item>
|
||||
<span class="one">找实验室</span>
|
||||
</el-breadcrumb-item>
|
||||
<el-breadcrumb-item>
|
||||
<span>实验室详情</span>
|
||||
</el-breadcrumb-item>
|
||||
</el-breadcrumb>
|
||||
</div>
|
||||
<el-row type="flex">
|
||||
<div style="flex: 1">
|
||||
<div class="item">
|
||||
<el-row type="flex" style="padding: 40px 20px">
|
||||
<!-- <div class="img">
|
||||
<img :src="state.LabDetail.image" alt />
|
||||
</div> -->
|
||||
<div class="content">
|
||||
<div class="tit">
|
||||
<!-- <div style="float: right">
|
||||
<span>匹配度</span>
|
||||
<el-rate
|
||||
style="display: inline-block"
|
||||
v-model="state.val"
|
||||
disabled
|
||||
></el-rate>
|
||||
</div> -->
|
||||
<div class="text" style="flex: 1">
|
||||
{{ state.LabDetail.name }}
|
||||
</div>
|
||||
</div>
|
||||
<div class="line">
|
||||
所属领域:
|
||||
<span>{{ state.LabDetail.industryStr }}</span>
|
||||
</div>
|
||||
<div class="line">
|
||||
网址:
|
||||
<span>{{ state.LabDetail.url }}</span>
|
||||
</div>
|
||||
<div class="line">
|
||||
所属院所或高校:
|
||||
<!-- <a :href="state.LabDetail.applyName"> -->
|
||||
<span>{{ state.LabDetail.school }}</span>
|
||||
<!-- </a> -->
|
||||
</div>
|
||||
</div>
|
||||
<div class="keywords" style="flex: 1">
|
||||
<wordcloud
|
||||
v-if="state.LabDetail.keyword"
|
||||
:data="createdData(state.LabDetail.keyword.split(','))"
|
||||
></wordcloud>
|
||||
</div>
|
||||
<div class="btns">
|
||||
<div class="order" @click="showDocking = true">预约对接</div>
|
||||
<div class="share">一键分享</div>
|
||||
</div>
|
||||
</el-row>
|
||||
</div>
|
||||
|
||||
<div class="product">
|
||||
<div style="padding: 20px 0">
|
||||
<div class="pointTit">实验室简介</div>
|
||||
</div>
|
||||
<div class="html" v-html="state.LabDetail.introduction"></div>
|
||||
<div style="padding: 20px 0">
|
||||
<div class="pointTit">核心成员及简介</div>
|
||||
</div>
|
||||
<div class="html" v-html="state.LabDetail.member"></div>
|
||||
<div style="padding: 20px 0">
|
||||
<div class="pointTit">研究方向</div>
|
||||
</div>
|
||||
<div>{{ state.LabDetail.researchDirection }}</div>
|
||||
<div style="padding: 20px 0">
|
||||
<div class="pointTit">主要技术应用场景</div>
|
||||
</div>
|
||||
<div>{{ state.LabDetail.primaryTechnology }}</div>
|
||||
<div style="padding: 20px 0">
|
||||
<div class="pointTit">承担科研项目情况</div>
|
||||
</div>
|
||||
<div>{{ state.LabDetail.researchProject }}</div>
|
||||
<div style="padding: 20px 0">
|
||||
<div class="pointTit">代表性科技成果</div>
|
||||
</div>
|
||||
<div>{{ state.LabDetail.achievement }}</div>
|
||||
<div style="padding: 20px 0">
|
||||
<div class="pointTit">所属行业领域</div>
|
||||
</div>
|
||||
<div>{{ state.LabDetail.industryStr }}</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="r"><webContact /></div>
|
||||
</el-row>
|
||||
</template>
|
||||
</searchContainer>
|
||||
<docking v-model:visible="showDocking"></docking>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script setup>
|
||||
import webContact from "@/components/webContact/index.vue";
|
||||
// import request from "@/utils/request";
|
||||
import { searchLaboratoryDetail } from "@/api/website/home";
|
||||
import { onMounted, reactive, ref } from "vue";
|
||||
import searchContainer from "./components/searchContainer.vue";
|
||||
import wordcloud from "./components/wordcloud.vue";
|
||||
// import productItem from "./components/productItem.vue";
|
||||
import { useRoute, useRouter } from "vue-router";
|
||||
import docking from "./components/docking.vue";
|
||||
const showDocking = ref(false);
|
||||
const router = useRouter();
|
||||
const route = useRoute();
|
||||
const loading = ref(true);
|
||||
const state = reactive({
|
||||
pageNum: 1,
|
||||
pageSize: 4,
|
||||
keyword: "",
|
||||
val: 3,
|
||||
LabDetail: {},
|
||||
companyProduct: [],
|
||||
arr: [
|
||||
{
|
||||
name: "Cat",
|
||||
value: 26,
|
||||
},
|
||||
{
|
||||
name: "fish",
|
||||
value: 19,
|
||||
},
|
||||
],
|
||||
});
|
||||
|
||||
function createdData(arr) {
|
||||
let l = [];
|
||||
let snap = JSON.parse(JSON.stringify(arr));
|
||||
snap.map((e) => {
|
||||
l.push({ name: e, value: 30 });
|
||||
return { name: e, value: 30 };
|
||||
});
|
||||
return l;
|
||||
}
|
||||
|
||||
// function handleDetail(id) {
|
||||
// let routeData = router.resolve({
|
||||
// path: `/searchList/0/detail/${id}`,
|
||||
// query: { keyword: state.keyword },
|
||||
// });
|
||||
// window.open(routeData.href, "_blank");
|
||||
// }
|
||||
|
||||
function handleList(mode, keyword) {
|
||||
router.push({
|
||||
path: `/searchList/${mode}`,
|
||||
query: { keyword, queryType: route.query.queryType },
|
||||
});
|
||||
}
|
||||
|
||||
// 首次加载数据,其后跳转页面
|
||||
let flag = true;
|
||||
|
||||
function handleQuery(state) {
|
||||
state.keyword = state.currentKeyword;
|
||||
if (flag) {
|
||||
getDataList();
|
||||
flag = false;
|
||||
} else {
|
||||
handleList("lab", state.currentKeyword);
|
||||
}
|
||||
}
|
||||
|
||||
function getDataList() {
|
||||
loading.value = true;
|
||||
|
||||
let id = route.params.id;
|
||||
if (!id) return;
|
||||
searchLaboratoryDetail(id)
|
||||
.then((resp) => {
|
||||
state.LabDetail = resp.data;
|
||||
loading.value = false;
|
||||
})
|
||||
.catch((err) => {
|
||||
console.log(err);
|
||||
loading.value = false;
|
||||
});
|
||||
}
|
||||
</script>
|
||||
|
||||
<style lang="scss" scoped>
|
||||
.head {
|
||||
padding: 15px 0px;
|
||||
span {
|
||||
font-size: 16px;
|
||||
font-family: Source Han Sans CN;
|
||||
font-weight: 400;
|
||||
color: #666666;
|
||||
}
|
||||
.one {
|
||||
color: #333333;
|
||||
}
|
||||
}
|
||||
.r {
|
||||
display: inline-block;
|
||||
width: 325px;
|
||||
margin-left: 14px;
|
||||
min-height: 200px;
|
||||
}
|
||||
|
||||
.product {
|
||||
width: 661px;
|
||||
box-sizing: border-box;
|
||||
padding: 20px;
|
||||
background: #fff;
|
||||
.describe {
|
||||
font-size: 14px;
|
||||
font-family: Source Han Sans CN;
|
||||
font-weight: 400;
|
||||
color: #666666;
|
||||
margin-bottom: 5px;
|
||||
}
|
||||
}
|
||||
|
||||
.pointTit {
|
||||
position: relative;
|
||||
padding-left: 10px;
|
||||
font-size: 16px;
|
||||
font-family: Source Han Sans CN;
|
||||
font-weight: 500;
|
||||
color: #333333;
|
||||
&:before {
|
||||
content: "";
|
||||
top: 8px;
|
||||
left: 0px;
|
||||
position: absolute;
|
||||
display: block;
|
||||
width: 5px;
|
||||
height: 5px;
|
||||
background: #0054ff;
|
||||
}
|
||||
}
|
||||
|
||||
.item {
|
||||
overflow: hidden;
|
||||
background-color: #fff;
|
||||
margin-bottom: 16px;
|
||||
|
||||
.btns {
|
||||
overflow: hidden;
|
||||
padding-top: 20px;
|
||||
width: 100%;
|
||||
|
||||
div {
|
||||
text-align: center;
|
||||
float: right;
|
||||
cursor: pointer;
|
||||
user-select: none;
|
||||
width: 101px;
|
||||
height: 36px;
|
||||
font-size: 14px;
|
||||
font-family: Source Han Sans CN;
|
||||
font-weight: 400;
|
||||
line-height: 36px;
|
||||
box-sizing: border-box;
|
||||
&:hover {
|
||||
opacity: 0.7;
|
||||
}
|
||||
}
|
||||
.share {
|
||||
color: #333333;
|
||||
background: #f2f6ff;
|
||||
border: 1px solid #dcdcdc;
|
||||
margin-right: 10px;
|
||||
}
|
||||
.order {
|
||||
background: #0054ff;
|
||||
color: #ffffff;
|
||||
border: none;
|
||||
}
|
||||
}
|
||||
|
||||
.img {
|
||||
width: 90px;
|
||||
margin-right: 12px;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
img {
|
||||
width: 90px;
|
||||
height: 90px;
|
||||
border-radius: 50%;
|
||||
}
|
||||
}
|
||||
.content {
|
||||
display: inline-block;
|
||||
width: 390px;
|
||||
.line {
|
||||
font-size: 16px;
|
||||
font-family: Source Han Sans CN;
|
||||
font-weight: 400;
|
||||
color: #666666;
|
||||
margin: 10px 0;
|
||||
span {
|
||||
font-size: 16px;
|
||||
font-family: Source Han Sans CN;
|
||||
font-weight: 500;
|
||||
color: #333;
|
||||
}
|
||||
}
|
||||
}
|
||||
.keywords {
|
||||
flex: 1;
|
||||
width: 129px;
|
||||
height: 129px;
|
||||
}
|
||||
.tit {
|
||||
width: 100%;
|
||||
overflow: hidden;
|
||||
cursor: pointer;
|
||||
.text {
|
||||
// margin-right: 200px;
|
||||
overflow: hidden;
|
||||
|
||||
text-overflow: ellipsis;
|
||||
white-space: nowrap;
|
||||
font-size: 20px;
|
||||
font-family: Source Han Sans CN;
|
||||
font-weight: bold;
|
||||
color: #333333;
|
||||
}
|
||||
}
|
||||
}
|
||||
</style>
|
@ -77,6 +77,37 @@
|
||||
class="html"
|
||||
v-html="state.patentDetail.principalClaim"
|
||||
></div>
|
||||
<div style="padding: 20px 0">
|
||||
<div class="pointTit">发明人</div>
|
||||
</div>
|
||||
<div class="html" v-html="state.patentDetail.inventor"></div>
|
||||
<div style="padding: 20px 0">
|
||||
<div class="pointTit">IPC分类号</div>
|
||||
</div>
|
||||
<section>
|
||||
{{ state.patentDetail.ipcCode }}
|
||||
</section>
|
||||
<div style="padding: 20px 0">
|
||||
<div class="pointTit">专利类型</div>
|
||||
</div>
|
||||
<section>
|
||||
{{
|
||||
patentOptions.find((el) => el.key == state.patentDetail.kind)
|
||||
?.value
|
||||
}}
|
||||
</section>
|
||||
<div style="padding: 20px 0">
|
||||
<div class="pointTit">公开日</div>
|
||||
</div>
|
||||
<section>{{ state.patentDetail.openAt }}</section>
|
||||
<div style="padding: 20px 0">
|
||||
<div class="pointTit">公开号</div>
|
||||
</div>
|
||||
<section>{{ state.patentDetail.openCode }}</section>
|
||||
<div style="padding: 20px 0">
|
||||
<div class="pointTit">申请人地址</div>
|
||||
</div>
|
||||
<section>{{ state.patentDetail.applyAddress }}</section>
|
||||
<!-- <section v-if="state.patentDetail.directions">
|
||||
<div
|
||||
v-for="(item, index) in state.patentDetail.directions"
|
||||
@ -156,8 +187,10 @@ import { searchPatentDetail } from "@/api/website/home";
|
||||
import { onMounted, reactive, ref } from "vue";
|
||||
import searchContainer from "./components/searchContainer.vue";
|
||||
import wordcloud from "./components/wordcloud.vue";
|
||||
import { patentOptions } from "@/utils/parameter";
|
||||
import productItem from "./components/productItem.vue";
|
||||
import { useRoute, useRouter } from "vue-router";
|
||||
// import { getCity } from "../../../utils/city";
|
||||
import docking from "./components/docking.vue";
|
||||
const showDocking = ref(false);
|
||||
const router = useRouter();
|
||||
@ -170,6 +203,7 @@ const state = reactive({
|
||||
val: 3,
|
||||
patentDetail: {},
|
||||
companyProduct: [],
|
||||
// localtion: "",
|
||||
arr: [
|
||||
{
|
||||
name: "Cat",
|
||||
@ -265,8 +299,13 @@ function getDataList() {
|
||||
let id = route.params.id;
|
||||
if (!id) return;
|
||||
searchPatentDetail(id)
|
||||
.then((resp) => {
|
||||
.then(async (resp) => {
|
||||
state.patentDetail = resp.data;
|
||||
// state.localtion = await getCity(
|
||||
// resp.data.province,
|
||||
// resp.data.city,
|
||||
// resp.data.district
|
||||
// );
|
||||
loading.value = false;
|
||||
})
|
||||
.catch((err) => {
|
||||
|
@ -1,8 +1,8 @@
|
||||
<template>
|
||||
<div class="index">
|
||||
<searchContainer
|
||||
bannerKey="首页>技术需求库>技术需求列表"
|
||||
title="技术需求库"
|
||||
bannerKey="首页>需求库>需求列表"
|
||||
title="需求库"
|
||||
@handleQuery="handleQuery"
|
||||
>
|
||||
<template v-slot>
|
||||
@ -12,7 +12,7 @@
|
||||
<!-- <industrySelect @industryChange="industryChange"></industrySelect> -->
|
||||
<div class="total">
|
||||
共找到
|
||||
<span>{{ total }}</span> 个技术需求
|
||||
<span>{{ total }}</span> 个需求
|
||||
</div>
|
||||
<div v-loading="loading">
|
||||
<section v-for="item in searchResults" :key="item.id">
|
||||
|
@ -1,18 +1,18 @@
|
||||
<template>
|
||||
<div v-loading="loading">
|
||||
<searchContainer
|
||||
bannerKey="首页>技术需求库>技术需求详情"
|
||||
title="技术需求库"
|
||||
bannerKey="首页>需求库>需求详情"
|
||||
title="需求库"
|
||||
@handleQuery="handleQuery"
|
||||
>
|
||||
<template v-slot>
|
||||
<div class="head">
|
||||
<el-breadcrumb separator="/">
|
||||
<el-breadcrumb-item>
|
||||
<span class="one">接技术需求</span>
|
||||
<span class="one">接需求</span>
|
||||
</el-breadcrumb-item>
|
||||
<el-breadcrumb-item>
|
||||
<span>技术需求详情</span>
|
||||
<span>需求详情</span>
|
||||
</el-breadcrumb-item>
|
||||
</el-breadcrumb>
|
||||
</div>
|
||||
@ -20,6 +20,9 @@
|
||||
<div style="flex: 1">
|
||||
<div class="item">
|
||||
<el-row type="flex" style="padding: 40px 20px">
|
||||
<!-- <technologyDemandItem
|
||||
:data="state.demandDetail"
|
||||
></technologyDemandItem> -->
|
||||
<div class="img">
|
||||
<img :src="state.demandDetail.image" alt />
|
||||
</div>
|
||||
@ -41,19 +44,13 @@
|
||||
需求类型:
|
||||
<span>{{ state.demandDetail.kind }}</span>
|
||||
</div>
|
||||
<div class="line">
|
||||
申请日
|
||||
<span>{{ state.demandDetail.createTime }}</span>
|
||||
</div>
|
||||
<div class="line">
|
||||
联系人
|
||||
<!-- <a :href="state.demandDetail.applyName"> -->
|
||||
<span>{{ state.demandDetail.name }}</span>
|
||||
<!-- </a> -->
|
||||
<span>中科云平台</span>
|
||||
</div>
|
||||
<div class="line">
|
||||
联系方式
|
||||
<span>{{ state.demandDetail.mobile }}</span>
|
||||
联系方式(微信同号):
|
||||
<span>18156053255</span>
|
||||
</div>
|
||||
</div>
|
||||
<div class="keywords" style="flex: 1">
|
||||
@ -78,6 +75,12 @@
|
||||
<div class="pointTit">需求描述</div>
|
||||
</div>
|
||||
<div class="html" v-html="state.demandDetail.introduce"></div>
|
||||
<div style="padding: 20px 0">
|
||||
<div class="pointTit">所在地</div>
|
||||
</div>
|
||||
<section>
|
||||
{{ state.localtion }}
|
||||
</section>
|
||||
</div>
|
||||
</div>
|
||||
<div class="r"><webContact /></div>
|
||||
@ -96,6 +99,7 @@ import { onMounted, reactive, ref } from "vue";
|
||||
import searchContainer from "./components/searchContainer.vue";
|
||||
import wordcloud from "./components/wordcloud.vue";
|
||||
import productItem from "./components/productItem.vue";
|
||||
import { getCity } from "@/utils/city";
|
||||
import { useRoute, useRouter } from "vue-router";
|
||||
import docking from "./components/docking.vue";
|
||||
const showDocking = ref(false);
|
||||
@ -109,6 +113,7 @@ const state = reactive({
|
||||
val: 3,
|
||||
demandDetail: {},
|
||||
companyProduct: [],
|
||||
localtion: "",
|
||||
arr: [
|
||||
{
|
||||
name: "Cat",
|
||||
@ -157,8 +162,15 @@ function getDataList() {
|
||||
let id = route.params.id;
|
||||
if (!id) return;
|
||||
searchTechnologyDemandDetail(id)
|
||||
.then((resp) => {
|
||||
.then(async (resp) => {
|
||||
state.demandDetail = resp.data;
|
||||
if (resp.data.province && resp.data.city && resp.data.district) {
|
||||
state.localtion = await getCity(
|
||||
resp.data.province,
|
||||
resp.data.city,
|
||||
resp.data.district
|
||||
);
|
||||
}
|
||||
loading.value = false;
|
||||
})
|
||||
.catch((err) => {
|
||||
|
Reference in New Issue
Block a user