Commit 46abc84b by 吴春元

修改

parent 8758aaee
......@@ -18,7 +18,7 @@
/>
<button
class="flex items-center px-4 py-[9px] bg-blue-500 text-white rounded-[10px] hover:bg-blue-600 transition-colors whitespace-nowrap"
class="flex items-center px-4 py-[9px] bg-blue-500 cursor-pointer text-white rounded-[10px] hover:bg-blue-600 transition-colors whitespace-nowrap"
style="border: none"
@click="handleSearch"
>
......
......@@ -2,6 +2,7 @@ let baseImageUrl;
if (process.env.NODE_ENV === "development") {
baseImageUrl = (path) => "http://192.168.19.142:9002" + path;
// baseImageUrl = (path) => "http://localhost:9002" + path;
} else {
baseImageUrl = (path) => "http://yjzh.sxyztech.cn" + path;
}
......
......@@ -17,7 +17,7 @@
<div class="flex-1 min-w-0">
<div class="flex items-center mb-1">
<h3
class="text-blue-600 hover:text-blue-800 cursor-pointer text-lg font-medium truncate mr-2"
class="text-blue-600 hover:text-blue-800 cursor-pointer text-lg font-medium truncate mr-2 line-clamp-2"
@click="goToDetail(item.id)"
>
{{ item.contentTitle }}
......
......@@ -95,12 +95,12 @@
<div>
<h3
class="text-lg font-medium mb-2 hover:text-blue-600 text-black"
class="text-lg font-medium mb-2 hover:text-blue-600 cursor-pointer text-black line-clamp-2"
@click="goToDetail(item)"
>
{{ item.contentTitle }}
</h3>
<p class="text-gray-600 text-sm line-clamp-2">
<p class="text-gray-600 text-sm line-clamp-3">
{{ item.contentDescription }}
</p>
<div class="mt-2 text-sm text-gray-500">
......@@ -132,7 +132,7 @@
class="border-b last:border-0 pb-4"
>
<h3
class="text-base font-medium hover:text-blue-600 cursor-pointer text-black"
class="text-base font-medium hover:text-blue-600 cursor-pointer text-black line-clamp-2"
@click="goToDetail(hot)"
>
{{ hot.contentTitle }}
......@@ -165,7 +165,7 @@
</div>
</div>
<h3
class="mt-2 text-base font-medium group-hover:text-blue-600 text-black"
class="mt-2 text-base font-medium group-hover:text-blue-600 text-black line-clamp-2"
>
{{ video.title }}
</h3>
......@@ -199,7 +199,7 @@
<!-- <el-icon class="text-blue-600 text-xl"><Document /></el-icon> -->
<div class="flex-1">
<h3
class="text-base font-medium hover:text-blue-600 cursor-pointer text-black"
class="text-base font-medium hover:text-blue-600 cursor-pointer text-black line-clamp-2"
>
{{ item.contentTitle }}
</h3>
......@@ -242,12 +242,12 @@
>辟谣</el-tag
>
<h3
class="text-base font-medium hover:text-blue-600 cursor-pointer text-black"
class="text-base font-medium hover:text-blue-600 cursor-pointer text-black line-clamp-2"
>
{{ item.contentTitle }}
</h3>
</div>
<p class="mt-1 text-sm text-gray-500 line-clamp-2">
<p class="mt-1 text-sm text-gray-500 line-clamp-3">
{{ item.contentDescription }}
</p>
</div>
......
......@@ -27,7 +27,7 @@
>
{{ news.contentTitle }}
</h2>
<p class="text-gray-600 text-sm line-clamp-2">
<p class="text-gray-600 text-sm line-clamp-3">
{{ news.contentDescription }}
</p>
<div class="mt-3 flex items-center space-x-4">
......
......@@ -27,7 +27,7 @@
>
{{ news.contentTitle }}
</h2>
<p class="text-gray-600 text-sm line-clamp-2">
<p class="text-gray-600 text-sm line-clamp-3">
{{ news.contentDescription }}
</p>
<div class="mt-3 flex items-center space-x-4">
......
......@@ -27,7 +27,7 @@
>
{{ news.contentTitle }}
</h2>
<p class="text-gray-600 text-sm line-clamp-2">
<p class="text-gray-600 text-sm line-clamp-3">
{{ news.contentDescription }}
</p>
<div class="mt-3 flex items-center space-x-4">
......
......@@ -19,7 +19,7 @@
class="w-full h-full object-cover object-top"
/>
</div>
<h3 class="text-lg font-semibold mb-2 text-black">
<h3 class="text-lg font-semibold mb-2 text-black line-clamp-2">
{{ card.contentTitle }}
</h3>
<p class="text-gray-600 text-sm">{{ card.contentDescription }}</p>
......
......@@ -25,7 +25,7 @@
<div class="flex items-center justify-between">
<div class="flex items-center text-sm text-gray-500">
<span>{{ item.contentDatetime }}</span>
<span class="mx-5">留言人:{{ item.name }}</span>
<span class="mx-5">留言人:***</span>
</div>
<el-tag
size="small"
......@@ -34,9 +34,11 @@
{{ item.replyStatus === "1" ? "已回复" : "未回复" }}
</el-tag>
</div>
<h4 class="text-gray-900 font-medium mt-3">{{ item.title }}</h4>
<h4 class="text-gray-900 font-medium mt-3 line-clamp-2">
{{ item.title }}
</h4>
<p class="mt-2 text-gray-700">{{ item.content }}</p>
<p class="mt-2 text-gray-700 line-clamp-3">{{ item.content }}</p>
</div>
</div>
</div>
......@@ -63,18 +65,20 @@
<div class="flex items-center justify-between mb-3">
<div class="flex-1">
<div class="flex items-center justify-between">
<h4 class="text-gray-900 font-medium">{{ item.title }}</h4>
<h4 class="text-gray-900 font-medium line-clamp-2">
{{ item.title }}
</h4>
<!-- <span class="text-gray-500 text-sm">{{
item.contentDatetime
}}</span> -->
<div class="flex items-center text-sm text-gray-500">
<span>{{ item.contentDatetime }}</span>
<span class="mx-5">留言人:{{ item.name }}</span>
<span class="mx-5">留言人:***</span>
</div>
</div>
</div>
</div>
<p class="text-gray-700">{{ item.content }}</p>
<p class="text-gray-700 line-clamp-3">{{ item.content }}</p>
</div>
</div>
</div>
......
......@@ -29,14 +29,24 @@
{{ detail.replyStatus === "1" ? "已回复" : "未回复" }}
</el-tag>
<span>留言人: {{ detail.name }}</span>
<span>留言人: ***</span>
<span>时间: {{ detail.contentDatetime }}</span>
</div>
</div>
<!-- 问题描述 -->
<div class="mb-6">
<div class="space-y-4 text-gray-600" v-html="detail.content"></div>
<!-- <div class="space-y-4 text-gray-600" v-html="detail.content"></div> -->
<el-input
type="textarea"
:rows="16"
disabled
:autosize="true"
v-model="detail.content"
:style="{ width: '100%', color: 'red' }"
placeholder="留言内容"
>
</el-input>
<!-- 附件区域 -->
<!-- <div
v-if="attachments.length > 0"
......@@ -123,7 +133,18 @@
<!-- 官方回复 -->
<div class="rounded-lg bg-gray-50 p-5" v-if="detail.reply != null">
<h2 class="mb-4 text-lg font-medium text-red-500">官方回复:</h2>
<div class="space-y-4 text-gray-600" v-html="detail.reply"></div>
<!-- <div type="textarea" class="space-y-4 text-gray-600" v-html="detail.reply"></div> -->
<el-input
type="textarea"
:rows="16"
disabled
:autosize="true"
v-model="detail.reply"
:style="{ width: '100%', color: 'red' }"
placeholder="留言内容"
>
</el-input>
</div>
</div>
</div>
......@@ -206,4 +227,15 @@ const handlePreview = (file: FileItem) => {
.min-h-screen {
min-height: 1024px;
}
:deep(.el-textarea.is-disabled .el-textarea__inner) {
color: #4b4b4b;
font-size: 15px;
padding: 20px;
line-height: 2;
}
:deep(.el-textarea) {
--el-input-border-color: #fff;
--el-input-border-color-hover: #fff;
}
</style>
......@@ -32,7 +32,9 @@
</h2> -->
<div class="flex justify-between items-start mb-1">
<h3 class="text-lg font-medium text-gray-900">{{ item.title }}</h3>
<h3 class="text-lg font-medium text-gray-900 line-clamp-2">
{{ item.title }}
</h3>
<span
:class="[
'px-3 py-1 rounded-full text-sm',
......@@ -44,10 +46,12 @@
>
</div>
<p class="text-gray-600 mb-4 leading-relaxed">{{ item.content }}</p>
<p class="text-gray-600 mb-4 leading-relaxed line-clamp-3">
{{ item.content }}
</p>
<div class="flex items-center text-sm text-gray-500">
<span>{{ item.contentDatetime }}</span>
<span class="mx-5">留言人:{{ item.name }}</span>
<span class="mx-5">留言人:***</span>
</div>
</div>
</div>
......
<!-- 代码已包含 CSS:使用 TailwindCSS , 安装 TailwindCSS 后方可看到布局样式效果 -->
<template>
<div class="bg-gray-50">
<div class="mx-auto w-[1440px] px-4">
<!-- 面包屑导航 -->
<div class="flex items-center justify-between py-2 border-b mb-5">
<bread-crumb :breadcrumbItems="breadcrumbItems" />
<!-- 搜索框 -->
<div class="relative">
<input
type="text"
v-model="searchText"
placeholder="搜索回复"
class="w-[300px] h-8 pl-4 pr-10 rounded-lg border-none bg-white shadow-sm focus:ring-2 focus:ring-blue-500 text-sm"
@keyup.enter="handleSearch"
/>
<el-icon
class="absolute left-3 top-1/2 -translate-y-1/2 text-gray-400"
><Search
/></el-icon>
</div>
<div class="mx-auto w-[1440px] px-4">
<!-- 面包屑导航 -->
<div class="flex items-center justify-between py-2 border-b mb-5">
<bread-crumb :breadcrumbItems="breadcrumbItems" />
<!-- 搜索框 -->
<div class="relative">
<input
type="text"
v-model="searchText"
placeholder="搜索回复"
class="w-[300px] h-8 pl-4 pr-10 rounded-lg border-none bg-white shadow-sm focus:ring-2 focus:ring-blue-500 text-sm"
@keyup.enter="handleSearch"
/>
<el-icon class="absolute left-3 top-1/2 -translate-y-1/2 text-gray-400"
><Search
/></el-icon>
</div>
<!-- 回复列表 -->
<div>
<div
v-for="(item, index) in recoverList"
:key="index"
class="bg-white rounded-lg p-6 mb-4 shadow-sm hover:shadow-md transition-shadow"
@click="clickList(item.id)"
>
<div class="flex justify-between items-start mb-1">
<h3 class="text-lg font-medium text-gray-900">{{ item.title }}</h3>
<span
:class="[
'px-3 py-1 rounded-full text-sm',
item.replyStatus === '1'
? 'bg-green-50 text-green-600'
: 'bg-orange-50 text-orange-600',
]"
>{{ item.replyStatus === "1" ? "已回复" : "未回复" }}</span
>
</div>
</div>
<!-- 回复列表 -->
<div>
<div
v-for="(item, index) in recoverList"
:key="index"
class="bg-white rounded-lg p-6 mb-4 shadow-sm hover:shadow-md transition-shadow"
@click="clickList(item.id)"
>
<div class="flex justify-between items-start mb-1">
<h3 class="text-lg font-medium text-gray-900 line-clamp-2">
{{ item.title }}
</h3>
<span
:class="[
'px-3 py-1 rounded-full text-sm',
item.replyStatus === '1'
? 'bg-green-50 text-green-600'
: 'bg-orange-50 text-orange-600',
]"
>{{ item.replyStatus === "1" ? "已回复" : "未回复" }}</span
>
</div>
<!-- <p class="text-gray-600 mb-4">{{ item.content }}</p>
<!-- <p class="text-gray-600 mb-4">{{ item.content }}</p>
<div class="text-sm text-gray-400">{{ item.contentDatetime }}</div> -->
<div class="flex items-center text-sm text-gray-500">
<span>{{ item.contentDatetime }}</span>
<span class="mx-5">留言人:{{ item.name }}</span>
</div>
<p class="mt-2 text-gray-700">{{ item.content }}</p>
<div class="flex items-center text-sm text-gray-500">
<span>{{ item.contentDatetime }}</span>
<span class="mx-5">留言人:***</span>
</div>
<p class="mt-2 text-gray-700 line-clamp-3">{{ item.content }}</p>
</div>
</div>
<!-- 分页 -->
<div class="flex justify-center mt-8">
<el-pagination
v-model:current-page="pageNo"
v-model:page-size="pageSize"
background
:total="total"
:page-sizes="[10, 20, 30, 40]"
layout="prev, pager, next"
@size-change="handleSizeChange"
@current-change="handleCurrentChange"
/>
</div>
<!-- 分页 -->
<div class="flex justify-center mt-8">
<el-pagination
v-model:current-page="pageNo"
v-model:page-size="pageSize"
background
:total="total"
:page-sizes="[10, 20, 30, 40]"
layout="prev, pager, next"
@size-change="handleSizeChange"
@current-change="handleCurrentChange"
/>
</div>
</div>
</template>
......
......@@ -28,9 +28,10 @@ export default defineConfig({
// 本地跨域代理 https://cn.vitejs.dev/config/server-options.html#server-proxy
proxy: {
"/cms": {
// target: "http://localhost:8081",
// target: "http://localhost:9002",
// target: "http://172.16.70.52:8081",
target: "http://192.168.19.142:9002",
// target: "http://192.168.19.127:9002",
changeOrigin: true,
// rewrite: (path) => path.replace(/^\/cms/, "/cms"),
},
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment