This commit is contained in:
quantulr
2023-11-07 17:14:42 +08:00
parent a8b1ad286d
commit 83e7cd3c4d
5 changed files with 35 additions and 21 deletions

View File

@ -13,7 +13,23 @@ const Page = async ({
const data = await articleDetail({ id: articleId });
return (
<>
<ArticleWithBreadcrumb breadcrumb={[]}>
<ArticleWithBreadcrumb
breadcrumb={[
{ title: "首页", href: "/" },
{
title: "学术交流",
href: "/academic-exchange/academic-events/pages/1",
},
{
title: "学术活动",
href: "/academic-exchange/academic-events/pages/1",
},
{
title: data.title,
href: `/academic-exchange/academic-events/${data.id}`,
},
]}
>
<ArticleRender article={data} />
</ArticleWithBreadcrumb>
</>

View File

@ -14,8 +14,8 @@ export default async function ResearchProgress({
<ArticleWithBreadcrumb
breadcrumb={[
{ title: "首页", href: "/" },
{ title: "科研进展", href: "/general-news/pages/1" },
{ title: data.title, href: `/general-news/${data.id}` },
{ title: "科研进展", href: "/research-progress/pages/1" },
{ title: data.title, href: `/research-progress/${data.id}` },
]}
>
<ArticleRender article={data} />

View File

@ -9,6 +9,7 @@ import "swiper/css";
import "swiper/css/pagination";
import "swiper/css/effect-coverflow";
import "swiper/css/autoplay";
import Image from "next/image";
const data = [
{
@ -134,7 +135,7 @@ const AnhuiSwiper = () => {
swiper?.destroy();
swiper = null;
};
}, [data]);
}, []);
return (
<div className={"flex h-[205px] flex-col bg-white"}>
<div

View File

@ -79,13 +79,7 @@ const ArticleItem = ({ article }: { article: Article }) => {
className={"aspect-square"}
href={`/branch-life-sketch/${article.id}`}
>
<img
alt={""}
className={"h-full w-full"}
src={article.image
.replace("http://101.34.131.16:8084/api/uploads/", "")
.replace("http://localhost:8084/api/uploads/", "")}
/>
<img alt={""} className={"h-full w-full"} src={article.image} />
</Link>
<div className={"ml-1 w-0 flex-1"}>

View File

@ -1,16 +1,19 @@
/** @type {import("next").NextConfig} */
const nextConfig = {
async rewrites() {
return [
{
source: "/api/:path*",
destination: "http://localhost:8084/api/:path*"
}, {
source: "/admin-api/:path*",
destination: "http://localhost:8082/api/:path*"
},
];
}
return process.env.NODE_ENV === "development"
? [
{
source: "/api/:path*",
destination: "http://localhost:8084/api/:path*",
},
{
source: "/admin-api/:path*",
destination: "http://localhost:8082/api/:path*",
},
]
: [];
},
};
module.exports = nextConfig;