Browse Source

在线咨询,兽医端聊天功能优化

master
ZhaoYang 3 weeks ago
parent
commit
664b29b37b
  1. 1193
      chenhai-ui/src/views/muhu/consultation/index.vue
  2. 180
      chenhai-ui/src/views/system/questions/index.vue
  3. 480
      chenhai-ui/src/views/vet/chatManager/index.vue
  4. 12
      chenhai-ui/src/views/vet/comments/index.vue
  5. 8
      chenhai-ui/src/views/vet/plan/index.vue

1193
chenhai-ui/src/views/muhu/consultation/index.vue
File diff suppressed because it is too large
View File

180
chenhai-ui/src/views/system/questions/index.vue

@ -1,59 +1,33 @@
<template>
<div class="app-container">
<!-- 搜索区域 -->
<!-- <div class="search-area">-->
<!-- <el-form :model="queryParams" ref="queryForm" size="small" :inline="true" v-show="showSearch" label-width="80px">-->
<!-- <el-form-item>-->
<!-- <el-button type="primary" icon="el-icon-search" size="mini" @click="handleQuery">搜索</el-button>-->
<!-- <el-button icon="el-icon-refresh" size="mini" @click="resetQuery">重置</el-button>-->
<!-- </el-form-item>-->
<!-- </el-form>-->
<!-- </div>-->
<!-- 操作按钮区域-->
<!-- 搜索区域 -->
<!-- <div class="search-area">-->
<!-- <el-form :model="queryParams" ref="queryForm" size="small" :inline="true" v-show="showSearch" label-width="80px">-->
<!-- <el-form-item>-->
<!-- <el-button type="primary" icon="el-icon-search" size="mini" @click="handleQuery">搜索</el-button>-->
<!-- <el-button icon="el-icon-refresh" size="mini" @click="resetQuery">重置</el-button>-->
<!-- </el-form-item>-->
<!-- </el-form>-->
<!-- </div>-->
<!-- 操作按钮区域-->
<div class="operation-area">
<el-row :gutter="10" class="mb8">
<el-col :span="1.5">
<el-button
type="primary"
plain
icon="el-icon-plus"
size="mini"
@click="handleAdd"
v-hasPermi="['system:questions:add']"
>新增问题</el-button>
<el-button type="primary" plain icon="el-icon-plus" size="mini" @click="handleAdd"
v-hasPermi="['system:questions:add']">新增问题</el-button>
</el-col>
<el-col :span="1.5">
<el-button
type="success"
plain
icon="el-icon-edit"
size="mini"
:disabled="single"
@click="handleUpdate"
v-hasPermi="['system:questions:edit']"
>修改</el-button>
<el-button type="success" plain icon="el-icon-edit" size="mini" :disabled="single" @click="handleUpdate"
v-hasPermi="['system:questions:edit']">修改</el-button>
</el-col>
<el-col :span="1.5">
<el-button
type="danger"
plain
icon="el-icon-delete"
size="mini"
:disabled="multiple"
@click="handleDelete"
v-hasPermi="['system:questions:remove']"
>删除</el-button>
<el-button type="danger" plain icon="el-icon-delete" size="mini" :disabled="multiple" @click="handleDelete"
v-hasPermi="['system:questions:remove']">删除</el-button>
</el-col>
<el-col :span="1.5">
<el-button
type="warning"
plain
icon="el-icon-download"
size="mini"
@click="handleExport"
v-hasPermi="['system:questions:export']"
>导出</el-button>
<el-button type="warning" plain icon="el-icon-download" size="mini" @click="handleExport"
v-hasPermi="['system:questions:export']">导出</el-button>
</el-col>
<right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar>
</el-row>
@ -62,84 +36,45 @@
<!-- 问题列表 -->
<div class="main-content">
<div class="questions-list">
<el-table
v-loading="loading"
:data="questionsList"
@selection-change="handleSelectionChange"
@row-click="handleRowClick"
highlight-current-row
style="width: 100%"
height="calc(100vh - 260px)"
>
<el-table-column type="selection" width="55" align="center"/>
<el-table-column label="用户名" align="center" prop="username" width="150" :show-overflow-tooltip="true"/>
<el-table-column label="问题标题" align="center" prop="title" width="150" :show-overflow-tooltip="true">
<template slot-scope="scope">
<el-tooltip :content="scope.row.title" placement="top">
<span class="title-text">{{ scope.row.title }}</span>
</el-tooltip>
</template>
</el-table-column>
<el-table-column label="内容" align="center" prop="content" width="300" :show-overflow-tooltip="true">
<template slot-scope="scope">
<div class="content-preview" v-html="scope.row.content"></div>
</template>
</el-table-column>
<el-table-column label="图片" align="center" prop="images" width="100">
<el-table v-loading="loading" :data="questionsList" @selection-change="handleSelectionChange"
@row-click="handleRowClick" highlight-current-row style="width: 100%" height="calc(100vh - 260px)">
<el-table-column type="selection" width="55" align="center" />
<el-table-column label="用户名" align="center" prop="username" />
<el-table-column label="问题标题" align="center" prop="title" :show-overflow-tooltip="true" />
<el-table-column label="内容" align="center" prop="content" :show-overflow-tooltip="true">
<template slot-scope="scope">
<div class="content-preview" v-html="scope.row.content"></div>
</template>
</el-table-column>
<el-table-column label="图片" align="center" prop="images">
<template slot-scope="scope">
<image-preview :src="scope.row.images" :width="50" :height="50" />
</template>
</el-table-column>
<el-table-column label="标签" align="center" prop="tags" width="150">
<el-table-column label="标签" align="center" prop="tags">
<template slot-scope="scope">
<el-tag v-if="scope.row.tags" size="mini">{{ scope.row.tags }}</el-tag>
</template>
</el-table-column>
<el-table-column label="回复数" align="center" prop="answerCount" width="100"/>
<el-table-column label="浏览量" align="center" prop="viewCount" width="100"/>
<el-table-column label="创建时间" align="center" prop="createdAt" width="150" />
<el-table-column label="回复数" align="center" prop="answerCount" />
<el-table-column label="浏览量" align="center" prop="viewCount" />
<el-table-column label="创建时间" align="center" prop="createdAt" />
<el-table-column label="操作" align="center" fixed="right" width="300">
<template slot-scope="scope">
<el-button
size="mini"
type="text"
icon="el-icon-edit"
@click="handleUpdate(scope.row)"
style="color: #42B983"
v-hasPermi="['system:questions:edit']"
class="info-btn alter-btn"
>编辑</el-button>
<el-button
size="mini"
type="text"
icon="el-icon-chat-dot-round"
@click="openAnswersDialog(scope.row)"
style="color: #07368a"
v-hasPermi="['system:answers:view']"
class="info-btn chat-btn"
>回复</el-button>
<el-button
size="mini"
type="text"
icon="el-icon-delete"
@click="handleDelete(scope.row)"
style="color: #f56c6c"
v-hasPermi="['system:questions:remove']"
class="info-btn delete-btn"
>删除</el-button>
<el-button size="mini" type="text" icon="el-icon-edit" @click="handleUpdate(scope.row)"
style="color: #42B983" v-hasPermi="['system:questions:edit']" class="info-btn alter-btn">修改</el-button>
<el-button size="mini" type="text" icon="el-icon-chat-dot-round" @click="openAnswersDialog(scope.row)"
style="color: #07368a" v-hasPermi="['system:answers:view']" class="info-btn chat-btn">回复</el-button>
<el-button size="mini" type="text" icon="el-icon-delete" @click="handleDelete(scope.row)"
style="color: #f56c6c" v-hasPermi="['system:questions:remove']" class="info-btn delete-btn">删除</el-button>
</template>
</el-table-column>
</el-table>
<!-- 分页 -->
<div class="pagestyle">
<pagination
v-show="total>0"
:total="total"
:page.sync="queryParams.pageNum"
:limit.sync="queryParams.pageSize"
@pagination="getList"
/>
<pagination v-show="total > 0" :total="total" :page.sync="queryParams.pageNum"
:limit.sync="queryParams.pageSize" @pagination="getList" />
</div>
</div>
</div>
@ -167,22 +102,10 @@
</el-dialog>
<!-- 回复管理弹窗 -->
<el-dialog
:title="'回复管理 - ' + currentQuestionTitle"
:visible.sync="answersDialogVisible"
width="80%"
top="5vh"
append-to-body
class="answers-dialog"
>
<AnswersManagementDialog
ref="answersDialog"
:question-id="currentQuestionId"
:question-title="currentQuestionTitle"
:answer-count="currentAnswerCount"
@refresh="handleAnswersRefresh"
@close="answersDialogVisible = false"
/>
<el-dialog :title="'回复管理 - ' + currentQuestionTitle" :visible.sync="answersDialogVisible" width="80%" top="5vh"
append-to-body class="answers-dialog">
<AnswersManagementDialog ref="answersDialog" :question-id="currentQuestionId" :question-title="currentQuestionTitle"
:answer-count="currentAnswerCount" @refresh="handleAnswersRefresh" @close="answersDialogVisible = false" />
</el-dialog>
</div>
</template>
@ -362,7 +285,7 @@ export default {
if (this.currentQuestionId && ids.includes(this.currentQuestionId)) {
this.answersDialogVisible = false
}
}).catch(() => {})
}).catch(() => { })
},
/** 导出按钮操作 */
@ -404,6 +327,11 @@ export default {
}
}
</script>
<style>
.el-tooltip__popper {
width: 300px !important;
}
</style>
<style scoped>
.app-container {
@ -480,7 +408,7 @@ export default {
padding-bottom: 15px;
}
::v-deep .pagestyle .el-input{
::v-deep .pagestyle .el-input {
width: auto !important;
}
</style>
@ -499,7 +427,7 @@ export default {
transform: translateY(-1px);
}
.alter-btn:hover{
.alter-btn:hover {
background-color: rgb(230, 255, 238);
transform: translateY(-1px);
}

480
chenhai-ui/src/views/vet/chatManager/index.vue

@ -50,7 +50,8 @@
:src="session.otherUserAvatar"
:style="{ backgroundColor: getAvatarColor(session.otherUserName) }"
>
{{ getAvatarText(session.otherUserName) }}
<!-- {{ getAvatarText(session.otherUserName) }} -->
<img :src="baseUrl+session.otherUserAvatar" alt="">
</el-avatar>
<span
class="online-status"
@ -176,7 +177,6 @@
<span v-if="message.isRead === 1" class="read-status">已读</span>
<span v-else-if="message.temp" class="read-status">发送中</span>
<span v-else-if="message.failed" class="read-status" style="color: #F56C6C;">失败</span>
<span v-else class="read-status">未读</span>
</div>
</div>
</div>
@ -281,7 +281,8 @@ export default {
lastHeartbeatTime: null,
wsRetryCount: 0,
maxRetries: 3,
shouldAutoScroll: true
shouldAutoScroll: true,
baseUrl:process.env.VUE_APP_BASE_API
}
},
@ -942,53 +943,110 @@ export default {
</script>
<style scoped>
/* 全局容器优化 */
.app-container {
height: calc(100vh - 84px);
padding: 20px;
background: #f0f2f5;
background: linear-gradient(135deg, #f5f7fa 0%, #eef2f6 100%);
}
/* 页面标题优化 */
.page-header {
display: flex;
justify-content: space-between;
align-items: center;
margin-bottom: 20px;
padding: 0 8px;
}
.page-header h2 {
margin: 0;
font-size: 24px;
font-weight: 600;
color: #303133;
background: linear-gradient(135deg, #303133 0%, #606266 100%);
-webkit-background-clip: text;
-webkit-text-fill-color: transparent;
background-clip: text;
letter-spacing: 0.5px;
}
.header-actions .el-button {
border-radius: 20px;
transition: all 0.3s ease;
box-shadow: 0 2px 6px rgba(64, 158, 255, 0.2);
}
.header-actions .el-button:hover {
transform: translateY(-1px);
box-shadow: 0 4px 12px rgba(64, 158, 255, 0.3);
}
/* 聊天主容器优化 */
.chat-container {
height: calc(100vh - 140px);
border-radius: 12px;
border-radius: 20px;
overflow: hidden;
background: white;
box-shadow: 0 2px 12px 0 rgba(0, 0, 0, 0.1);
box-shadow: 0 8px 24px rgba(0, 0, 0, 0.08), 0 2px 4px rgba(0, 0, 0, 0.02);
transition: box-shadow 0.3s ease;
}
.chat-container:hover {
box-shadow: 0 12px 32px rgba(0, 0, 0, 0.12);
}
/* 左侧会话列表优化 */
.chat-sidebar {
display: flex;
flex-direction: column;
border-right: 1px solid #e4e7ed;
background: #fff;
background: #ffffff;
border-right: 1px solid rgba(228, 231, 237, 0.6);
transition: background 0.3s ease;
}
/* 搜索区域优化 */
.search-container {
padding: 16px;
border-bottom: 1px solid #e4e7ed;
padding: 20px 16px;
border-bottom: 1px solid #f0f2f5;
background: #ffffff;
}
.search-container .el-input__inner {
border-radius: 24px;
background: #f5f7fa;
border: 1px solid transparent;
transition: all 0.3s ease;
}
.search-container .el-input__inner:focus {
background: #ffffff;
border-color: #409eff;
box-shadow: 0 0 0 3px rgba(64, 158, 255, 0.1);
}
/* 会话列表区域优化 */
.session-list {
flex: 1;
overflow-y: auto;
position: relative;
min-height: 200px;
scroll-behavior: smooth;
}
.session-list::-webkit-scrollbar {
width: 4px;
}
.session-list::-webkit-scrollbar-track {
background: #f5f7fa;
}
.session-list::-webkit-scrollbar-thumb {
background: #dcdfe6;
border-radius: 4px;
}
.session-list::-webkit-scrollbar-thumb:hover {
background: #c0c4cc;
}
/* 空状态优化 */
.empty-state {
display: flex;
flex-direction: column;
@ -996,63 +1054,104 @@ export default {
justify-content: center;
height: 300px;
color: #909399;
animation: fadeIn 0.5s ease;
}
.empty-state .empty-icon {
font-size: 64px;
margin-bottom: 16px;
color: #c0c4cc;
font-size: 72px;
margin-bottom: 20px;
color: #dcdfe6;
transition: transform 0.3s ease;
}
.empty-state .empty-icon:hover {
transform: scale(1.05);
}
.empty-state .empty-text {
margin: 0;
font-size: 14px;
font-weight: 400;
}
/* 会话项优化 */
.session-items {
padding: 8px 0;
}
.session-item {
display: flex;
padding: 12px 16px;
padding: 14px 16px;
cursor: pointer;
transition: all 0.3s;
border-bottom: 1px solid #f5f5f5;
transition: all 0.25s ease;
border-bottom: 1px solid #f5f7fa;
position: relative;
margin: 2px 0;
}
.session-item:hover {
background-color: #f5f7fa;
background: linear-gradient(90deg, #f8f9fc 0%, #f5f7fa 100%);
transform: translateX(2px);
}
.session-item.active {
background-color: #ecf5ff;
background: linear-gradient(90deg, #ecf5ff 0%, #e8f0fe 100%);
border-right: 3px solid #409eff;
}
.session-item.active::before {
content: '';
position: absolute;
left: 0;
top: 0;
bottom: 0;
width: 3px;
background: #409eff;
}
/* 头像容器优化 */
.avatar-container {
position: relative;
margin-right: 12px;
margin-right: 14px;
transition: transform 0.2s ease;
}
.session-item:hover .avatar-container {
transform: scale(1.02);
}
/* 在线状态指示器优化 */
.online-status {
position: absolute;
bottom: 2px;
right: 2px;
width: 10px;
height: 10px;
width: 12px;
height: 12px;
border-radius: 50%;
border: 2px solid white;
transition: transform 0.2s ease;
}
.online-status.online {
background-color: #67c23a;
box-shadow: 0 0 0 2px rgba(103, 194, 58, 0.2);
animation: pulseOnline 1.5s infinite;
}
.online-status.offline {
background-color: #c0c4cc;
}
@keyframes pulseOnline {
0%, 100% {
box-shadow: 0 0 0 0 rgba(103, 194, 58, 0.4);
}
50% {
box-shadow: 0 0 0 3px rgba(103, 194, 58, 0.2);
}
}
/* 会话信息优化 */
.session-info {
flex: 1;
min-width: 0;
@ -1061,48 +1160,62 @@ export default {
.info-header {
display: flex;
justify-content: space-between;
align-items: center;
margin-bottom: 4px;
align-items: baseline;
margin-bottom: 6px;
}
.session-name {
font-weight: 500;
font-size: 14px;
font-weight: 600;
font-size: 15px;
color: #303133;
overflow: hidden;
text-overflow: ellipsis;
white-space: nowrap;
letter-spacing: -0.2px;
}
.session-time {
font-size: 12px;
color: #909399;
font-size: 11px;
color: #b0b3bc;
font-weight: 400;
}
.session-preview {
display: flex;
justify-content: space-between;
align-items: flex-start;
align-items: center;
gap: 8px;
}
.preview-text {
flex: 1;
font-size: 13px;
color: #606266;
color: #909399;
overflow: hidden;
text-overflow: ellipsis;
white-space: nowrap;
margin-right: 8px;
margin: 0;
line-height: 1.4;
}
.unread-badge {
flex-shrink: 0;
/* 未读徽章优化 */
.unread-badge >>> .el-badge__content {
background: #f56c6c;
border: none;
font-size: 11px;
padding: 0 5px;
height: 18px;
line-height: 18px;
border-radius: 9px;
box-shadow: 0 2px 4px rgba(245, 108, 108, 0.3);
}
/* 右侧聊天区域优化 */
.chat-main {
padding: 0;
display: flex;
flex-direction: column;
background: #f8f9fc;
}
.chat-content {
@ -1110,15 +1223,30 @@ export default {
display: flex;
flex-direction: column;
height: 100%;
animation: slideIn 0.3s ease;
}
@keyframes slideIn {
from {
opacity: 0;
transform: translateX(10px);
}
to {
opacity: 1;
transform: translateX(0);
}
}
/* 聊天头部优化 */
.chat-header {
display: flex;
justify-content: space-between;
align-items: center;
padding: 16px 20px;
border-bottom: 1px solid #e4e7ed;
background: white;
padding: 16px 24px;
border-bottom: 1px solid rgba(228, 231, 237, 0.6);
background: #ffffff;
backdrop-filter: blur(10px);
box-shadow: 0 1px 4px rgba(0, 0, 0, 0.02);
}
.header-left {
@ -1128,13 +1256,14 @@ export default {
}
.header-info {
margin-left: 12px;
margin-left: 14px;
}
.header-info .chat-title {
margin: 0 0 4px 0;
font-size: 16px;
font-weight: 500;
margin: 0 0 6px 0;
font-size: 18px;
font-weight: 600;
color: #303133;
}
.chat-subtitle {
@ -1144,145 +1273,235 @@ export default {
}
.status-text {
display: flex;
display: inline-flex;
align-items: center;
font-size: 12px;
padding: 4px 8px;
border-radius: 20px;
background: #f5f7fa;
color: #909399;
transition: all 0.2s ease;
}
.status-text.online {
background: rgba(103, 194, 58, 0.1);
color: #67c23a;
}
.status-icon {
margin-right: 4px;
font-size: 12px;
}
/* 消息容器优化 */
.message-container {
flex: 1;
position: relative;
overflow: hidden;
background: #f5f7fa;
background: #f8f9fc;
}
.message-list {
height: 100%;
padding: 20px;
padding: 20px 24px;
overflow-y: auto;
scroll-behavior: smooth;
}
.message-list::-webkit-scrollbar {
width: 6px;
}
.message-list::-webkit-scrollbar-track {
background: #e9ecef;
border-radius: 3px;
}
.message-list::-webkit-scrollbar-thumb {
background: #cbd5e0;
border-radius: 3px;
}
.message-list::-webkit-scrollbar-thumb:hover {
background: #a0aec0;
}
/* 加载更多提示优化 */
.load-more-hint {
text-align: center;
padding: 10px;
color: #909399;
padding: 12px;
color: #409eff;
font-size: 12px;
cursor: pointer;
transition: all 0.2s ease;
border-radius: 20px;
margin: 8px auto;
width: fit-content;
background: rgba(64, 158, 255, 0.05);
}
.load-more-hint:hover {
color: #409eff;
background: rgba(64, 158, 255, 0.1);
transform: scale(1.02);
}
.loading-more {
text-align: center;
padding: 10px;
padding: 12px;
color: #909399;
font-size: 12px;
}
.message-item-wrapper {
margin-bottom: 16px;
}
/* 消息时间分隔线优化 */
.message-time-divider {
text-align: center;
margin: 16px 0;
margin: 20px 0;
position: relative;
}
.time-text {
font-size: 12px;
color: #909399;
background: #f5f5f5;
padding: 4px 12px;
border-radius: 12px;
font-size: 11px;
color: #a0aec0;
background: rgba(224, 230, 237, 0.6);
padding: 4px 14px;
border-radius: 20px;
backdrop-filter: blur(4px);
letter-spacing: 0.3px;
}
/* 消息项优化 */
.message-item-wrapper {
margin-bottom: 20px;
animation: messageFadeIn 0.3s ease;
}
@keyframes messageFadeIn {
from {
opacity: 0;
transform: translateY(8px);
}
to {
opacity: 1;
transform: translateY(0);
}
}
/* ===== 完全重构的消息样式 ===== */
/* 消息布局优化 */
.message-item {
display: flex;
width: 100%;
margin-bottom: 16px;
margin-bottom: 4px;
}
/* 头像盒子固定宽度 */
/* 头像盒子 */
.avatar-box {
width: 36px;
flex-shrink: 0;
}
/* 内容盒子自适应 */
/* 内容盒子优化 */
.content-box {
flex: 1;
padding: 0 10px;
padding: 0 12px;
}
/* 气泡基础样式 */
/* 气泡优化 */
.bubble {
display: inline-block;
max-width: 80%;
padding: 10px 14px;
border-radius: 18px;
padding: 10px 16px;
border-radius: 20px;
word-break: break-word;
position: relative;
box-shadow: 0 1px 2px rgba(0, 0, 0, 0.1);
box-shadow: 0 1px 3px rgba(0, 0, 0, 0.08);
transition: all 0.2s ease;
font-size: 14px;
line-height: 1.5;
}
/* 自己消息的气泡 */
.bubble:hover {
transform: translateY(-1px);
box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}
/* 自己消息气泡优化 */
.me-bubble {
background: #95ec69;
border-top-right-radius: 4px;
background: linear-gradient(135deg, #95ec69 0%, #85d85a 100%);
border-top-right-radius: 6px;
text-align: left;
color: #1e2a3a;
}
/* 对方消息气泡 */
/* 对方消息气泡优化 */
.other-bubble {
background: white;
border-top-left-radius: 4px;
background: #ffffff;
border-top-left-radius: 6px;
text-align: left;
color: #2c3e50;
box-shadow: 0 2px 8px rgba(0, 0, 0, 0.04);
}
/* 时间显示 */
/* 时间信息优化 */
.time {
font-size: 11px;
color: #909399;
margin-top: 4px;
text-align: right;
font-size: 10px;
color: rgba(0, 0, 0, 0.45);
margin-top: 6px;
display: flex;
align-items: center;
justify-content: flex-end;
gap: 6px;
}
.me-bubble .time {
color: rgba(0, 0, 0, 0.5);
}
.other-bubble .time {
color: #94a3b8;
}
.read-status {
margin-left: 4px;
font-size: 10px;
font-weight: 400;
}
/* 输入区域优化 */
.input-container {
border-top: 1px solid #e4e7ed;
background: white;
border-top: 1px solid rgba(228, 231, 237, 0.6);
background: #ffffff;
backdrop-filter: blur(10px);
}
.input-area {
padding: 12px 20px;
padding: 16px 24px;
}
.message-input >>> .el-textarea__inner {
border: none;
border-radius: 8px;
background: #f5f7fa;
padding-right: 100px;
border: 1px solid #e2e8f0;
border-radius: 16px;
background: #fafbfc;
padding: 12px 80px 12px 16px;
resize: none;
font-size: 14px;
transition: all 0.3s ease;
}
.message-input >>> .el-textarea__inner:focus {
background: white;
box-shadow: 0 0 0 1px #409eff inset;
background: #ffffff;
border-color: #409eff;
box-shadow: 0 0 0 3px rgba(64, 158, 255, 0.1);
}
.message-input >>> .el-textarea__inner:hover {
border-color: #cbd5e0;
}
.message-input >>> .el-textarea .el-textarea__count {
background: transparent;
bottom: 8px;
right: 12px;
font-size: 11px;
}
.input-actions {
@ -1290,36 +1509,101 @@ export default {
align-items: center;
justify-content: flex-end;
height: 100%;
gap: 12px;
}
.send-button {
height: 32px;
padding: 0 20px;
height: 38px;
padding: 0 28px;
border-radius: 24px;
font-weight: 500;
transition: all 0.3s ease;
background: linear-gradient(135deg, #409eff 0%, #3a8ee6 100%);
border: none;
box-shadow: 0 2px 6px rgba(64, 158, 255, 0.3);
}
.send-button:hover:not(:disabled) {
transform: translateY(-2px);
box-shadow: 0 4px 12px rgba(64, 158, 255, 0.4);
}
.send-button:active:not(:disabled) {
transform: translateY(0);
}
/* 空聊天状态优化 */
.empty-chat {
flex: 1;
display: flex;
align-items: center;
justify-content: center;
background: #f5f7fa;
background: linear-gradient(135deg, #f8f9fc 0%, #f1f5f9 100%);
}
.empty-content {
text-align: center;
max-width: 400px;
animation: fadeInUp 0.5s ease;
}
@keyframes fadeInUp {
from {
opacity: 0;
transform: translateY(20px);
}
to {
opacity: 1;
transform: translateY(0);
}
}
.empty-content .empty-icon {
font-size: 64px;
color: #c0c4cc;
margin-bottom: 20px;
font-size: 80px;
color: #cbd5e0;
margin-bottom: 24px;
transition: transform 0.3s ease;
}
.empty-content .empty-icon:hover {
transform: scale(1.05);
color: #94a3b8;
}
.empty-content .empty-title {
margin: 0;
font-size: 20px;
font-size: 18px;
font-weight: 500;
color: #303133;
color: #64748b;
letter-spacing: -0.2px;
}
/* 通用动画 */
@keyframes fadeIn {
from {
opacity: 0;
}
to {
opacity: 1;
}
}
/* 响应式调整 */
@media (max-width: 768px) {
.app-container {
padding: 12px;
}
.chat-sidebar {
width: 280px !important;
}
.bubble {
max-width: 90%;
}
.message-list {
padding: 16px;
}
}
</style>

12
chenhai-ui/src/views/vet/comments/index.vue

@ -9,7 +9,7 @@
</el-form> -->
<!-- 工具栏 -->
<el-row :gutter="10" class="mb8">
<!-- <el-row :gutter="10" class="mb8">
<el-col :span="1.5">
<el-button
type="primary"
@ -21,7 +21,7 @@
>新增回复</el-button>
</el-col>
<right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar>
</el-row>
</el-row> -->
<!-- 表格 -->
<el-table v-loading="loading" :data="commentsList" @selection-change="handleSelectionChange">
@ -33,8 +33,10 @@
</el-table-column>
<el-table-column label="回复者" align="center" prop="replyName" />
<el-table-column label="职称" align="center" prop="title" />
<el-table-column label="从属医院" align="center" prop="hospital" :show-overflow-tooltip="true"/>
<el-table-column label="专家类型" align="center" prop="expertType" />
<el-table-column label="擅长领域" align="center" prop="specialty" />
<el-table-column label="从业经验" align="center" prop="experience"/>
<el-table-column label="从属医院" align="center" prop="hospital" :show-overflow-tooltip="true"/>
<el-table-column label="回复内容" align="center" prop="content" :show-overflow-tooltip="true"/>
<el-table-column label="回复图片" align="center" prop="images" >
<template slot-scope="scope">
@ -46,7 +48,7 @@
<span>{{ parseTime(scope.row.createdAt, '{y}-{m}-{d}') }}</span>
</template>
</el-table-column>
<el-table-column label="操作" align="center" class-name="small-padding fixed-width" fixed="right" >
<!-- <el-table-column label="操作" align="center" class-name="small-padding fixed-width" fixed="right" >
<template slot-scope="scope">
<el-button
size="mini"
@ -67,7 +69,7 @@
class="info-btn delete-btn"
>删除</el-button>
</template>
</el-table-column>
</el-table-column> -->
</el-table>
<!-- 分页 -->

8
chenhai-ui/src/views/vet/plan/index.vue

@ -23,7 +23,7 @@
</el-form-item>
</el-form>
<el-row :gutter="10" class="mb8">
<!-- <el-row :gutter="10" class="mb8">
<el-col :span="1.5">
<el-button
type="primary"
@ -67,7 +67,7 @@
>导出</el-button>
</el-col>
<right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar>
</el-row>
</el-row> -->
<el-table v-loading="loading" :data="planList" @selection-change="handleSelectionChange">
<el-table-column type="selection" width="55" align="center" />
@ -86,7 +86,7 @@
v-hasPermi="['vet:comments:list']"
class="info-btn view-btn"
>详情</el-button>
<el-button
<!-- <el-button
size="mini"
type="text"
icon="el-icon-edit"
@ -103,7 +103,7 @@
style="color: #f56c6c"
v-hasPermi="['vet:plan:remove']"
class="info-btn delete-btn"
>删除</el-button>
>删除</el-button> -->
</template>
</el-table-column>
</el-table>

Loading…
Cancel
Save