This commit is contained in:
2023-07-03 17:31:57 +08:00
parent eb19778bd0
commit 4789db178f
16 changed files with 546 additions and 521 deletions

View File

@ -3,16 +3,22 @@
<head>
<meta charset="utf-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
<meta name="renderer" content="webkit">
<meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1, user-scalable=no">
<link rel="icon" href="/favicon.ico">
<script type="text/javascript" src='//webapi.amap.com/maps?v=1.4.11&key=35a871e5905ecfd749bd998448b9cd03'></script>
<script type="text/javascript"
src="https://webapi.amap.com/maps?v=1.4.11&key=35a871e5905ecfd749bd998448b9cd03&plugin=AMap.DistrictSearch"></script>
<meta content="IE=edge,chrome=1" http-equiv="X-UA-Compatible">
<meta content="webkit" name="renderer">
<meta content="width=device-width, initial-scale=1, maximum-scale=1, user-scalable=no" name="viewport">
<link href="/favicon.ico" rel="icon">
<script type="text/javascript">
window._AMapSecurityConfig = {
securityJsCode: '7d1b758db4876389af608259c4c99832',
}
</script>
<script src='//webapi.amap.com/maps?v=1.4.15&key=bfc7224388e835679ffe74cfbd28c8d6' type="text/javascript"></script>
<script src="https://webapi.amap.com/maps?v=1.4.11&key=bfc7224388e835679ffe74cfbd28c8d6&plugin=AMap.DistrictSearch"
type="text/javascript"></script>
<script src="//webapi.amap.com/ui/1.0/main.js?v=1.0.11"></script>
<title>中科云</title>
<!--[if lt IE 11]><script>window.location.href='/html/ie.html';</script><![endif]-->
<!--[if lt IE 11]>
<script>window.location.href = '/html/ie.html';</script><![endif]-->
<style>
html,
body,
@ -213,7 +219,7 @@
<div class="load_title">正在加载系统资源,请耐心等待</div>
</div>
</div>
<script type="module" src="/src/main.js"></script>
<script src="/src/main.js" type="module"></script>
</body>
</html>

View File

@ -188,8 +188,8 @@ function listToString(list, separator) {
separator = separator || ",";
for (let i in list) {
if (undefined !== list[i].url && list[i].url.indexOf("blob:") !== 0) {
strs += list[i].url.replace(baseUrl, "") + separator;
// strs += list[i].url + separator;
// strs += list[i].url.replace(baseUrl, "") + separator;
strs += list[i].url + separator;
}
}
return strs != "" ? strs.substr(0, strs.length - 1) : "";

View File

@ -212,8 +212,8 @@ function handlePage() {
function handlePath(path) {
pagePath.value = path;
// router.push(path);
window.open(path, "_blank");
router.push(path);
// window.open(path, "_blank");
}
function logout() {
ElMessageBox.confirm("确定注销并退出系统吗?", "提示", {

View File

@ -124,3 +124,18 @@ export const invoiceStatusDict = [
elTagType: "success",
},
];
// 课题角色1承担单位2参与单位
export const subjectRoleDict = [
{
value: "1",
label: "承担单位",
elTagType: "primary",
}
,
{
value: "2",
label: "参与单位",
elTagType: "success",
}
];

View File

@ -9,7 +9,7 @@ export function addViewHistory(type, itemId, itemName) {
}
const enterpriseId = enterprise.id;
const enterpriseName = enterprise.name;
const nickname = enterprise.userName;
const nickname = enterprise.username;
const phone = enterprise.phone;
addViewRecord({
type: type,

View File

@ -15,10 +15,11 @@ const queryRef = ref(null);
* 删除指定行
* @param row
*/
const deleteRecord = (row) => {};
const deleteRecord = (row) => {
};
// 重置查询条件 resetQuery
export const resetQuery = () => {
const resetQuery = () => {
queryRef.value.resetFields();
handleQuery();
};

View File

@ -107,7 +107,7 @@ import {
updateTechnologyDemand,
} from "@/api/admin/enterprise/demand";
import { onMounted, reactive, ref, toRefs } from "vue";
import { updateCount } from "../../../../api/admin/count";
import { updateCount } from "@/api/admin/count";
const router = useRouter();
const route = useRoute();

View File

@ -31,9 +31,9 @@
</el-form-item>
</el-form>
<el-row :gutter="10" class="mb8">
<el-col :span="1.5">
<el-button icon="plus" size="small" type="primary">新增</el-button>
</el-col>
<!-- <el-col :span="1.5">-->
<!-- <el-button icon="plus" size="small" type="primary">新增</el-button>-->
<!-- </el-col>-->
<right-toolbar
v-model:showSearch="showSearch"
@queryTable="getList"

View File

@ -71,7 +71,7 @@
icon="view"
size="small"
type="text"
@click="handleBrowseUnitInfo(row.id)"
@click="handleBrowseUnitInfo(row)"
>浏览单位信息
</el-button>
</template>

View File

@ -1,25 +1,32 @@
<script setup>
import Pagination from "@/components/Pagination/index.vue";
import { customerBrowseList } from "@/api/admin/research/footprint";
import { reactive, ref, toRefs } from "vue";
import { seeLogTypeDict } from "@/constant/dict";
import { useRoute, useRouter } from "vue-router";
import { seeLogList } from "@/api/admin/laboratory/paper";
const route = useRoute();
const router = useRouter();
const data = reactive({
queryParams: {
pageNum: 1,
pageSize: 10,
browseTimeRange: [],
id: null,
},
});
const { queryParams } = toRefs(data);
if (route.query.id) {
queryParams.value.id = route.query.id;
} else {
router.push({ path: "/admin/research/paper" });
}
const queryRef = ref();
const tableData = ref([]);
const loading = ref(false);
const total = ref(0);
const getList = async () => {
loading.value = true;
const resp = await customerBrowseList(queryParams.value);
const resp = await seeLogList(queryParams.value);
tableData.value = resp.rows;
total.value = resp.total;
loading.value = false;
@ -53,27 +60,15 @@ getList();
<template>
<div class="app-container">
<el-form ref="queryRef" class="mb8" inline>
<el-form ref="queryRef" class="mb8" :model="queryParams" inline>
<!-- 企业名称-->
<el-form-item label="企业名称" prop="enterpriseName">
<el-form-item label="企业名称" prop="name">
<el-input
v-model="queryParams.enterpriseName"
v-model="queryParams.name"
placeholder="请输入企业名称"
></el-input>
</el-form-item>
<!-- 浏览时间范围-->
<el-form-item label="浏览时间" prop="browseTime">
<el-date-picker
v-model="queryParams.browseTimeRange"
end-placeholder="结束日期"
range-separator="至"
start-placeholder="开始日期"
type="datetimerange"
unlink-panels
value-format="YYYY-MM-dd"
>
</el-date-picker>
</el-form-item>
<el-form-item>
<el-button type="primary" @click="handleQuery">查询</el-button>
<el-button @click="resetQuery">重置</el-button>
@ -82,7 +77,6 @@ getList();
<!-- 客户浏览数据列表-->
<el-table :data="tableData">
<!--多选-->
<el-table-column type="selection" width="55"></el-table-column>
<el-table-column label="企业名称" prop="enterpriseName"></el-table-column>
<el-table-column label="浏览类别" prop="type">
<template #default="{ row }">
@ -94,17 +88,8 @@ getList();
<el-table-column label="名称" prop="typeName"></el-table-column>
<el-table-column label="联系人" prop="nickname"></el-table-column>
<el-table-column label="手机" prop="phone"></el-table-column>
<el-table-column label="浏览时长" prop="browseTime"></el-table-column>
<el-table-column label="浏览次数" prop="seeCount"></el-table-column>
<el-table-column label="浏览时间" prop="updateTime"></el-table-column>
<!-- 操作-->
<el-table-column label="操作" width="200">
<template #default="{ row }">
<el-button size="small" type="text" @click="handleDelete(row)"
>删除</el-button
>
</template>
</el-table-column>
</el-table>
<!-- 分页 -->
<pagination

View File

@ -7,9 +7,9 @@
:model="queryParams"
@submit.prevent
>
<el-form-item label="专利名称" prop="title">
<el-form-item label="专利名称" prop="patentName">
<el-input
v-model="queryParams.title"
v-model="queryParams.patentName"
clearable
placeholder="请输入专利名称"
size="small"
@ -248,7 +248,7 @@ const data = reactive({
queryParams: {
pageNum: 1,
pageSize: 10,
inventor: undefined,
patentName: undefined
},
// form: {},
// rules: {

View File

@ -7,9 +7,9 @@
:model="queryParams"
@submit.prevent
>
<el-form-item label="成果名称" prop="title">
<el-form-item label="成果名称" prop="name">
<el-input
v-model="queryParams.title"
v-model="queryParams.name"
clearable
placeholder="请输入专利名称"
size="small"
@ -46,9 +46,13 @@
prop="title"
/>
<el-table-column :show-overflow-tooltip="true" label="类型" prop="kind" />
<el-table-column label="所属专家" prop="inventor" />
<el-table-column label="课题角色" prop="applyName" />
<el-table-column label="课题负责人" prop="applyName" />
<!-- <el-table-column label="所属专家" prop="inventor" />-->
<el-table-column label="课题角色" >
<template #default="{ row }">
{{ subjectRoleDict.find(item => item.value === row.role)?.label}}
</template>
</el-table-column>
<el-table-column label="课题负责人" prop="director" />
<el-table-column align="center" label="发布时间" prop="applyAt">
<template #default="{ row }">
<span>{{ dayjs(row.applyAt).format("YYYY-MM-DD") }}</span>
@ -60,13 +64,13 @@
label="操作"
>
<template #default="{ row }">
<el-button
icon="download"
size="small"
type="text"
@click="handleTakeOff(row.id)"
>下架
</el-button>
<!-- <el-button-->
<!-- icon="download"-->
<!-- size="small"-->
<!-- type="text"-->
<!-- @click="handleTakeOff(row.id)"-->
<!-- >下架-->
<!-- </el-button>-->
<el-button
icon="Delete"
size="small"
@ -97,6 +101,7 @@ import {
deleteTechnologyProject,
technologyProjectList,
} from "@/api/admin/laboratory/research-project";
import {subjectRoleDict} from "../../../../../constant/dict";
const router = useRouter();

View File

@ -53,27 +53,14 @@ getList();
<template>
<div class="app-container">
<el-form ref="queryRef" class="mb8" inline>
<el-form ref="queryRef" class="mb8" :model="queryParams" inline>
<!-- 企业名称-->
<el-form-item label="企业名称" prop="enterpriseName">
<el-form-item label="企业名称" prop="name">
<el-input
v-model="queryParams.enterpriseName"
v-model="queryParams.name"
placeholder="请输入企业名称"
></el-input>
</el-form-item>
<!-- 浏览时间范围-->
<el-form-item label="浏览时间" prop="browseTime">
<el-date-picker
v-model="queryParams.browseTimeRange"
end-placeholder="结束日期"
range-separator="至"
start-placeholder="开始日期"
type="datetimerange"
unlink-panels
value-format="YYYY-MM-dd"
>
</el-date-picker>
</el-form-item>
<el-form-item>
<el-button type="primary" @click="handleQuery">查询</el-button>
<el-button @click="resetQuery">重置</el-button>
@ -82,7 +69,7 @@ getList();
<!-- 客户浏览数据列表-->
<el-table :data="tableData">
<!--多选-->
<el-table-column type="selection" width="55"></el-table-column>
<!-- <el-table-column type="selection" width="55"></el-table-column>-->
<el-table-column label="企业名称" prop="enterpriseName"></el-table-column>
<el-table-column label="浏览类别" prop="type">
<template #default="{ row }">
@ -94,17 +81,8 @@ getList();
<el-table-column label="名称" prop="typeName"></el-table-column>
<el-table-column label="联系人" prop="nickname"></el-table-column>
<el-table-column label="手机" prop="phone"></el-table-column>
<el-table-column label="浏览时长" prop="browseTime"></el-table-column>
<el-table-column label="浏览次数" prop="seeCount"></el-table-column>
<el-table-column label="浏览时间" prop="updateTime"></el-table-column>
<!-- 操作-->
<el-table-column label="操作" width="200">
<template #default="{ row }">
<el-button size="small" type="text" @click="handleDelete(row)"
>删除</el-button
>
</template>
</el-table-column>
</el-table>
<!-- 分页 -->
<pagination

View File

@ -39,16 +39,20 @@
<!-- 表格数据 -->
<el-table v-loading="loading" :data="dataList">
<el-table-column label="数据编号" prop="id" />
<el-table-column
<el-table-column align="center" label="数据编号" prop="id" />
<el-table-column align="center"
:show-overflow-tooltip="true"
label="科研项目名称"
prop="title"
/>
<el-table-column :show-overflow-tooltip="true" label="类型" prop="kind" />
<el-table-column label="所属专家" prop="inventor" />
<el-table-column label="课题角色" prop="applyName" />
<el-table-column label="课题负责人" prop="applyName" />
<el-table-column align="center" :show-overflow-tooltip="true" label="类型" prop="kind" />
<!-- <el-table-column label="所属专家" prop="inventor" />-->
<el-table-column align="center" label="课题角色" >
<template #default="{ row }">
<span>{{ subjectRoleDict.find(item => item.value === row.role)?.label }}</span>
</template>
</el-table-column>
<el-table-column align="center" label="课题负责人" prop="director" />
<el-table-column align="center" label="发布时间" prop="applyAt">
<template #default="{ row }">
<span>{{ dayjs(row.applyAt).format("YYYY-MM-DD") }}</span>
@ -60,13 +64,13 @@
label="操作"
>
<template #default="{ row }">
<el-button
icon="download"
size="small"
type="text"
@click="handleTakeOff(row.id)"
>下架
</el-button>
<!-- <el-button-->
<!-- icon="download"-->
<!-- size="small"-->
<!-- type="text"-->
<!-- @click="handleTakeOff(row.id)"-->
<!-- >下架-->
<!-- </el-button>-->
<el-button
icon="Delete"
size="small"
@ -97,6 +101,7 @@ import {
deleteTechnologyProject,
technologyProjectList,
} from "@/api/admin/research/research-project";
import {subjectRoleDict} from "@/constant/dict";
const router = useRouter();

View File

@ -1,5 +1,5 @@
<template>
<div class="small" v-loading="loading">
<div v-loading="loading" class="small">
<div class="_title">
<div
v-if="!state.banner"
@ -8,20 +8,20 @@
<div v-else style="height: 394px">
<img
:src="state.banner"
style="width: 100%; height: 100%"
alt="banner"
style="width: 100%; height: 100%"
/>
</div>
<div
v-if="state.caseList.length"
class="_li"
:class="isFixed ? '_fixed' : ''"
class="_li"
>
<ul class="conter1000">
<li
:class="activeId == item.id ? '_active' : ''"
v-for="(item, index) in state.caseList"
:key="item.id"
:class="activeId == item.id ? '_active' : ''"
@click="setScrollTop(item.id, index)"
>
{{ item.title }}
@ -30,24 +30,24 @@
</div>
<h2 v-else style="text-align: center; line-height: 100px">暂无数据</h2>
</div>
<div class="box" v-show="!isShowMore">
<div v-show="!isShowMore" class="box">
<div
class="_item"
:ref="setItemRef"
v-for="(item, index) in state.caseList"
:key="index"
:ref="setItemRef"
:data-id="item.id"
class="_item"
>
<h3 class="_tit text-center" style="font-size: 24px; color: #333333">
{{ item.title }}
</h3>
<div class="_info conter1000">
<div class="_r" v-if="isOddEvenNumber(index)">
<div v-if="isOddEvenNumber(index)" class="_r">
<img :src="item.image" alt srcset/>
</div>
<div
class="_l"
:class="isOddEvenNumber(index) ? '_paddingl' : '_paddingr'"
class="_l"
>
<h3 :class="isOddEvenNumber(index) ? 'text-right' : ''">
{{ item.title }}
@ -55,7 +55,7 @@
<!-- <p>{{ item.description }}</p> -->
<p>{{ item.description }}</p>
</div>
<div class="_r" v-if="!isOddEvenNumber(index)">
<div v-if="!isOddEvenNumber(index)" class="_r">
<img :src="item.image" alt srcset/>
</div>
</div>
@ -67,9 +67,9 @@
@click="handlePath(child.id)"
>
<el-image
style="width: 100%; height: 135px"
:src="child.image"
fit="cover"
style="width: 100%; height: 135px"
></el-image>
<div class="_head text_hidden">{{ child.title }}</div>
<div class="_detail text_hidden">{{ child.description }}</div>
@ -77,7 +77,8 @@
</ul>
<div class="_liBtn text-right">
<el-button class="x_btns" @click="handleShowMore(item)"
>查看更多</el-button
>查看更多
</el-button
>
</div>
</div>
@ -85,9 +86,9 @@
</div>
<seeMore
v-if="isShowMore"
:data="moreData"
v-model:isShowMore="isShowMore"
v-model:oneLevelTitle="oneLevelTitle"
:data="moreData"
></seeMore>
<webFooter></webFooter>
</div>
@ -137,6 +138,8 @@ const route = useRoute();
watch(route, () => {
initData();
});
onMounted(() => {
initData();
});
@ -148,7 +151,7 @@ async function initData() {
let mode = route.params.mode;
// let key = keyDict[name];
getCase({ mode }).then((res) => {
mode && getCase({mode}).then((res) => {
state.caseList = res.data;
initScroll();
// loading.value = false;
@ -183,6 +186,7 @@ function initScroll() {
});
});
}
function getScroll() {
return {
left:
@ -197,6 +201,7 @@ function getScroll() {
0,
};
}
function setScrollTop(id, index) {
// if (isShowMore.value) return false;
isShowMore.value = false;
@ -207,9 +212,11 @@ function setScrollTop(id, index) {
});
activeId.value = id;
}
function isOddEvenNumber(num) {
return num % 2 == 0 ? false : true;
}
function handleShowMore(item) {
console.log(item);
moreData.value = item.children;
@ -223,18 +230,22 @@ function handleShowMore(item) {
<style lang="scss" scoped>
.small {
background-color: #fff;
._title {
position: relative;
._li {
position: absolute;
bottom: 0;
width: 100%;
height: 48px;
background: rgba(0, 0, 0, 0.2);
> ul {
display: flex;
height: 48px;
line-height: 48px;
li {
flex: 1;
text-align: center;
@ -243,11 +254,13 @@ function handleShowMore(item) {
display: inline-block;
cursor: pointer;
}
._active {
background: #000000;
}
}
}
._fixed {
position: fixed;
top: 80px;
@ -255,28 +268,36 @@ function handleShowMore(item) {
background-color: #ccc;
}
}
.box {
margin-bottom: 30px;
._item {
._tit {
margin: 0;
padding: 100px 0 60px;
}
._info {
display: flex;
._paddingr {
padding-right: 63px;
}
._paddingl {
padding-left: 63px;
}
._l {
flex: 1;
h3 {
font-size: 18px;
font-weight: 500;
color: #333333;
}
p {
font-size: 14px;
font-weight: 400;
@ -284,9 +305,11 @@ function handleShowMore(item) {
line-height: 24px;
}
}
._r {
width: 420px;
background: #f2f6ff;
img {
width: 100%;
height: 100%;
@ -294,19 +317,24 @@ function handleShowMore(item) {
}
}
}
._list {
margin-top: 86px;
> ul {
display: flex;
justify-content: center;
li {
cursor: pointer;
width: calc(100% / 6);
padding: 0 11px;
&:hover ._head,
&:hover ._detail {
opacity: 0.6;
}
._head {
margin: 5px 0;
font-size: 17px;
@ -315,6 +343,7 @@ function handleShowMore(item) {
color: #333333;
line-height: 19px;
}
._detail {
font-size: 15px;
font-family: Source Han Sans CN;
@ -324,6 +353,7 @@ function handleShowMore(item) {
}
}
}
._liBtn {
margin-top: 36px;
display: flex;

View File

@ -31,9 +31,9 @@ export default defineConfig(({ mode, command }) => {
proxy: {
// https://cn.vitejs.dev/config/#server-proxy
"/dev-api": {
// target: 'http://101.34.131.16:1618',
target: "http://101.34.131.16:1618",
// target: "http://101.34.131.16:1618",
target: "http://192.168.0.201:1618",
// target: "http://192.168.0.201:1618",
// target: 'http://172.18.3.127:1618',
changeOrigin: true,
rewrite: (p) => p.replace(/^\/dev-api/, ""),