diff --git a/app.json b/app.json
index 337f3eb..dedf6ec 100644
--- a/app.json
+++ b/app.json
@@ -9,7 +9,9 @@
{
"root": "pagesA",
"pages": [
- "pages/carouselDetail/carouselDetail"
+ "pages/carouselDetail/carouselDetail",
+ "pages/askingSy/askingSy",
+ "pages/askingSyDetails/askingSyDetails"
]
},
{
diff --git a/pages/home/home.js b/pages/home/home.js
index d76aa24..50c0168 100644
--- a/pages/home/home.js
+++ b/pages/home/home.js
@@ -40,6 +40,13 @@ Page({
})
},
+ // 远程诊疗
+ bindYczl() {
+ wx.navigateTo({
+ url: '/pagesA/pages/askingSy/askingSy',
+ })
+ },
+
// 在线问答列表
getforumList() {
diff --git a/pages/home/home.wxml b/pages/home/home.wxml
index da8165c..3e1b99e 100644
--- a/pages/home/home.wxml
+++ b/pages/home/home.wxml
@@ -53,7 +53,7 @@
快捷回复
-
+
远程诊疗
足不出户方便快捷
diff --git a/pagesA/images/kzt.png b/pagesA/images/kzt.png
new file mode 100644
index 0000000..39886b6
Binary files /dev/null and b/pagesA/images/kzt.png differ
diff --git a/pagesA/pages/askingSy/askingSy.js b/pagesA/pages/askingSy/askingSy.js
new file mode 100644
index 0000000..025df01
--- /dev/null
+++ b/pagesA/pages/askingSy/askingSy.js
@@ -0,0 +1,66 @@
+import http from '../../../utils/api'
+Page({
+ data: {
+ diagnosisList: []
+ },
+
+ onLoad: function () {
+
+ },
+
+ onShow:function(){
+ this.getwzd()
+ },
+
+
+ // 问诊单
+ getwzd() {
+ http.wzd({
+ data: {},
+ success: res => {
+ console.log(1111, res);
+ this.setData({
+ diagnosisList: res.rows
+ })
+ }
+ })
+ },
+
+
+
+ // 格式化日期显示
+ formatDate: function (dateString) {
+ const date = new Date(dateString);
+ const now = new Date();
+ const diff = now - date;
+ const diffDays = Math.floor(diff / (1000 * 60 * 60 * 24));
+ const diffHours = Math.floor(diff / (1000 * 60 * 60));
+ const diffMinutes = Math.floor(diff / (1000 * 60));
+
+ if (diffMinutes < 60) {
+ return `${diffMinutes}分钟前`;
+ } else if (diffHours < 24) {
+ return `${diffHours}小时前`;
+ } else if (diffDays === 1) {
+ return '昨天';
+ } else if (diffDays === 2) {
+ return '前天';
+ } else if (diffDays < 7) {
+ return `${diffDays}天前`;
+ } else {
+ const month = date.getMonth() + 1;
+ const day = date.getDate();
+ return `${month}月${day}日`;
+ }
+ },
+
+
+ // 查看详情
+ viewDetail: function (e) {
+ const data = e.currentTarget.dataset.value
+ wx.navigateTo({
+ url: `/pagesA/pages/askingSyDetails/askingSyDetails?data=${encodeURIComponent(JSON.stringify(data))}`,
+ });
+ },
+
+});
\ No newline at end of file
diff --git a/pagesA/pages/askingSy/askingSy.json b/pagesA/pages/askingSy/askingSy.json
new file mode 100644
index 0000000..bd4f970
--- /dev/null
+++ b/pagesA/pages/askingSy/askingSy.json
@@ -0,0 +1,4 @@
+{
+ "navigationBarTitleText":"问诊单列表",
+ "usingComponents": {}
+}
\ No newline at end of file
diff --git a/pagesA/pages/askingSy/askingSy.wxml b/pagesA/pages/askingSy/askingSy.wxml
new file mode 100644
index 0000000..9c89855
--- /dev/null
+++ b/pagesA/pages/askingSy/askingSy.wxml
@@ -0,0 +1,98 @@
+
+
+
+
+
+
+
+
+
+ 暂无问诊记录
+ 开始您的第一次问诊吧
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ 牲畜信息
+
+
+
+
+
+
+ {{item.animalType}}
+
+
+ {{item.animalAge}}
+
+
+ {{item.animalGender}}
+
+
+
+
+
+
+
+ {{item.description}}
+
+
+
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/pagesA/pages/askingSy/askingSy.wxss b/pagesA/pages/askingSy/askingSy.wxss
new file mode 100644
index 0000000..b9c6ccf
--- /dev/null
+++ b/pagesA/pages/askingSy/askingSy.wxss
@@ -0,0 +1,428 @@
+/* 全局样式 */
+.wzbox{
+ min-height: 100vh;
+ position: relative;
+ background: linear-gradient(180deg, #F8FBFF 0%, #F0F7FF 100%);
+}
+
+/* 头部样式优化 */
+.header {
+ padding: 20rpx 40rpx 20rpx;
+ background: linear-gradient(135deg, #6D9EFF 0%, #4A7CFF 100%);
+ border-radius: 0 0 36rpx 36rpx;
+ box-shadow: 0 4rpx 20rpx rgba(74, 144, 226, 0.15);
+ position: relative;
+ overflow: hidden;
+}
+
+.header-content {
+ position: relative;
+ z-index: 2;
+}
+
+.title-section {
+ display: flex;
+ flex-direction: column;
+ gap: 8rpx;
+}
+
+.title {
+ font-size: 44rpx;
+ font-weight: 700;
+ color: #FFFFFF;
+ letter-spacing: 0.5rpx;
+ text-shadow: 0 2rpx 8rpx rgba(0, 0, 0, 0.1);
+}
+
+.subtitle {
+ font-size: 28rpx;
+ color: rgba(255, 255, 255, 0.9);
+ font-weight: 400;
+}
+
+/* 头部装饰元素 */
+.header-decoration {
+ position: absolute;
+ top: 0;
+ left: 0;
+ right: 0;
+ bottom: 0;
+ overflow: hidden;
+ z-index: 1;
+}
+
+.decoration-circle {
+ position: absolute;
+ border-radius: 50%;
+ background: rgba(255, 255, 255, 0.08);
+}
+
+.circle-1 {
+ width: 200rpx;
+ height: 200rpx;
+ top: -80rpx;
+ right: -40rpx;
+}
+
+.circle-2 {
+ width: 120rpx;
+ height: 120rpx;
+ bottom: -40rpx;
+ left: -20rpx;
+}
+
+/* 问诊记录列表 */
+.record-list {
+ height: calc(100vh - 200rpx);
+ padding: 0 32rpx 20rpx;
+ box-sizing: border-box;
+}
+
+.records-container {
+ padding-top: 24rpx;
+}
+
+/* 列表头部 */
+.section-header {
+ display: flex;
+ justify-content: space-between;
+ align-items: center;
+ margin-bottom: 24rpx;
+ padding: 0 4rpx;
+}
+
+.section-title {
+ font-size: 32rpx;
+ font-weight: 700;
+ color: #1A1A1A;
+ position: relative;
+ padding-left: 16rpx;
+}
+
+.section-title::before {
+ content: '';
+ position: absolute;
+ left: 0;
+ top: 50%;
+ transform: translateY(-50%);
+ width: 4rpx;
+ height: 20rpx;
+ background: linear-gradient(180deg, #6D9EFF 0%, #4A7CFF 100%);
+ border-radius: 2rpx;
+}
+
+.section-count {
+ font-size: 26rpx;
+ color: #666;
+ background: #F0F7FF;
+ padding: 6rpx 16rpx;
+ border-radius: 16rpx;
+ font-weight: 500;
+}
+
+/* 问诊记录卡片 */
+.record-card {
+ background: #FFFFFF;
+ border-radius: 24rpx;
+ margin-bottom: 24rpx;
+ box-shadow: 0 6rpx 24rpx rgba(74, 144, 226, 0.08);
+ position: relative;
+ overflow: hidden;
+ transition: all 0.3s cubic-bezier(0.2, 0, 0.2, 1);
+ border: 1rpx solid #F0F7FF;
+}
+
+.record-card:active {
+ transform: translateY(-2rpx);
+ box-shadow: 0 10rpx 30rpx rgba(74, 144, 226, 0.15);
+}
+
+/* 卡片头部 */
+.card-header {
+ display: flex;
+ justify-content: space-between;
+ align-items: center;
+ padding: 24rpx 28rpx;
+ border-bottom: 1rpx solid #F5F9FF;
+}
+
+.user-section {
+ display: flex;
+ align-items: center;
+ gap: 16rpx;
+ flex: 1;
+}
+
+.user-avatar {
+ width: 60rpx;
+ height: 60rpx;
+ border-radius: 50%;
+ border: 2rpx solid rgba(255, 255, 255, 0.8);
+ box-shadow: 0 2rpx 12rpx rgba(0, 0, 0, 0.08);
+}
+
+.user-name {
+ font-size: 28rpx;
+ color: #1A1A1A;
+ font-weight: 600;
+}
+
+/* 状态标签 */
+.status-tag {
+ padding: 8rpx 20rpx;
+ border-radius: 20rpx;
+ font-size: 22rpx;
+ font-weight: 600;
+ min-width: 80rpx;
+ text-align: center;
+ flex-shrink: 0;
+}
+
+.status-replied {
+ background: linear-gradient(135deg, rgba(76, 217, 100, 0.12) 0%, rgba(46, 204, 113, 0.12) 100%);
+ color: #2ECC71;
+ border: 1rpx solid rgba(46, 204, 113, 0.2);
+}
+
+.status-pending {
+ background: linear-gradient(135deg, rgba(255, 149, 0, 0.12) 0%, rgba(255, 127, 0, 0.12) 100%);
+ color: #FF9500;
+ border: 1rpx solid rgba(255, 149, 0, 0.2);
+}
+
+/* 牲畜信息 */
+.livestock-section {
+ padding: 20rpx 28rpx;
+}
+
+/* 牲畜信息标题优化 */
+.livestock-title-wrapper {
+ display: flex;
+ align-items: center;
+ justify-content: center;
+ margin-bottom: 20rpx;
+ position: relative;
+}
+
+.livestock-title-line {
+ flex: 1;
+ height: 2rpx;
+ background: linear-gradient(90deg, transparent, #4A7CFF 50%, transparent);
+ opacity: 0.3;
+}
+
+.livestock-title-content {
+ display: flex;
+ align-items: center;
+ gap: 12rpx;
+ padding: 0 20rpx;
+ position: relative;
+}
+
+.livestock-title-text {
+ font-size: 30rpx;
+ font-weight: 700;
+ color: #333;
+ background: linear-gradient(135deg, #4A7CFF 0%, #8CB4FF 100%);
+ -webkit-background-clip: text;
+ -webkit-text-fill-color: transparent;
+ background-clip: text;
+ text-shadow: 0 2rpx 4rpx rgba(74, 124, 255, 0.1);
+ letter-spacing: 1rpx;
+}
+
+
+@keyframes cowPulse {
+ 0%, 100% {
+ transform: scale(1) rotate(0deg);
+ }
+ 50% {
+ transform: scale(1.1) rotate(5deg);
+ }
+}
+
+.livestock-tags {
+ display: flex;
+ gap: 16rpx;
+ flex-wrap: wrap;
+}
+
+.livestock-tag {
+ padding: 5rpx 20rpx;
+ border-radius: 20rpx;
+ font-size: 26rpx;
+ font-weight: 600;
+ display: flex;
+ align-items: center;
+ justify-content: center;
+ box-shadow: 0 2rpx 8rpx rgba(0, 0, 0, 0.1);
+}
+
+.type-tag {
+ background: linear-gradient(135deg, #6D9EFF 0%, #4A7CFF 100%);
+ color: #FFFFFF;
+ border: 2rpx solid rgba(255, 255, 255, 0.3);
+}
+
+.age-tag {
+ background: linear-gradient(135deg, #FFB347 0%, #FFA033 100%);
+ color: #FFFFFF;
+ border: 2rpx solid rgba(255, 255, 255, 0.3);
+}
+
+.gender-tag {
+ background: linear-gradient(135deg, #42E695 0%, #3BB2B8 100%);
+ color: #FFFFFF;
+ border: 2rpx solid rgba(255, 255, 255, 0.3);
+}
+
+.tag-text {
+ font-size: 26rpx;
+ font-weight: 600;
+ color: #FFFFFF;
+}
+
+/* 症状描述 */
+.symptom-section {
+ padding: 24rpx 28rpx 28rpx;
+}
+
+.symptom-content {
+ background: #F9FAFF;
+ padding: 20rpx 24rpx;
+ border-radius: 16rpx;
+ border: 1rpx solid #E6ECFF;
+ position: relative;
+}
+
+.symptom-content::before {
+ content: '症状描述';
+ position: absolute;
+ top: -12rpx;
+ left: 24rpx;
+ background: #FFFFFF;
+ padding: 0 12rpx;
+ font-size: 24rpx;
+ font-weight: 600;
+ color: #4A7CFF;
+ z-index: 1;
+}
+
+.symptom-text {
+ font-size: 28rpx;
+ color: #333;
+ line-height: 1.6;
+ font-weight: 400;
+}
+
+/* 卡片底部 */
+.card-footer {
+ display: flex;
+ justify-content: space-between;
+ align-items: center;
+ padding: 20rpx 28rpx;
+ border-top: 1rpx solid #F5F9FF;
+}
+
+.time-info {
+ display: flex;
+ align-items: center;
+ gap: 8rpx;
+}
+
+.time-text {
+ font-size: 24rpx;
+ color: #999;
+ font-weight: 400;
+}
+
+.reply-info {
+ display: flex;
+ align-items: center;
+ gap: 8rpx;
+ padding: 8rpx 16rpx;
+ background: #F0F7FF;
+ border-radius: 16rpx;
+ border: 1rpx solid #E5EFFF;
+}
+
+.reply-count {
+ font-size: 24rpx;
+ font-weight: 500;
+ color: #4A7CFF;
+}
+
+/* 空状态优化 */
+.empty-state {
+ display: flex;
+ flex-direction: column;
+ align-items: center;
+ padding-top: 120rpx;
+ text-align: center;
+}
+
+.empty-icon {
+ width: 400rpx;
+ margin-bottom: 32rpx;
+ opacity: 0.5;
+}
+
+.empty-text {
+ font-size: 32rpx;
+ color: #666;
+ margin-bottom: 12rpx;
+ font-weight: 600;
+}
+
+.empty-tip {
+ font-size: 26rpx;
+ color: #999;
+ margin-bottom: 40rpx;
+ line-height: 1.4;
+}
+
+/* 列表底部 */
+.list-footer {
+ text-align: center;
+ padding: 40rpx 0;
+ color: #999;
+ font-size: 24rpx;
+}
+
+.footer-text {
+ opacity: 0.6;
+ letter-spacing: 1rpx;
+}
+
+
+/* 卡片入场动画 */
+@keyframes cardSlideIn {
+ from {
+ opacity: 0;
+ transform: translateY(30rpx);
+ }
+ to {
+ opacity: 1;
+ transform: translateY(0);
+ }
+}
+
+.record-card {
+ animation: cardSlideIn 0.4s ease-out forwards;
+ opacity: 0;
+}
+
+.record-card:nth-child(1) { animation-delay: 0.1s; }
+.record-card:nth-child(2) { animation-delay: 0.15s; }
+.record-card:nth-child(3) { animation-delay: 0.2s; }
+.record-card:nth-child(4) { animation-delay: 0.25s; }
+.record-card:nth-child(5) { animation-delay: 0.3s; }
+
+/* 响应式适配 */
+@media screen and (min-width: 768px) {
+ .record-card {
+ max-width: 600rpx;
+ margin-left: auto;
+ margin-right: auto;
+ }
+}
\ No newline at end of file
diff --git a/pagesA/pages/askingSyDetails/askingSyDetails.js b/pagesA/pages/askingSyDetails/askingSyDetails.js
new file mode 100644
index 0000000..2594584
--- /dev/null
+++ b/pagesA/pages/askingSyDetails/askingSyDetails.js
@@ -0,0 +1,569 @@
+// 第一个页面的完整JS代码 - pages/diagnosisDetail/diagnosisDetail.js
+import http from '../../../utils/api'
+const baseUrl = require('../../../utils/baseUrl')
+
+Page({
+ /**
+ * 页面的初始数据
+ */
+ data: {
+ diagnosisData: {},
+ replies: [],
+ baseUrl: baseUrl,
+ refreshing: false,
+
+ // 新增回复相关数据
+ showReplyInput: true,
+ replyContent: '',
+ replyImages: [],
+ replyImagesTemp: [], // 本地临时路径,用于预览
+ uploadingImage: false,
+ submittingReply: false,
+ isUploading: false // 防止重复上传
+ },
+
+ /**
+ * 生命周期函数--监听页面加载
+ */
+ onLoad(options) {
+ if (options.data) {
+ // 根据id加载兽医回复数据
+ const data = JSON.parse(decodeURIComponent(options.data));
+ // 处理用户图片 - 确保是数组格式
+ if (data.images) {
+ if (typeof data.images === 'string') {
+ data.images = data.images.split(',')
+ }
+ console.log('用户图片:', data.images);
+ } else {
+ data.images = [];
+ }
+
+ this.setData({
+ diagnosisData: data,
+ })
+ this.loadDiagnosisData(data.formId);
+ }
+ },
+
+ /**
+ * 加载问诊数据(兽医回复)
+ * @param {string} id - 问诊ID
+ */
+ loadDiagnosisData(id) {
+ console.log('加载问诊数据:', id);
+ wx.showLoading({
+ title: '加载中...',
+ mask: true
+ });
+
+ http.wzdxq({
+ data: {
+ consultationId: id
+ },
+ success: res => {
+ wx.hideLoading();
+ // 处理兽医回复的图片
+ let replies = [];
+
+ if (res && res.rows) {
+ replies = res.rows || [];
+
+ // 遍历每个回复,处理图片字段
+ for (let i = 0; i < replies.length; i++) {
+ const item = replies[i];
+
+ // 处理图片 - 确保是数组格式
+ if (item.images) {
+ if (typeof item.images === 'string') {
+ // 如果是空字符串,设为空数组
+ if (item.images.trim() === '') {
+ item.images = [];
+ } else {
+ // 按逗号分割字符串
+ item.images = item.images.split(',');
+ }
+ } else if (Array.isArray(item.images)) {
+ // 已经是数组,但需要过滤空值
+ item.images = item.images.filter(img => img && img.trim() !== '');
+ } else {
+ item.images = [];
+ }
+ } else {
+ item.images = [];
+ }
+
+ console.log(`兽医回复[${i}]图片:`, item.images);
+ }
+ }
+
+ console.log('兽医回复数据:', replies);
+ this.setData({
+ replies: replies
+ })
+ },
+ fail: err => {
+ wx.hideLoading();
+ console.error('加载回复失败:', err);
+ wx.showToast({
+ title: '加载失败',
+ icon: 'none'
+ });
+ }
+ })
+ },
+
+ /**
+ * 回复内容输入
+ */
+ onReplyContentInput(e) {
+ this.setData({
+ replyContent: e.detail.value
+ });
+ },
+
+ /**
+ * 清空所有图片
+ */
+ clearAllImages() {
+ if (this.data.replyImages.length === 0) return;
+
+ wx.showModal({
+ title: '提示',
+ content: '确定要清空所有已选图片吗?',
+ success: (res) => {
+ if (res.confirm) {
+ this.setData({
+ replyImages: [],
+ replyImagesTemp: []
+ });
+ }
+ }
+ });
+ },
+
+ /**
+ * 选择回复图片 - 优化后的版本
+ */
+ chooseReplyImage() {
+ if (this.data.isUploading) {
+ wx.showToast({
+ title: '正在上传中,请稍候',
+ icon: 'none'
+ });
+ return;
+ }
+
+ if (this.data.replyImages.length >= 9) {
+ wx.showToast({
+ title: '最多上传9张图片',
+ icon: 'none'
+ });
+ return;
+ }
+
+ wx.chooseMedia({
+ count: 9 - this.data.replyImages.length,
+ mediaType: ['image'],
+ sourceType: ['album', 'camera'],
+ sizeType: ['compressed'],
+ success: (res) => {
+ if (res.tempFiles && res.tempFiles.length > 0) {
+ this.setData({
+ isUploading: true
+ });
+
+ // 显示加载提示
+ wx.showLoading({
+ title: '上传图片中...',
+ mask: true
+ });
+
+ // 获取临时文件路径列表
+ const tempPaths = res.tempFiles.map(file => file.tempFilePath);
+
+ // 保存临时路径用于预览
+ const newTempPaths = [...this.data.replyImagesTemp, ...tempPaths];
+ this.setData({
+ replyImagesTemp: newTempPaths
+ });
+
+ // 逐张上传图片
+ this.uploadImages(tempPaths);
+ }
+ }
+ });
+ },
+
+ /**
+ * 上传多张图片 - 优化后的版本
+ */
+ uploadImages(filePaths) {
+ const uploadTasks = filePaths.map(path => {
+ return new Promise((resolve, reject) => {
+ wx.uploadFile({
+ url: baseUrl + '/common/upload',
+ filePath: path,
+ name: 'file',
+ header: {
+ 'Authorization': 'Bearer ' + wx.getStorageSync('token')
+ },
+ success: (res) => {
+ try {
+ const data = JSON.parse(res.data);
+ if (data.code === 200 || data.fileName) {
+ const imagePath = data.fileName || data.url;
+ resolve(imagePath);
+ } else {
+ reject(new Error(data.msg || '上传失败'));
+ }
+ } catch (e) {
+ reject(e);
+ }
+ },
+ fail: (err) => {
+ reject(err);
+ }
+ });
+ });
+ });
+
+ Promise.all(uploadTasks)
+ .then((imagePaths) => {
+ wx.hideLoading();
+
+ // 将新上传的图片添加到现有图片数组中
+ const newReplyImages = [...this.data.replyImages, ...imagePaths];
+
+ this.setData({
+ replyImages: newReplyImages,
+ isUploading: false
+ });
+
+ wx.showToast({
+ title: '上传成功',
+ icon: 'success'
+ });
+ })
+ .catch((err) => {
+ wx.hideLoading();
+ console.error('上传失败:', err);
+
+ // 上传失败时,移除对应的临时预览图片
+ const failedCount = filePaths.length;
+ const currentTempPaths = [...this.data.replyImagesTemp];
+ for (let i = 0; i < failedCount; i++) {
+ currentTempPaths.pop();
+ }
+
+ this.setData({
+ replyImagesTemp: currentTempPaths,
+ isUploading: false
+ });
+
+ wx.showToast({
+ title: '上传失败,请重试',
+ icon: 'none'
+ });
+ });
+ },
+
+ /**
+ * 移除单张回复图片
+ */
+ removeReplyImage(e) {
+ const index = e.currentTarget.dataset.index;
+ const replyImages = this.data.replyImages.filter((_, i) => i !== index);
+ const replyImagesTemp = this.data.replyImagesTemp.filter((_, i) => i !== index);
+
+ this.setData({
+ replyImages: replyImages,
+ replyImagesTemp: replyImagesTemp
+ });
+ },
+
+ /**
+ * 提交回复 - 优化后的版本
+ */
+ submitReply() {
+ const content = this.data.replyContent.trim();
+ const images = this.data.replyImages;
+
+ // 检查内容
+ if (!content && images.length === 0) {
+ wx.showToast({
+ title: '请输入回复内容或上传图片',
+ icon: 'none'
+ });
+ return;
+ }
+
+ if (this.data.submittingReply || this.data.isUploading) {
+ wx.showToast({
+ title: this.data.isUploading ? '图片上传中,请稍后' : '提交中,请稍后',
+ icon: 'none'
+ });
+ return;
+ }
+
+ this.setData({ submittingReply: true });
+
+ // 显示加载提示
+ wx.showLoading({
+ title: '发送中...',
+ mask: true
+ });
+
+ // 准备提交数据
+ const submitData = {
+ consultationId: this.data.diagnosisData.formId,
+ content: content
+ };
+
+ // 如果有图片,将图片数组转为逗号分隔的字符串
+ if (images.length > 0) {
+ submitData.images = images.join(',');
+ }
+
+ console.log('提交回复数据:', submitData);
+
+ // 调用回复接口
+ http.wzdAdd({
+ data: submitData,
+ success: res => {
+ wx.hideLoading();
+
+ if (res.code === 200 || res.success) {
+ // 清空输入
+ this.setData({
+ replyContent: '',
+ replyImages: [],
+ replyImagesTemp: [],
+ submittingReply: false
+ });
+
+ wx.showToast({
+ title: '回复成功',
+ icon: 'success'
+ });
+
+ // 重新加载回复列表
+ this.loadDiagnosisData(this.data.diagnosisData.formId);
+
+ // 滚动到底部
+ setTimeout(() => {
+ wx.createSelectorQuery().select('.page-content').boundingClientRect(rect => {
+ wx.pageScrollTo({
+ scrollTop: rect.height,
+ duration: 300
+ });
+ }).exec();
+ }, 500);
+ } else {
+ this.setData({ submittingReply: false });
+ wx.showToast({
+ title: res.message || '回复失败',
+ icon: 'none'
+ });
+ }
+ },
+ fail: err => {
+ wx.hideLoading();
+ this.setData({ submittingReply: false });
+ console.error('回复失败:', err);
+ wx.showToast({
+ title: '网络错误,请重试',
+ icon: 'none'
+ });
+ }
+ });
+ },
+
+ /**
+ * 返回上一页
+ */
+ goBack() {
+ wx.navigateBack();
+ },
+
+ /**
+ * 分享
+ */
+ onShare() {
+ wx.showActionSheet({
+ itemList: ['分享给好友', '保存到相册'],
+ success: (res) => {
+ if (res.tapIndex === 0) {
+ wx.showToast({
+ title: '已分享',
+ icon: 'success'
+ });
+ }
+ }
+ });
+ },
+
+ /**
+ * 下拉刷新
+ */
+ onRefresh() {
+ this.setData({
+ refreshing: true
+ });
+
+ if (this.data.diagnosisData && this.data.diagnosisData.formId) {
+ this.loadDiagnosisData(this.data.diagnosisData.formId)
+ }
+
+ setTimeout(() => {
+ this.setData({
+ refreshing: false
+ });
+ wx.showToast({
+ title: '刷新成功',
+ icon: 'success'
+ });
+ }, 1000);
+ },
+
+ /**
+ * 预览用户图片
+ */
+ previewImage(e) {
+ const dataset = e.currentTarget.dataset;
+ const current = dataset.url;
+ const urls = dataset.urls || [];
+
+ // 构建完整URL数组
+ const urlsArray = urls.map(item => {
+ if (typeof item === 'string' && (item.startsWith('http://') || item.startsWith('https://'))) {
+ return item;
+ }
+ return baseUrl + item;
+ });
+
+ console.log('预览用户图片:', urlsArray);
+ wx.previewImage({
+ current: current,
+ urls: urlsArray
+ });
+ },
+
+ /**
+ * 预览兽医回复图片
+ */
+ previewReplyImage(e) {
+ const dataset = e.currentTarget.dataset;
+
+ const currentFileName = dataset.url;
+ const currentFullUrl = dataset.fullurl;
+ const urlsArray = dataset.urls || [];
+ const currentIndex = dataset.currentIndex || 0;
+ const replyIndex = dataset.replyIndex;
+
+ console.log('预览兽医图片 - 数据集:', dataset);
+
+ // 从replies数据中获取当前回复的图片列表
+ let targetUrls = [];
+ let targetCurrentUrl = '';
+
+ if (replyIndex !== undefined && this.data.replies[replyIndex]) {
+ const reply = this.data.replies[replyIndex];
+ if (reply.images && reply.images.length > 0) {
+ targetUrls = reply.images;
+
+ const fullUrls = targetUrls.map(img => {
+ if (typeof img === 'string' && (img.startsWith('http://') || img.startsWith('https://'))) {
+ return img;
+ }
+ return baseUrl + img;
+ });
+
+ if (currentIndex < fullUrls.length) {
+ targetCurrentUrl = fullUrls[currentIndex];
+ } else if (currentFullUrl) {
+ targetCurrentUrl = currentFullUrl;
+ } else if (currentFileName) {
+ targetCurrentUrl = baseUrl + currentFileName;
+ }
+
+ console.log('预览兽医回复图片:', fullUrls, '当前:', targetCurrentUrl);
+
+ wx.previewImage({
+ current: targetCurrentUrl,
+ urls: fullUrls
+ });
+ return;
+ }
+ }
+
+ // 使用dataset中的数据
+ if (urlsArray && urlsArray.length > 0) {
+ const fullUrls = urlsArray.map(item => {
+ if (typeof item === 'string' && (item.startsWith('http://') || item.startsWith('https://'))) {
+ return item;
+ }
+ return baseUrl + item;
+ });
+
+ let currentUrl = '';
+ if (currentFullUrl) {
+ currentUrl = currentFullUrl;
+ } else if (currentIndex < fullUrls.length) {
+ currentUrl = fullUrls[currentIndex];
+ } else if (currentFileName) {
+ currentUrl = baseUrl + currentFileName;
+ }
+
+ console.log('预览兽医回复图片(从dataset):', fullUrls, '当前:', currentUrl);
+
+ wx.previewImage({
+ current: currentUrl,
+ urls: fullUrls
+ });
+ return;
+ }
+
+ // 预览单张图片
+ if (currentFullUrl) {
+ console.log('预览单张兽医图片:', [currentFullUrl]);
+ wx.previewImage({
+ current: currentFullUrl,
+ urls: [currentFullUrl]
+ });
+ } else if (currentFileName) {
+ const fullUrl = baseUrl + currentFileName;
+ console.log('预览单张兽医图片(拼接后):', [fullUrl]);
+ wx.previewImage({
+ current: fullUrl,
+ urls: [fullUrl]
+ });
+ } else {
+ wx.showToast({
+ title: '图片预览失败',
+ icon: 'none'
+ });
+ }
+ },
+
+ /**
+ * 生命周期函数--监听页面显示
+ */
+ onShow() {
+ // 如果已经有数据,刷新列表
+ if (this.data.diagnosisData && this.data.diagnosisData.formId) {
+ this.loadDiagnosisData(this.data.diagnosisData.formId);
+ }
+ },
+
+ /**
+ * 生命周期函数--监听页面卸载
+ */
+ onUnload() {
+ // 页面卸载时重置状态
+ this.setData({
+ submittingReply: false,
+ isUploading: false
+ });
+ }
+});
\ No newline at end of file
diff --git a/pagesA/pages/askingSyDetails/askingSyDetails.json b/pagesA/pages/askingSyDetails/askingSyDetails.json
new file mode 100644
index 0000000..9ffffad
--- /dev/null
+++ b/pagesA/pages/askingSyDetails/askingSyDetails.json
@@ -0,0 +1,4 @@
+{
+ "navigationBarTitleText":"问诊详情",
+ "usingComponents": {}
+}
\ No newline at end of file
diff --git a/pagesA/pages/askingSyDetails/askingSyDetails.wxml b/pagesA/pages/askingSyDetails/askingSyDetails.wxml
new file mode 100644
index 0000000..99c88c5
--- /dev/null
+++ b/pagesA/pages/askingSyDetails/askingSyDetails.wxml
@@ -0,0 +1,243 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ {{diagnosisData.farmerName || '用户'}}
+
+ {{diagnosisData.status}}
+
+
+
+
+ {{diagnosisData.animalType}}
+ {{diagnosisData.animalAge}}
+ {{diagnosisData.animalGender}}
+
+
+ {{diagnosisData.createdTime}}
+
+
+
+
+
+
+
+
+
+
+ "
+
+ {{diagnosisData.description}}
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ {{item.replyName || '兽医'}}
+
+ {{item.title}}
+
+
+
+
+ {{item.hospital}}
+
+
+ {{item.experience}}
+
+
+
+
+
+
+
+
+ {{item.content}}
+
+
+
+
+
+
+
+
+
+
+ +{{item.images.length - 4}}
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ 等待兽医回复中
+ 专业兽医通常会在24小时内为您解答
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ ×
+
+
+
+
+
+
+
+
+
+
+
+
+
+ 📷
+ 图片
+
+
+ {{replyImagesTemp.length}}
+
+
+
+
+
+
+
+
+
+
+
+
+ 仅兽医可回复
+
+
+
\ No newline at end of file
diff --git a/pagesA/pages/askingSyDetails/askingSyDetails.wxss b/pagesA/pages/askingSyDetails/askingSyDetails.wxss
new file mode 100644
index 0000000..c869204
--- /dev/null
+++ b/pagesA/pages/askingSyDetails/askingSyDetails.wxss
@@ -0,0 +1,1067 @@
+.xqbox {
+ background: linear-gradient(180deg, #F8FBFF 0%, #F0F7FF 100%);
+ min-height: 100vh;
+}
+
+/* 页面内容 */
+.page-content {
+ height: calc(100vh - 120rpx);
+ box-sizing: border-box;
+}
+
+/* 动画效果 */
+@keyframes cardEnter {
+ 0% {
+ opacity: 0;
+ transform: translateY(40rpx) scale(0.95);
+ }
+ 100% {
+ opacity: 1;
+ transform: translateY(0) scale(1);
+ }
+}
+
+@keyframes fadeInUp {
+ 0% {
+ opacity: 0;
+ transform: translateY(30rpx);
+ }
+ 100% {
+ opacity: 1;
+ transform: translateY(0);
+ }
+}
+
+@keyframes fadeIn {
+ from { opacity: 0; }
+ to { opacity: 1; }
+}
+
+@keyframes pulse {
+ 0% { transform: scale(1); }
+ 50% { transform: scale(1.05); }
+ 100% { transform: scale(1); }
+}
+
+.card-enter {
+ animation: cardEnter 0.6s cubic-bezier(0.34, 1.56, 0.64, 1) forwards;
+}
+
+.fade-in-up {
+ animation: fadeInUp 0.5s ease-out forwards;
+ opacity: 0;
+}
+
+.fade-in {
+ animation: fadeIn 0.8s ease-out forwards;
+ opacity: 0;
+}
+
+.pulse {
+ animation: pulse 2s infinite;
+}
+
+.hover-effect {
+ transition: all 0.3s ease;
+}
+
+.hover-effect:active {
+ transform: scale(0.95);
+}
+
+/* 渐变背景 */
+.gradient-blue {
+ background: linear-gradient(135deg, #6D9EFF 0%, #4A7CFF 100%);
+ color: white !important;
+}
+
+.gradient-orange {
+ background: linear-gradient(135deg, #FF9500 0%, #FF7F00 100%);
+ color: white !important;
+}
+
+.gradient-pink {
+ background: linear-gradient(135deg, #FF6B9D 0%, #FF4081 100%);
+ color: white !important;
+}
+
+.gradient-purple {
+ background: linear-gradient(135deg, #9D4BFF 0%, #7C3AED 100%);
+ color: white !important;
+}
+
+.gradient-gold {
+ background: linear-gradient(135deg, #FFD700 0%, #FFB300 100%);
+ color: white !important;
+}
+
+/* 用户问诊卡片 */
+.user-query-card {
+ background: #FFFFFF;
+ margin: 24rpx;
+ border-radius: 28rpx;
+ box-shadow: 0 12rpx 48rpx rgba(74, 144, 226, 0.15);
+ border: 2rpx solid #FFFFFF;
+ overflow: hidden;
+ position: relative;
+ backdrop-filter: blur(20rpx);
+}
+
+/* 卡片装饰 */
+.card-decoration {
+ position: absolute;
+ top: 0;
+ left: 0;
+ right: 0;
+ bottom: 0;
+ pointer-events: none;
+ z-index: 1;
+}
+
+.decoration-dot {
+ position: absolute;
+ border-radius: 50%;
+ background: linear-gradient(135deg, rgba(109, 158, 255, 0.1) 0%, rgba(74, 124, 255, 0.1) 100%);
+}
+
+.dot-1 {
+ width: 120rpx;
+ height: 120rpx;
+ top: -40rpx;
+ right: -40rpx;
+}
+
+.dot-2 {
+ width: 80rpx;
+ height: 80rpx;
+ bottom: 60rpx;
+ left: -20rpx;
+}
+
+.dot-3 {
+ width: 60rpx;
+ height: 60rpx;
+ bottom: -20rpx;
+ right: 80rpx;
+}
+
+/* 用户信息区域 */
+.user-info-section {
+ padding: 40rpx 32rpx 32rpx;
+ display: flex;
+ align-items: flex-start;
+ position: relative;
+ z-index: 2;
+}
+
+.avatar-wrapper {
+ position: relative;
+ margin-right: 24rpx;
+ flex-shrink: 0;
+}
+
+.user-avatar {
+ width: 88rpx;
+ height: 88rpx;
+ border-radius: 50%;
+ border: 3rpx solid #FFFFFF;
+ box-shadow: 0 8rpx 24rpx rgba(74, 144, 226, 0.3);
+}
+
+.user-details {
+ flex: 1;
+}
+
+.user-name-row {
+ display: flex;
+ align-items: center;
+ justify-content: space-between;
+ margin-bottom: 16rpx;
+}
+
+.user-name {
+ font-size: 34rpx;
+ font-weight: 700;
+ color: #1A1A1A;
+ line-height: 1.2;
+ text-shadow: 0 1rpx 2rpx rgba(0, 0, 0, 0.1);
+}
+
+.status-badge {
+ padding: 10rpx 24rpx;
+ border-radius: 24rpx;
+ font-size: 26rpx;
+ font-weight: 700;
+ min-width: 88rpx;
+ text-align: center;
+ box-shadow: 0 4rpx 12rpx rgba(0, 0, 0, 0.1);
+}
+
+.status-replied {
+ background: linear-gradient(135deg, #2ECC71 0%, #27AE60 100%);
+ color: white;
+}
+
+.status-pending {
+ background: linear-gradient(135deg, #FF9500 0%, #F39C12 100%);
+ color: white;
+}
+
+.pet-info {
+ display: flex;
+ flex-direction: column;
+ gap: 16rpx;
+}
+
+.pet-info-tags {
+ display: flex;
+ gap: 12rpx;
+ flex-wrap: wrap;
+}
+
+.pet-tag {
+ padding: 6rpx 20rpx;
+ border-radius: 20rpx;
+ font-size: 24rpx;
+ font-weight: 600;
+ box-shadow: 0 4rpx 12rpx rgba(0, 0, 0, 0.1);
+}
+
+.time-info {
+ display: flex;
+ align-items: center;
+ gap: 8rpx;
+ background: rgba(109, 158, 255, 0.08);
+ padding: 8rpx 16rpx;
+ border-radius: 20rpx;
+ align-self: flex-start;
+}
+
+.time-text {
+ font-size: 24rpx;
+ color: #6D9EFF;
+ font-weight: 500;
+}
+
+/* 症状描述区域 */
+.symptom-section {
+ padding: 32rpx;
+ position: relative;
+ z-index: 2;
+}
+
+.section-header {
+ display: flex;
+ align-items: center;
+ margin-bottom: 28rpx;
+}
+
+.section-title {
+ font-size: 32rpx;
+ font-weight: 700;
+ color: #1A1A1A;
+ position: relative;
+ padding-right: 16rpx;
+}
+
+.title-decoration {
+ flex: 1;
+ height: 2rpx;
+ background: linear-gradient(90deg, #E5F0FF 0%, #6D9EFF 50%, #E5F0FF 100%);
+ margin-left: 16rpx;
+ border-radius: 1rpx;
+}
+
+.symptom-content {
+ background: #F8FBFF;
+ border-radius: 24rpx;
+ padding: 36rpx 32rpx;
+ border: 2rpx solid #E5F0FF;
+ position: relative;
+ box-shadow: 0 4rpx 16rpx rgba(74, 144, 226, 0.1);
+ transition: all 0.3s ease;
+}
+
+.symptom-content:active {
+ transform: translateY(-2rpx);
+ box-shadow: 0 8rpx 24rpx rgba(74, 144, 226, 0.15);
+}
+
+.quote-left {
+ position: absolute;
+ top: 20rpx;
+ left: 20rpx;
+ font-size: 48rpx;
+ color: #6D9EFF;
+ font-weight: 700;
+ opacity: 0.3;
+}
+
+.symptom-text {
+ font-size: 30rpx;
+ color: #333;
+ line-height: 1.8;
+ font-weight: 400;
+ text-align: left;
+}
+
+/* 图片展示区域 */
+.image-section {
+ padding: 32rpx;
+ position: relative;
+ z-index: 2;
+}
+
+.image-count {
+ margin-left: auto;
+ padding: 6rpx 16rpx;
+ border-radius: 20rpx;
+ font-size: 24rpx;
+ font-weight: 600;
+}
+
+.images-scroll {
+ width: 100%;
+}
+
+.images-container {
+ display: flex;
+ padding: 8rpx 0;
+}
+
+.image-wrapper {
+ margin-right: 20rpx;
+ position: relative;
+ border-radius: 20rpx;
+ overflow: hidden;
+ box-shadow: 0 8rpx 24rpx rgba(0, 0, 0, 0.15);
+ transition: all 0.3s ease;
+}
+
+.image-wrapper:last-child {
+ margin-right: 0;
+}
+
+.image-wrapper:active {
+ transform: scale(0.98);
+}
+
+.symptom-image {
+ width: 220rpx;
+ height: 220rpx;
+ border-radius: 20rpx;
+}
+
+/* 兽医回复区域 */
+.replies-section {
+ margin: 24rpx;
+}
+
+.reply-count {
+ margin-left: auto;
+ padding: 8rpx 20rpx;
+ border-radius: 24rpx;
+ display: flex;
+ align-items: center;
+ gap: 4rpx;
+ box-shadow: 0 4rpx 12rpx rgba(157, 75, 255, 0.3);
+}
+
+.count-number {
+ font-size: 30rpx;
+ font-weight: 700;
+}
+
+.count-text {
+ font-size: 24rpx;
+ font-weight: 500;
+ opacity: 0.9;
+}
+
+/* 回复列表 */
+.replies-list {
+ display: flex;
+ flex-direction: column;
+ gap: 24rpx;
+ padding-bottom: 30rpx;
+}
+
+.vet-reply-card {
+ background: #FFFFFF;
+ border-radius: 28rpx;
+ padding: 36rpx;
+ box-shadow: 0 12rpx 48rpx rgba(74, 144, 226, 0.15);
+ border: 2rpx solid #FFFFFF;
+ position: relative;
+ overflow: hidden;
+ backdrop-filter: blur(20rpx);
+}
+
+/* 兽医信息 */
+.vet-info {
+ display: flex;
+ align-items: center;
+ margin-bottom: 32rpx;
+}
+
+.vet-avatar {
+ width: 80rpx;
+ height: 80rpx;
+ border-radius: 50%;
+ border: 3rpx solid #FFFFFF;
+ box-shadow: 0 8rpx 24rpx rgba(255, 215, 0, 0.3);
+ margin-right: 20rpx;
+ flex-shrink: 0;
+}
+
+.vet-verified {
+ position: absolute;
+ bottom: 2rpx;
+ right: 2rpx;
+ width: 20rpx;
+ height: 20rpx;
+ background: #2ECC71;
+ border: 2rpx solid white;
+ border-radius: 50%;
+}
+
+.vet-details {
+ flex: 1;
+}
+
+.vet-name-row {
+ display: flex;
+ align-items: center;
+ margin-bottom: 12rpx;
+}
+
+.vet-name {
+ font-size: 32rpx;
+ font-weight: 700;
+ color: #1A1A1A;
+ margin-right: 16rpx;
+ text-shadow: 0 1rpx 2rpx rgba(0, 0, 0, 0.1);
+}
+
+.vet-badge {
+ padding: 2rpx 10rpx;
+ border-radius: 20rpx;
+ box-shadow: 0 4rpx 12rpx rgba(255, 215, 0, 0.3);
+}
+
+.vet-title {
+ font-size: 24rpx;
+ font-weight: 700;
+ letter-spacing: 0.5rpx;
+}
+
+.vet-meta {
+ display: flex;
+ align-items: center;
+ gap: 20rpx;
+}
+
+.meta-item {
+ display: flex;
+ align-items: center;
+ gap: 6rpx;
+ background: rgba(109, 158, 255, 0.08);
+ padding: 6rpx 12rpx;
+ border-radius: 16rpx;
+}
+
+.vet-hospital,
+.vet-experience {
+ font-size: 24rpx;
+ color: #6D9EFF;
+ font-weight: 500;
+}
+
+/* 回复内容 */
+.reply-content {
+ margin-bottom: 28rpx;
+}
+
+.reply-bubble {
+ background: #F8FBFF;
+ border-radius: 24rpx;
+ padding: 32rpx;
+ border: 2rpx solid #E5F0FF;
+ position: relative;
+ box-shadow: 0 4rpx 16rpx rgba(74, 144, 226, 0.1);
+}
+
+.reply-bubble::before {
+ content: '';
+ position: absolute;
+ top: -12rpx;
+ left: 40rpx;
+ width: 0;
+ height: 0;
+ border-left: 12rpx solid transparent;
+ border-right: 12rpx solid transparent;
+ border-bottom: 12rpx solid #F8FBFF;
+}
+
+.reply-text {
+ font-size: 28rpx;
+ color: #333;
+ line-height: 1.8;
+ font-weight: 400;
+}
+
+/* 回复底部 */
+.reply-footer {
+ display: flex;
+ justify-content: space-between;
+ align-items: center;
+ padding-top: 24rpx;
+ border-top: 2rpx dashed #E5F0FF;
+}
+
+.reply-time {
+ display: flex;
+ align-items: center;
+ gap: 10rpx;
+ background: rgba(109, 158, 255, 0.1);
+ padding: 8rpx 20rpx;
+ border-radius: 20rpx;
+}
+
+/* 无回复状态 */
+.no-replies {
+ background: #FFFFFF;
+ border-radius: 28rpx;
+ padding: 80rpx 40rpx;
+ text-align: center;
+ box-shadow: 0 12rpx 48rpx rgba(74, 144, 226, 0.15);
+ border: 2rpx solid #FFFFFF;
+ position: relative;
+ overflow: hidden;
+}
+
+.no-replies-title {
+ font-size: 32rpx;
+ color: #333;
+ font-weight: 700;
+ margin-bottom: 16rpx;
+ display: block;
+ text-shadow: 0 1rpx 2rpx rgba(0, 0, 0, 0.1);
+}
+
+.no-replies-desc {
+ font-size: 26rpx;
+ color: #999;
+ line-height: 1.4;
+ max-width: 400rpx;
+ margin: 0 auto;
+}
+
+.waiting-animation {
+ display: flex;
+ justify-content: center;
+ gap: 12rpx;
+ margin-top: 40rpx;
+}
+
+.loading-dot {
+ width: 16rpx;
+ height: 16rpx;
+ border-radius: 50%;
+ background: #6D9EFF;
+ animation: pulse 1.5s infinite ease-in-out;
+}
+
+.loading-dot.dot-1 { animation-delay: 0s; }
+.loading-dot.dot-2 { animation-delay: 0.2s; }
+.loading-dot.dot-3 { animation-delay: 0.4s; }
+
+/* 页面底部安全区域 */
+.page-bottom {
+ height: 60rpx;
+}
+
+/* 新增兽医回复图片预览 */
+.reply-images-section {
+ margin-top: 24rpx;
+ padding: 0 8rpx;
+}
+
+.reply-images-grid {
+ display: grid;
+ gap: 12rpx;
+ width: 100%;
+}
+
+/* 根据图片数量自适应网格 */
+.reply-images-grid.grid-1 {
+ grid-template-columns: repeat(1, minmax(200rpx, 320rpx));
+ justify-content: start;
+}
+
+.reply-images-grid.grid-2 {
+ grid-template-columns: repeat(2, 1fr);
+}
+
+.reply-images-grid.grid-3,
+.reply-images-grid.grid-4,
+.reply-images-grid:not(.grid-1):not(.grid-2) {
+ grid-template-columns: repeat(2, 1fr);
+}
+
+.reply-image-wrapper {
+ position: relative;
+ border-radius: 16rpx;
+ overflow: hidden;
+ background-color: #f5f5f5;
+ aspect-ratio: 1 / 1;
+ box-shadow: 0 4rpx 16rpx rgba(0, 0, 0, 0.1);
+ transition: transform 0.2s ease;
+}
+
+.reply-image-wrapper:active {
+ transform: scale(0.98);
+}
+
+.reply-image {
+ width: 100%;
+ height: 100%;
+ border-radius: 16rpx;
+ object-fit: cover;
+}
+
+/* 图片数量遮罩 */
+.image-more-mask {
+ position: absolute;
+ top: 0;
+ left: 0;
+ width: 100%;
+ height: 100%;
+ background-color: rgba(0, 0, 0, 0.5);
+ display: flex;
+ align-items: center;
+ justify-content: center;
+ border-radius: 16rpx;
+}
+
+.more-count {
+ color: #fff;
+ font-size: 36rpx;
+ font-weight: 700;
+ text-shadow: 0 2rpx 4rpx rgba(0,0,0,0.3);
+}
+
+/* 底部回复输入区域 */
+.reply-input-section {
+ position: fixed;
+ bottom: 0;
+ left: 0;
+ right: 0;
+ background: #FFFFFF;
+ box-shadow: 0 -8rpx 30rpx rgba(74, 144, 226, 0.15);
+ border-top: 2rpx solid #E5F0FF;
+ transform: translateY(100%);
+ transition: transform 0.3s ease;
+ z-index: 1000;
+ backdrop-filter: blur(20rpx);
+}
+
+.reply-input-section.show {
+ transform: translateY(0);
+}
+
+.reply-input-container {
+ padding: 20rpx 24rpx;
+ max-height: 600rpx;
+ overflow-y: auto;
+}
+
+/* 图片预览区 */
+.reply-image-preview {
+ margin-bottom: 20rpx;
+}
+
+.preview-scroll {
+ width: 100%;
+ white-space: nowrap;
+}
+
+.preview-list {
+ display: flex;
+ gap: 16rpx;
+ padding: 8rpx 0;
+}
+
+.preview-item {
+ position: relative;
+ width: 120rpx;
+ height: 120rpx;
+ border-radius: 16rpx;
+ overflow: hidden;
+ box-shadow: 0 4rpx 12rpx rgba(0, 0, 0, 0.1);
+}
+
+.preview-img {
+ width: 100%;
+ height: 100%;
+ object-fit: cover;
+}
+
+.preview-remove {
+ position: absolute;
+ top: 4rpx;
+ right: 4rpx;
+ width: 32rpx;
+ height: 32rpx;
+ background: rgba(0, 0, 0, 0.5);
+ border-radius: 50%;
+ display: flex;
+ align-items: center;
+ justify-content: center;
+ border: 2rpx solid #FFFFFF;
+}
+
+.remove-icon {
+ color: #FFFFFF;
+ font-size: 28rpx;
+ font-weight: 700;
+ line-height: 1;
+}
+
+/* 输入工具栏 */
+.input-toolbar {
+ display: flex;
+ flex-direction: column;
+ gap: 16rpx;
+}
+
+.reply-textarea {
+ width: 100%;
+ min-height: 80rpx;
+ max-height: 200rpx;
+ padding: 16rpx 24rpx;
+ background: #F8FBFF;
+ border-radius: 24rpx;
+ font-size: 28rpx;
+ color: #333;
+ border: 2rpx solid #E5F0FF;
+ box-sizing: border-box;
+}
+
+.textarea-placeholder {
+ color: #999;
+ font-size: 28rpx;
+}
+
+.toolbar-actions {
+ display: flex;
+ align-items: center;
+ justify-content: space-between;
+}
+
+.action-item {
+ display: flex;
+ align-items: center;
+ gap: 8rpx;
+ padding: 12rpx 24rpx;
+ background: #F0F7FF;
+ border-radius: 40rpx;
+ border: 2rpx solid #E5F0FF;
+}
+
+.action-icon {
+ font-size: 32rpx;
+}
+
+.action-text {
+ font-size: 26rpx;
+ color: #6D9EFF;
+ font-weight: 500;
+}
+
+.submit-reply-btn {
+ min-width: 160rpx;
+ height: 72rpx;
+ line-height: 72rpx;
+ text-align: center;
+ background: linear-gradient(135deg, #CCCCCC 0%, #999999 100%);
+ color: #FFFFFF;
+ font-size: 28rpx;
+ font-weight: 600;
+ border-radius: 40rpx;
+ margin: 0;
+ padding: 0 24rpx;
+ border: none;
+ transition: all 0.3s ease;
+}
+
+.submit-reply-btn.active {
+ background: linear-gradient(135deg, #6D9EFF 0%, #4A7CFF 100%);
+ box-shadow: 0 8rpx 24rpx rgba(74, 144, 226, 0.3);
+}
+
+.submit-reply-btn:active {
+ transform: scale(0.95);
+}
+
+.submit-reply-btn[disabled] {
+ opacity: 0.5;
+}
+
+/* 底部占位 */
+.bottom-placeholder {
+ height: 160rpx;
+}
+
+/* 回复输入区域的样式补充 */
+
+/* 图片预览区头部 */
+.preview-header {
+ display: flex;
+ align-items: center;
+ justify-content: space-between;
+ margin-bottom: 16rpx;
+ padding: 0 8rpx;
+}
+
+.preview-title {
+ font-size: 26rpx;
+ color: #666;
+ font-weight: 500;
+}
+
+.clear-all-btn {
+ display: flex;
+ align-items: center;
+ gap: 6rpx;
+ padding: 8rpx 16rpx;
+ background: rgba(255, 107, 107, 0.1);
+ border-radius: 24rpx;
+ border: 1rpx solid rgba(255, 107, 107, 0.3);
+}
+
+.clear-icon {
+ font-size: 28rpx;
+}
+
+.clear-text {
+ font-size: 24rpx;
+ color: #FF6B6B;
+ font-weight: 500;
+}
+
+.clear-all-btn:active {
+ opacity: 0.7;
+ transform: scale(0.95);
+}
+
+/* 图片预览区优化 */
+.reply-image-preview {
+ margin-bottom: 24rpx;
+ background: #F8FBFF;
+ border-radius: 24rpx;
+ padding: 20rpx;
+ border: 2rpx solid #E5F0FF;
+}
+
+.preview-scroll {
+ width: 100%;
+ white-space: nowrap;
+}
+
+.preview-list {
+ display: flex;
+ gap: 16rpx;
+ padding: 4rpx 0;
+}
+
+.preview-item {
+ position: relative;
+ width: 140rpx;
+ height: 140rpx;
+ border-radius: 20rpx;
+ overflow: hidden;
+ box-shadow: 0 6rpx 20rpx rgba(74, 144, 226, 0.2);
+ border: 2rpx solid #FFFFFF;
+}
+
+.preview-img {
+ width: 100%;
+ height: 100%;
+ object-fit: cover;
+}
+
+.preview-remove {
+ position: absolute;
+ top: 6rpx;
+ right: 6rpx;
+ width: 36rpx;
+ height: 36rpx;
+ background: rgba(0, 0, 0, 0.6);
+ border-radius: 50%;
+ display: flex;
+ align-items: center;
+ justify-content: center;
+ border: 2rpx solid #FFFFFF;
+ backdrop-filter: blur(4rpx);
+}
+
+.remove-icon {
+ color: #FFFFFF;
+ font-size: 32rpx;
+ font-weight: 700;
+ line-height: 1;
+}
+
+/* 输入工具栏优化 */
+.input-toolbar {
+ display: flex;
+ flex-direction: column;
+ gap: 20rpx;
+}
+
+.reply-textarea {
+ width: 100%;
+ min-height: 100rpx;
+ max-height: 240rpx;
+ padding: 20rpx 28rpx;
+ background: #F8FBFF;
+ border-radius: 28rpx;
+ font-size: 30rpx;
+ color: #333;
+ border: 2rpx solid #E5F0FF;
+ box-sizing: border-box;
+ transition: all 0.3s ease;
+}
+
+.reply-textarea:focus {
+ border-color: #6D9EFF;
+ box-shadow: 0 0 0 4rpx rgba(109, 158, 255, 0.2);
+}
+
+.textarea-placeholder {
+ color: #AAA;
+ font-size: 30rpx;
+}
+
+.toolbar-actions {
+ display: flex;
+ align-items: center;
+ justify-content: space-between;
+}
+
+.action-left {
+ display: flex;
+ align-items: center;
+ gap: 16rpx;
+ position: relative;
+}
+
+.action-item {
+ display: flex;
+ align-items: center;
+ gap: 8rpx;
+ padding: 16rpx 28rpx;
+ background: #F0F7FF;
+ border-radius: 44rpx;
+ border: 2rpx solid #E5F0FF;
+ transition: all 0.2s ease;
+}
+
+.action-item:active {
+ background: #E5F0FF;
+ transform: scale(0.96);
+}
+
+.action-icon {
+ font-size: 34rpx;
+}
+
+.action-text {
+ font-size: 28rpx;
+ color: #4A7CFF;
+ font-weight: 600;
+}
+
+.image-count-badge {
+ background: linear-gradient(135deg, #FF6B9D 0%, #FF4081 100%);
+ color: white;
+ min-width: 36rpx;
+ height: 36rpx;
+ border-radius: 36rpx;
+ display: flex;
+ align-items: center;
+ justify-content: center;
+ padding: 0 8rpx;
+ border: 2rpx solid #FFFFFF;
+ box-shadow: 0 4rpx 12rpx rgba(255, 64, 129, 0.3);
+ margin-left: -10rpx;
+}
+
+.image-count-badge .count-text {
+ font-size: 22rpx;
+ font-weight: 700;
+ color: white;
+}
+
+.action-right {
+ flex-shrink: 0;
+}
+
+.submit-reply-btn {
+ min-width: 180rpx;
+ height: 80rpx;
+ line-height: 80rpx;
+ text-align: center;
+ background: linear-gradient(135deg, #CCCCCC 0%, #999999 100%);
+ color: #FFFFFF;
+ font-size: 30rpx;
+ font-weight: 700;
+ border-radius: 44rpx;
+ margin: 0;
+ padding: 0 32rpx;
+ border: none;
+ transition: all 0.3s ease;
+ box-shadow: 0 6rpx 16rpx rgba(0, 0, 0, 0.1);
+}
+
+.submit-reply-btn.active {
+ background: linear-gradient(135deg, #6D9EFF 0%, #4A7CFF 100%);
+ box-shadow: 0 8rpx 24rpx rgba(74, 144, 226, 0.4);
+}
+
+.submit-reply-btn:active {
+ transform: scale(0.94);
+}
+
+.submit-reply-btn[disabled] {
+ opacity: 0.6;
+ background: linear-gradient(135deg, #CCCCCC 0%, #999999 100%);
+ box-shadow: none;
+}
+
+/* 无回复权限提示 */
+.no-reply-permission {
+ position: fixed;
+ bottom: 0;
+ left: 0;
+ right: 0;
+ background: #FFFFFF;
+ box-shadow: 0 -4rpx 20rpx rgba(74, 144, 226, 0.1);
+ padding: 24rpx 0;
+ text-align: center;
+ border-top: 2rpx solid #E5F0FF;
+ backdrop-filter: blur(20rpx);
+}
+
+.no-permission-text {
+ font-size: 28rpx;
+ color: #999;
+ font-weight: 500;
+}
+
+/* 底部占位优化 */
+.bottom-placeholder {
+ height: 200rpx;
+}
+
diff --git a/utils/api.js b/utils/api.js
index e77e778..e52bcb0 100644
--- a/utils/api.js
+++ b/utils/api.js
@@ -77,8 +77,20 @@ function videoZd(params) {
http('/system/dict/data/list', 'get', params)
}
+// 问诊列表
+function wzd(params) {
+ http('/muhu/consultation/list', 'get', params)
+}
+// 问诊单回复列表
+function wzdxq(params) {
+ http('/vet/comments/list', 'get', params)
+}
+// 新增问诊单回复
+function wzdAdd(params) {
+ http('/vet/comments', 'post', params)
+}
@@ -150,8 +162,8 @@ function today(params) {
export default { // 暴露接口
- login,carousel,getPhoneNumber,article,articleDetails,articleZd,
+ login,carousel,getPhoneNumber,article,articleDetails,articleZd,wzd,wzdAdd,
areaChildren,userCode,UserInfo,videoList,videoZd,videoDetails,forumList,forumAdd,forumDetails,
forumReply,commentReply,experience,experiencezd,experienceDetails,realName,revise,feedback,
- today,carouselDetail,videoAdd,articleAdd
+ today,carouselDetail,videoAdd,articleAdd,wzdxq
}