From e9af667b8a9ce9ca5daca4fd01d9fcd171a20a79 Mon Sep 17 00:00:00 2001 From: ZhaoYang <565837861@qq.com> Date: Tue, 6 Jan 2026 18:57:28 +0800 Subject: [PATCH] =?UTF-8?q?=E5=B8=82=E5=9C=BA=E4=BF=A1=E6=81=AF?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- pages/images/ccp.png | Bin 0 -> 8080 bytes pages/images/scqs.png | Bin 0 -> 4139 bytes pages/images/sl.png | Bin 0 -> 5638 bytes pages/market/market.js | 667 +++++++++++++++++++++++++++++-- pages/market/market.json | 1 + pages/market/market.wxml | 314 ++++++++++++++- pages/market/market.wxss | 772 +++++++++++++++++++++++++++++++++++- pagesA/pages/wzai/wzai.js | 111 ++++-- pagesA/pages/wzai/wzai.wxml | 12 +- utils/api.js | 18 +- utils/tool.wxs | 14 +- 11 files changed, 1824 insertions(+), 85 deletions(-) create mode 100644 pages/images/ccp.png create mode 100644 pages/images/scqs.png create mode 100644 pages/images/sl.png diff --git a/pages/images/ccp.png b/pages/images/ccp.png new file mode 100644 index 0000000000000000000000000000000000000000..ce96e689847f037de2ba6d1a50ed398e25fbfd57 GIT binary patch literal 8080 zcmV;BA8+7^P)Py9N=ZaPRCr$PT@RF2#dW{$`_Khjm48xeqb%}ABsCD08ft3THC5|B2-P4tO4rp& z zz2Le%Yy0{(XdrI|i9c&;SzkN8Vx`i%dgsmoD>}%XXlM>NaYujs?Ag~ijFeu`+eVu8ZdAn$Oi{v0eR`{*`44xT~Vw+t+lpPYRe+KaLZ6}-7TWN7s};Htd&Jv;@?ejAQq6X zZ)w@$4DO2~zpPGl%0h($cU`w5PyPUrJo$I~I1mfSLbJ0v-h$(_t=_St*S_IL_o(XN zx<=G*2C|4l{JUum!~!x^BWHD@Q^%Lph065gV*1H(AQq7GuCelNaU?g*xFypZhy`To z9?}8Wa9^p^VR|sS=`U?*aVa#{luEJqNNI!1FbASI5NiTP#*hQ8X3=v^^;qLD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DD1G%zWI_2)gm<5QE7m*N4*5Q1|sFSTAC7=*mx$_=bNqP|a zTG2ur3l!^-RV}1dgW6KkwL9-|2@oYOBF(xf`GM@ud@~AFE0^A*1Q7JRNH7+bevM#* z+z1s7$?Z!pI|qqEEp*vWnr1#?01$OrZflqUJ(wLiFqvAB0v-qc0vL){G6tgDpujq?iZ)l z0HT$!6OtUu23(`)IfkiD76Y<+5v@>*kN^NUYeE^0Vdl5008tLL2#FFT%5X@p-G^2| z^wof@kf7J>Y^z%@^E`i5vX@&mtFZBDE5Bjjkb$89(acAJCy~jfms?pgc(97|9HFP~ zt5#c)LjY-zkA!}6#=QU@TjEIsmRAYIdMEbApa?P=dY&Wo#%St6 z;?8s^OQvKI@|7mQtT4zkWxmLQm)MifkjqDM3?W?84Ujc2(Of2fMGj}zikAt09-bz; z`0?*}COWJKdizK%V4O&MvWnK1;jvwt44OC-g~=B)tMr@0}?^fYH7-- zhK(54ZIf{`N&1-lOftmj<`U)_nW{1k$Oe?wtAaB{=;|_=*e0`2}csma}zMWXxfCU=1BfYNK}cZJy1ZzUKY5xWJ1pzK-zLn#m#p&9pp zY(SB9PGRvMSX8E)lfyB7T3)_yT6!m)8wQYgjB9y#bXXWhHK1-tKz3jeuQEceLMR$Q z5kF#hKn^_1Z!0j3#eMm4VMCW}=HkKKm&I3q!>s_>fkpnyQYaSoorEpHoY1Sc@v0VX z3&@_-*4!m*a1t*Q{*69CBnCmc^4fd5ZVa@;m002ovPDHLkV1iCYb=Lp@ literal 0 HcmV?d00001 diff --git a/pages/images/sl.png b/pages/images/sl.png new file mode 100644 index 0000000000000000000000000000000000000000..aa07b4973db8977ce21e6715a564e6c959859164 GIT binary patch literal 5638 zcmV+h7WwIkP)Px~z)3_wRCr$PU5k|*Hx8VRMCV9+j>M-(P8-Qtk=TmFRwQ%6h}=g}&2FMlY?5fs zdw%QHcJl+G2%rFRw#WLICGdPc{}mdMpT8yz#($T8O8>v+_kXg1)%^Z7yd%&4vu#`c zj(M(kY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zxfUf;b{04=sY^8o38Y5svzWX+$WhP;5nvuolFhALENx&-Ih&r`q`qfmiY6FXj3bcj z?qp!;M5&)ryjJTfo`L-J_oHuU3bCO)7HM_rZS%mIP;@943>_e#A~eZ@%47vJXC@xV z+Ny~FP%fo@j@%#Z=2V;u<15Unkht>@Xw~U)NDF`<@kcX&)GSc2Jdp^{`s#TXB_e$002Mf|&SI1`AR47Vji+jx;Z^j(lSNq)26g3tpPSQ3kqXsZsz$iuy&n zp1Ghc%Y>hybXOD-ftl zv(z|*4G<*$_zCqH8x<8L{!BUbSd>_mfT~%P^$bS>NkTGpQ>F2I9c4Xt*Ac9upvEC= zfFSXQ2u*|(FB|>@EKvl_i*oGkKLg{R{*?fTc>d$)49L-3V}*kJtSy<(+oQT!Y=9u~ zM=RxsKKHURWC`!&n@~WINA|rrrprzP2pWGhkI>9@Bu84w~nHzrCLu=>?>q^pPcsNzU~5Xc3sQ7`ZKqo5cbMvy5V7p=-vLmw0P` z&+{Nhzn^CKH3N6@EQRi60YqKi?qm_xG{%(xB@ST$#8dn+?vk&OX(T|2L(BlVS^S|{ zp!IBj37F#$20&({cl$5h8o?D3FvlSbfS~0iS^-7YXhvRMJ6EsIrwrf~>u7ef7yxMz zf5h4>sjK=axqRm!`Ea>l`)g-%5In;B{`J_VTwDLq`B(t?V_qSR#ajqmgEl+d{~DZ6>uz z(I1wdcLGiXLOhex6$mx!o_GkQGbl1Ax$D4GwQUAS0uoUuIXyPKaBCJInOAx(XFP+R zx^K13^?EL^9gDxeu1&QnP_Iel{brlo2bSwj0mvvq>M@R;B0(93Y!sSWDtRY=UR%2r gpTE_G+pX99|GZ(beVbTykN^Mx07*qoM6N<$f~f02egFUf literal 0 HcmV?d00001 diff --git a/pages/market/market.js b/pages/market/market.js index 1acf24b..d59f61c 100644 --- a/pages/market/market.js +++ b/pages/market/market.js @@ -1,66 +1,659 @@ +import http from '../../utils/api' + // pages/market/market.js Page({ - - /** - * 页面的初始数据 - */ data: { + // 当前时间 + currentTime: '', + + // 销售市场数据 + salesData: [], + salesUpdateTime: '', + salesStatus: 'inactive', + + // 饲料市场数据 + feedData: [], + feedUpdateTime: '', + feedStatus: 'inactive', + + // 市场趋势数据 + trendData: [], + unreadCount: 0, + // 最后更新时间 + lastUpdateTime: '', + + // 刷新状态 + isRefreshing: false, + + // 动画数据 + headerAnimation: {}, + cardAnimation1: {}, + cardAnimation2: {}, + cardAnimation3: {}, + + // 无缝滚动相关数据 + scrollOffset: 0, // 滚动偏移量 + scrollDuration: 0.5, // 滚动动画持续时间 + scrollTimer: null, // 滚动定时器 + itemHeight: 150, // 每个公告项的高度(估算值,单位:px) + isPaused: false // 是否暂停滚动 }, - /** - * 生命周期函数--监听页面加载 - */ - onLoad(options) { + onLoad: function () { + // 初始化时间 + this.updateCurrentTime(); + + // 初始化数据 + this.initMarketData(); + // 启动动画 + this.startPageAnimations(); + + // 启动定时器 + this.startTimers(); + + // 启动无缝滚动 + this.startAutoScroll(); + this.getsales() + this.getfeed() + this.gettrend() + }, + + onShow: function () { + // 恢复滚动(如果之前暂停了) + if (this.data.isPaused) { + this.setData({ + isPaused: false + }); + this.startAutoScroll(); + } }, - /** - * 生命周期函数--监听页面初次渲染完成 - */ - onReady() { + onHide: function () { + // 页面隐藏时暂停滚动 + this.stopAutoScroll(); + this.setData({ + isPaused: true + }); + }, + onUnload: function () { + // 清理定时器 + this.clearTimers(); + // 停止滚动 + this.stopAutoScroll(); }, - /** - * 生命周期函数--监听页面显示 - */ - onShow() { + // 销售市场 + getsales() { + http.sales({ + data: {}, + success: res => { + console.log(11, res); + this.setData({ + salesData:res.rows + }) + } + }) }, - /** - * 生命周期函数--监听页面隐藏 - */ - onHide() { + //饲料市场 + getfeed() { + http.feed({ + data: {}, + success: res => { + console.log(22, res); + this.setData({ + feedData:res.rows + }) + } + }) + }, + // 市场趋势 + gettrend() { + http.trend({ + data: {}, + success: res => { + console.log(22, res); + this.setData({ + trendData:res.rows + }) + } + }) }, - /** - * 生命周期函数--监听页面卸载 - */ - onUnload() { + onPullDownRefresh: function () { + this.refreshAllData(); + }, + // 更新当前时间 + updateCurrentTime: function () { + const now = new Date(); + const timeStr = `${now.getHours().toString().padStart(2, '0')}:${now.getMinutes().toString().padStart(2, '0')}`; + this.setData({ + currentTime: timeStr + }); }, - /** - * 页面相关事件处理函数--监听用户下拉动作 - */ - onPullDownRefresh() { + // 启动定时器 + startTimers: function () { + // 更新时间 + this.timeTimer = setInterval(() => { + this.updateCurrentTime(); + }, 60000); + // 模拟实时数据更新 + this.dataTimer = setInterval(() => { + this.updateRandomData(); + }, 30000); }, - /** - * 页面上拉触底事件的处理函数 - */ - onReachBottom() { + // 清理定时器 + clearTimers: function () { + if (this.timeTimer) clearInterval(this.timeTimer); + if (this.dataTimer) clearInterval(this.dataTimer); + }, + // 启动自动滚动 + startAutoScroll: function () { + // 清除已有的定时器 + if (this.data.scrollTimer) { + clearInterval(this.data.scrollTimer); + } + + // 计算总高度(一条数据的高度 * 数据条数) + const totalHeight = this.data.itemHeight * this.data.trendData.length; + + // 设置滚动定时器,每5秒滚动一次 + const scrollTimer = setInterval(() => { + this.autoScrollStep(totalHeight); + }, 5000); + + this.setData({ + scrollTimer + }); + }, + + // 停止自动滚动 + stopAutoScroll: function () { + if (this.data.scrollTimer) { + clearInterval(this.data.scrollTimer); + this.setData({ + scrollTimer: null + }); + } + }, + + // 自动滚动步骤 + autoScrollStep: function (totalHeight) { + // 计算下一个偏移量 + let nextOffset = this.data.scrollOffset + this.data.itemHeight; + + // 如果滚动到了第一组数据的末尾,重置到开始位置 + if (nextOffset >= totalHeight) { + // 瞬间回到起点,然后继续滚动 + this.setData({ + scrollOffset: 0, + scrollDuration: 0 + }); + + // 下一帧继续正常滚动 + setTimeout(() => { + this.setData({ + scrollOffset: this.data.itemHeight, + scrollDuration: 0.5 + }); + }, 50); + } else { + // 正常滚动 + this.setData({ + scrollOffset: nextOffset, + scrollDuration: 0.5 + }); + } + }, + + // 手动控制滚动(可选) + pauseScroll: function () { + this.stopAutoScroll(); + this.setData({ + isPaused: true + }); + }, + + resumeScroll: function () { + if (this.data.isPaused) { + this.setData({ + isPaused: false + }); + this.startAutoScroll(); + } }, - /** - * 用户点击右上角分享 - */ - onShareAppMessage() { + // 初始化市场数据 + initMarketData: function () { + // 模拟销售市场数据(6条数据) + const salesData = [{ + id: 1, + name: '优质肉牛', + region: '内蒙古呼伦贝尔', + price: 35.8, + unit: '公斤', + trend: 'up', + change: '+2.3%', + updateTime: '09:30' + }, + { + id: 2, + name: '绵羊', + region: '新疆阿勒泰', + price: 28.5, + unit: '公斤', + trend: 'stable', + change: '0%', + updateTime: '09:25' + }, + { + id: 3, + name: '山羊', + region: '山东济宁', + price: 32.2, + unit: '公斤', + trend: 'down', + change: '-1.5%', + updateTime: '09:20' + }, + { + id: 4, + name: '奶牛', + region: '黑龙江', + price: 26.8, + unit: '公斤', + trend: 'up', + change: '+1.2%', + updateTime: '09:15' + }, + { + id: 5, + name: '生猪', + region: '河南', + price: 18.5, + unit: '公斤', + trend: 'up', + change: '+3.1%', + updateTime: '09:10' + }, + { + id: 6, + name: '肉羊', + region: '甘肃', + price: 30.2, + unit: '公斤', + trend: 'stable', + change: '0%', + updateTime: '09:05' + } + ]; + + // 模拟饲料市场数据(5条数据) + const feedData = [{ + id: 1, + name: '玉米饲料', + supplier: '内蒙古正大饲料有限公司', + price: 2.85, + unit: '公斤', + trend: 'up', + chartHeight: 85, + updateTime: '09:28' + }, + { + id: 2, + name: '豆粕', + supplier: '山东六和集团股份有限公司', + price: 3.42, + unit: '公斤', + trend: 'up', + chartHeight: 92, + updateTime: '09:25' + }, + { + id: 3, + name: '青贮饲料', + supplier: '河北牧原股份有限责任公司', + price: 0.78, + unit: '公斤', + trend: 'stable', + chartHeight: 65, + updateTime: '09:22' + }, + { + id: 4, + name: '麦麸', + supplier: '河南双汇发展有限公司', + price: 1.25, + unit: '公斤', + trend: 'down', + chartHeight: 45, + updateTime: '09:20' + }, + { + id: 5, + name: '鱼粉', + supplier: '广东海大集团', + price: 5.8, + unit: '公斤', + trend: 'stable', + chartHeight: 60, + updateTime: '09:18' + } + ]; + + // 模拟市场趋势通知公告数据(8条数据) + const trendData = [{ + id: 1, + type: 'report', + title: '2023年Q3畜牧业市场分析报告发布', + source: '国家统计局', + date: '2023-10-15', + summary: '第三季度畜产品价格整体上涨3.2%,饲料成本下降1.5%,养殖效益显著提升', + isNew: true, + isHot: true + }, + { + id: 2, + type: 'prediction', + title: '专家预测:四季度牛肉价格将稳中有升', + source: '行业专家委员会', + date: '2023-10-12', + summary: '受季节因素影响,预计四季度牛肉价格上涨幅度在3-5%之间', + isNew: true, + isHot: false + }, + { + id: 3, + type: 'report', + title: '全国饲料价格指数月报(9月份)', + source: '农业部监测中心', + date: '2023-10-10', + summary: '9月份全国饲料价格指数为108.5,环比上涨0.8%,同比上涨2.3%', + isNew: false, + isHot: true + }, + { + id: 4, + type: 'prediction', + title: '冬季饲草供应紧张预警', + source: '气象局农业处', + date: '2023-10-08', + summary: '北方地区提前进入冬季,预计饲草储备量不足,价格可能上涨', + isNew: true, + isHot: true + }, + { + id: 5, + type: 'report', + title: '牛羊养殖效益分析报告', + source: '畜牧业协会', + date: '2023-10-05', + summary: '2023年1-9月牛羊养殖效益同比增长8.5%,创近三年新高', + isNew: false, + isHot: false + }, + { + id: 6, + type: 'report', + title: '畜产品质量安全监测报告', + source: '质量监督局', + date: '2023-10-03', + summary: '第三季度畜产品质量抽检合格率达99.2%,质量安全状况良好', + isNew: false, + isHot: false + }, + { + id: 7, + type: 'prediction', + title: '明年饲料原料价格走势分析', + source: '农业经济研究所', + date: '2023-10-01', + summary: '预计明年玉米、豆粕等主要原料价格将保持稳定,波动幅度有限', + isNew: false, + isHot: false + }, + { + id: 8, + type: 'report', + title: '畜牧业数字化转型进展报告', + source: '工信部', + date: '2023-09-28', + summary: '全国畜牧业数字化率已达45%,智能养殖设备普及率显著提升', + isNew: false, + isHot: true + } + ]; + + // 计算未读数量 + const unreadCount = trendData.filter(item => item.isNew).length; + + const now = new Date(); + const timeStr = `${now.getMonth()+1}月${now.getDate()}日 ${now.getHours()}:${now.getMinutes().toString().padStart(2, '0')}`; + const lastUpdateTime = `${now.getHours()}:${now.getMinutes().toString().padStart(2, '0')}`; + + this.setData({ + salesData, + feedData, + trendData, + unreadCount, + salesUpdateTime: timeStr, + feedUpdateTime: timeStr, + lastUpdateTime, + salesStatus: 'inactive', + feedStatus: 'inactive' + }); + + // 模拟数据加载完成 + setTimeout(() => { + this.setData({ + salesStatus: 'active', + feedStatus: 'active' + }); + }, 1500); + }, + + // 启动页面动画 + startPageAnimations: function () { + // 头部动画 + const headerAnimation = wx.createAnimation({ + duration: 800, + timingFunction: 'ease-out' + }); + headerAnimation.translateY(0).opacity(1).step(); + + // 卡片动画 + const cardAnimation1 = wx.createAnimation({ + duration: 600, + timingFunction: 'cubic-bezier(0.4, 0, 0.2, 1)', + delay: 200 + }); + cardAnimation1.translateY(0).opacity(1).step(); + + const cardAnimation2 = wx.createAnimation({ + duration: 600, + timingFunction: 'cubic-bezier(0.4, 0, 0.2, 1)', + delay: 350 + }); + cardAnimation2.translateY(0).opacity(1).step(); + + const cardAnimation3 = wx.createAnimation({ + duration: 600, + timingFunction: 'cubic-bezier(0.4, 0, 0.2, 1)', + delay: 500 + }); + cardAnimation3.translateY(0).opacity(1).step(); + + this.setData({ + headerAnimation: headerAnimation.export(), + cardAnimation1: cardAnimation1.export(), + cardAnimation2: cardAnimation2.export(), + cardAnimation3: cardAnimation3.export() + }); + }, + + // 刷新所有数据 + refreshAllData: function () { + if (this.data.isRefreshing) return; + + this.setData({ + isRefreshing: true, + salesStatus: 'active', + feedStatus: 'active' + }); + + // 显示加载动画 + wx.showLoading({ + title: '更新数据中...', + mask: true + }); + + // 模拟网络请求 + setTimeout(() => { + // 更新数据 + this.updateRandomData(); + + // 更新时间戳 + const now = new Date(); + const timeStr = `${now.getMonth()+1}月${now.getDate()}日 ${now.getHours()}:${now.getMinutes().toString().padStart(2, '0')}`; + const lastUpdateTime = `${now.getHours()}:${now.getMinutes().toString().padStart(2, '0')}`; + + this.setData({ + salesUpdateTime: timeStr, + feedUpdateTime: timeStr, + lastUpdateTime, + isRefreshing: false, + salesStatus: 'inactive', + feedStatus: 'inactive' + }); + + // 显示成功提示 + wx.hideLoading(); + wx.showToast({ + title: '数据已更新', + icon: 'success', + duration: 1500 + }); + + // 停止下拉刷新 + wx.stopPullDownRefresh(); + }, 1500); + }, + + // 更新随机数据(模拟实时变化) + updateRandomData: function () { + // 随机更新销售价格 + const updatedSalesData = this.data.salesData.map(item => { + const random = Math.random(); + let newPrice, trend, change; + + if (random < 0.4) { + // 上涨 + trend = 'up'; + change = +(Math.random() * 0.5 + 0.1).toFixed(1); + newPrice = +(item.price * (1 + change / 100)).toFixed(1); + } else if (random < 0.7) { + // 稳定 + trend = 'stable'; + change = 0; + newPrice = item.price; + } else { + // 下降 + trend = 'down'; + change = +(Math.random() * 0.5 + 0.1).toFixed(1); + newPrice = +(item.price * (1 - change / 100)).toFixed(1); + } + + // 更新时间 + const now = new Date(); + const updateTime = `${now.getHours().toString().padStart(2, '0')}:${now.getMinutes().toString().padStart(2, '0')}`; + + return { + ...item, + price: newPrice, + trend, + change: trend === 'stable' ? '0%' : (trend === 'up' ? `+${change}%` : `-${change}%`), + updateTime + }; + }); + + // 随机更新饲料价格 + const updatedFeedData = this.data.feedData.map(item => { + const random = Math.random(); + let trend, chartHeight; + + if (random < 0.4) { + trend = 'up'; + chartHeight = Math.floor(Math.random() * 30 + 70); + } else if (random < 0.7) { + trend = 'stable'; + chartHeight = Math.floor(Math.random() * 20 + 50); + } else { + trend = 'down'; + chartHeight = Math.floor(Math.random() * 20 + 30); + } + + // 轻微调整价格 + const priceChange = (Math.random() - 0.5) * 0.1; + const newPrice = +(item.price + priceChange).toFixed(2); + + // 更新时间 + const now = new Date(); + const updateTime = `${now.getHours().toString().padStart(2, '0')}:${now.getMinutes().toString().padStart(2, '0')}`; + + return { + ...item, + price: newPrice > 0 ? newPrice : item.price, + trend, + chartHeight, + updateTime + }; + }); + + // 随机更新趋势数据(标记一些为已读,添加新公告) + const updatedTrendData = [...this.data.trendData]; + + // 随机标记一些为已读 + updatedTrendData.forEach((item, index) => { + if (item.isNew && Math.random() > 0.7) { + updatedTrendData[index] = { + ...item, + isNew: false + }; + } + }); + + // 偶尔添加新公告 + if (Math.random() > 0.8) { + const newNotice = { + id: Date.now(), + type: Math.random() > 0.5 ? 'report' : 'prediction', + title: `实时快报:${Math.random() > 0.5 ? '价格波动提醒' : '行业动态更新'}`, + source: '实时监测系统', + date: new Date().toISOString().split('T')[0], + summary: '系统监测到市场出现新的变化,请关注后续详细分析', + isNew: true, + isHot: Math.random() > 0.7 + }; + updatedTrendData.unshift(newNotice); + } + + const unreadCount = updatedTrendData.filter(item => item.isNew).length; + this.setData({ + salesData: updatedSalesData, + feedData: updatedFeedData, + trendData: updatedTrendData, + unreadCount + }); } -}) \ No newline at end of file +}); \ No newline at end of file diff --git a/pages/market/market.json b/pages/market/market.json index 8835af0..5fef5c4 100644 --- a/pages/market/market.json +++ b/pages/market/market.json @@ -1,3 +1,4 @@ { + "navigationBarTitleText":"市场信息", "usingComponents": {} } \ No newline at end of file diff --git a/pages/market/market.wxml b/pages/market/market.wxml index 6a94b68..add24fb 100644 --- a/pages/market/market.wxml +++ b/pages/market/market.wxml @@ -1,2 +1,312 @@ - -pages/market/market.wxml \ No newline at end of file + + + + + + + + + + + + + 畜牧业市场信息 + 实时行情 · 专业洞察 · 精准决策 + + + + + + {{currentTime}} + + + + + + + + {{salesData.length}} + 畜产品类 + + + + {{feedData.length}} + 饲料品类 + + + + {{trendData.length}} + 趋势公告 + + + + + + + + + + + 销售市场 + 畜产品价格动态 + + + {{salesData.length}}条 + + + + + + + + + + + 畜产品实时价格 + + 各地牛、羊等畜产品的市场价格动态 + + + + {{salesStatus === 'active' ? '更新中' : '已更新'}} + + + + + + + + + {{item.productName}} + {{item.regionDetail}} + + + ¥{{item.price}} + {{item.unit}} + + + + + +{{item.priceChange}}% + + + + + {{item.updateTime}} + + + + + + + + + 更新于 {{salesUpdateTime}} + + + + 上下滚动查看更多 + + + + + + + 饲料市场 + 饲草料供应商价格 + + + {{feedData.length}}条 + + + + + + + + + + + + + 饲料价格行情 + + 各地饲草料供应商实时报价 + + + + {{feedStatus === 'active' ? '更新中' : '已更新'}} + + + + + + + + + {{item.feedName}} + {{item.supplier}} + + + + ¥{{item.price}} + {{item.unit}} + + + + + + + + + {{item.updateTime}} + + + + + + + + + 更新于 {{feedUpdateTime}} + + + + 上下滚动查看更多 + + + + + + + + 市场趋势 + 通知公告与行业分析 + + + {{unreadCount}}条未读 + + + + + + + + + + + + + 行业洞察与预测 + + 行业报告和专家预测等信息,把握市场发展方向 + + + + + + + + + + + + {{item.category === '报告' ? '报告' : '预测'}} + + + + + + {{item.title}} + + 热点 + + + + + + {{item.content}} + + {{item.source}} + {{item.publishDate}} + + + + + + + + + + + {{item.category === '报告' ? '报告' : '预测'}} + + + + + + {{item.title}} + + 热点 + + + + + + {{item.content}} + + {{item.source}} + {{item.publishDate}} + + + + + + + + + + 共 {{trendData.length}} 条公告 · 自动滚动 + + + + 每5秒自动滚动 + + + + + + + + + 数据每30分钟自动同步 · 最后更新 {{lastUpdateTime}} + + + + \ No newline at end of file diff --git a/pages/market/market.wxss b/pages/market/market.wxss index b4d0a7e..3440f50 100644 --- a/pages/market/market.wxss +++ b/pages/market/market.wxss @@ -1 +1,771 @@ -/* pages/market/market.wxss */ \ No newline at end of file +.market-page { + min-height: 100vh; + background: linear-gradient(180deg, #f8fafc 0%, #f1f5f9 100%); + } + + /* 头部容器优化 */ + .header-container { + position: relative; + overflow: hidden; + border-radius: 0 0 40rpx 40rpx; + box-shadow: 0 4rpx 20rpx rgba(26, 124, 58, 0.15); + } + + .header-bg { + position: absolute; + top: 0; + left: 0; + width: 100%; + height: 100%; + } + + .bg-gradient { + position: absolute; + width: 100%; + height: 100%; + background: linear-gradient(135deg, + rgba(26, 124, 58, 0.95) 0%, + rgba(46, 204, 113, 0.9) 50%, + rgba(46, 204, 113, 0.85) 100%); + } + + .bg-pattern { + position: absolute; + width: 100%; + height: 100%; + background-image: + radial-gradient(circle at 20% 80%, rgba(255, 255, 255, 0.1) 2rpx, transparent 2rpx), + radial-gradient(circle at 80% 20%, rgba(255, 255, 255, 0.1) 2rpx, transparent 2rpx); + background-size: 60rpx 60rpx; + } + + .header-content { + position: relative; + z-index: 2; + padding: 40rpx 32rpx 0; + } + + .header-main { + display: flex; + justify-content: space-between; + align-items: flex-start; + margin-bottom: 30rpx; + } + + .title-area { + flex: 1; + } + + .app-name { + font-size: 44rpx; + font-weight: 700; + color: white; + letter-spacing: 1rpx; + margin-bottom: 8rpx; + text-shadow: 0 2rpx 4rpx rgba(0, 0, 0, 0.1); + } + + .app-desc { + font-size: 24rpx; + color: rgba(255, 255, 255, 0.9); + } + + .header-actions { + display: flex; + align-items: center; + gap: 20rpx; + } + + .time-display { + display: flex; + align-items: center; + background: rgba(255, 255, 255, 0.15); + padding: 8rpx 16rpx; + border-radius: 20rpx; + font-size: 22rpx; + color: white; + } + + .time-display .iconfont { + font-size: 24rpx; + margin-right: 8rpx; + } + + + .iconfont.rotating { + animation: rotate 1s linear infinite; + } + + @keyframes rotate { + from { + transform: rotate(0deg); + } + to { + transform: rotate(360deg); + } + } + + /* 数据统计摘要优化 */ + .data-summary { + display: flex; + background: rgba(255, 255, 255, 0.15); + backdrop-filter: blur(10rpx); + border-radius: 20rpx; + padding: 24rpx; + margin-bottom: 30rpx; + border: 1rpx solid rgba(255, 255, 255, 0.2); + } + + .summary-item { + flex: 1; + display: flex; + flex-direction: column; + align-items: center; + } + + .summary-value { + font-size: 36rpx; + font-weight: 700; + color: white; + margin-bottom: 8rpx; + } + + .summary-label { + font-size: 22rpx; + color: rgba(255, 255, 255, 0.9); + } + + .summary-divider { + width: 1rpx; + background: rgba(255, 255, 255, 0.3); + margin: 0 20rpx; + } + + /* 内容容器优化 */ + .content-container { + height: calc(100vh - 280rpx); + padding: 0 32rpx; + box-sizing: border-box; + } + + /* 区块标题优化 */ + .section-title { + display: flex; + align-items: center; + margin: 40rpx 0 20rpx; + padding-bottom: 16rpx; + border-bottom: 2rpx solid #e2e8f0; + position: relative; + opacity: 0; + transform: translateX(-20rpx); + animation: slideIn 0.6s ease forwards; + } + + .fade-in-item { + opacity: 0; + transform: translateX(-20rpx); + animation: slideIn 0.6s ease forwards; + } + + @keyframes slideIn { + to { + opacity: 1; + transform: translateX(0); + } + } + + + + .section-text { + font-size: 32rpx; + font-weight: 600; + color: #1e293b; + margin-right: 16rpx; + } + + .section-desc { + font-size: 24rpx; + color: #64748b; + flex: 1; + } + + .section-indicator { + width: 6rpx; + height: 32rpx; + background: #1a7c3a; + border-radius: 3rpx; + margin-left: 20rpx; + } + + .data-count { + background: #e2e8f0; + color: #64748b; + font-size: 22rpx; + padding: 4rpx 12rpx; + border-radius: 12rpx; + margin-left: 12rpx; + } + + .unread-badge { + background: #ef4444; + color: white; + font-size: 20rpx; + padding: 4rpx 12rpx; + border-radius: 12rpx; + margin-left: 12rpx; + font-weight: 500; + } + + /* 卡片通用样式优化 */ + .market-card { + background: white; + border-radius: 24rpx; + overflow: hidden; + margin-bottom: 32rpx; + box-shadow: 0 8rpx 32rpx rgba(0, 0, 0, 0.06); + position: relative; + border: 1rpx solid #e2e8f0; + opacity: 0; + transform: translateY(40rpx); + } + + .market-card:active { + transform: translateY(2rpx); + box-shadow: 0 4rpx 16rpx rgba(0, 0, 0, 0.08); + } + + + .card-header { + padding: 32rpx 32rpx 20rpx; + border-bottom: 1rpx solid #f1f5f9; + display: flex; + justify-content: space-between; + align-items: flex-start; + } + + .card-title-area { + flex: 1; + } + + .card-main-title { + display: flex; + align-items: center; + margin-bottom: 12rpx; + } + + .card-icon { + width: 56rpx; + height: 56rpx; + border-radius: 14rpx; + margin-right: 16rpx; + display: flex; + align-items: center; + justify-content: center; + overflow: hidden; + } + + .card-sales .card-icon { + background: linear-gradient(135deg, #ff6b6b, #ff8e8e); + } + + .card-feed .card-icon { + background: linear-gradient(135deg, #4d96ff, #6bc5ff); + } + + .card-trend .card-icon { + background: linear-gradient(135deg, #ffd166, #ffde8a); + } + + .icon-img { + width: 40rpx; + height: 40rpx; + } + + .card-title-text { + font-size: 32rpx; + font-weight: 600; + color: #1e293b; + } + + .card-subtitle { + font-size: 24rpx; + color: #64748b; + line-height: 1.4; + } + + .card-status { + display: flex; + align-items: center; + gap: 8rpx; + } + + .status-dot { + width: 12rpx; + height: 12rpx; + border-radius: 50%; + } + + .status-dot.active { + background: #10b981; + animation: pulse 2s infinite; + } + + .status-dot.inactive { + background: #94a3b8; + } + + @keyframes pulse { + 0%, 100% { + opacity: 1; + } + 50% { + opacity: 0.5; + } + } + + .status-text { + font-size: 22rpx; + color: #64748b; + } + + /* 数据滚动容器 */ + .data-scroll-container { + padding: 0 32rpx; + box-sizing: border-box; + } + + /* 销售市场列表样式 */ + .price-list { + padding: 20rpx 0; + } + + .price-item { + padding: 28rpx 0; + border-bottom: 1rpx solid #f1f5f9; + display: flex; + flex-direction: column; + gap: 12rpx; + } + + .price-item:last-child { + border-bottom: none; + } + + .price-info { + display: flex; + justify-content: space-between; + align-items: flex-start; + } + + .product-name { + font-size: 28rpx; + font-weight: 500; + color: #1e293b; + } + + .product-region { + font-size: 22rpx; + color: #64748b; + background: #f8fafc; + padding: 4rpx 12rpx; + border-radius: 12rpx; + } + + .price-value { + display: flex; + align-items: baseline; + justify-content: space-between; + } + + .price-number { + font-size: 36rpx; + font-weight: 600; + } + + .price-unit { + font-size: 22rpx; + color: #64748b; + margin-left: 8rpx; + } + + .trend-indicator { + display: flex; + align-items: center; + gap: 8rpx; + } + + .trend-icon { + font-size: 28rpx; + } + + .trend-change { + font-size: 22rpx; + font-weight: 500; + } + + .price-value.up { + color: #ef4444; + } + + .price-value.down { + color: #10b981; + } + + .price-value.stable { + color: #6b7280; + } + + .price-time { + display: flex; + align-items: center; + gap: 8rpx; + font-size: 22rpx; + color: #94a3b8; + } + + .iconfont.icon-clock-small { + font-size: 20rpx; + } + + /* 饲料市场列表样式 */ + .supplier-list { + padding: 20rpx 0; + } + + .supplier-item { + padding: 28rpx 0; + border-bottom: 1rpx solid #f1f5f9; + display: flex; + flex-direction: column; + gap: 12rpx; + } + + .supplier-item:last-child { + border-bottom: none; + } + + .supplier-info { + display: flex; + justify-content: space-between; + align-items: flex-start; + } + + .supplier-name { + font-size: 28rpx; + font-weight: 500; + color: #1e293b; + } + + .supplier-company { + font-size: 22rpx; + color: #64748b; + background: #f8fafc; + padding: 4rpx 12rpx; + border-radius: 12rpx; + max-width: 200rpx; + overflow: hidden; + text-overflow: ellipsis; + white-space: nowrap; + } + + .price-display { + display: flex; + align-items: center; + justify-content: space-between; + } + + .price-tag { + padding: 8rpx 20rpx; + border-radius: 20rpx; + font-weight: 600; + display: flex; + align-items: baseline; + min-width: 150rpx; + } + + .price-tag.up { + background: #fef2f2; + color: #ef4444; + } + + .price-tag.down { + background: #f0fdf4; + color: #10b981; + } + + .price-tag.stable { + background: #f8fafc; + color: #6b7280; + } + + .price-label { + font-size: 32rpx; + } + + .price-per { + font-size: 22rpx; + margin-left: 4rpx; + } + + .trend-chart-small { + width: 80rpx; + height: 40rpx; + display: flex; + align-items: flex-end; + gap: 4rpx; + } + + .chart-bar { + flex: 1; + border-radius: 4rpx 4rpx 0 0; + min-height: 8rpx; + } + + .chart-bar.up { + background: #ef4444; + } + + .chart-bar.down { + background: #10b981; + } + + .chart-bar.stable { + background: #94a3b8; + } + + .supplier-time { + display: flex; + align-items: center; + gap: 8rpx; + font-size: 22rpx; + color: #94a3b8; + } + + +/* 市场趋势通知公告样式*/ +.notice-scroll-wrapper { + position: relative; + overflow: hidden; + padding: 0 32rpx; + } + + .notice-scroll-content { + position: relative; + } + + /* 无缝滚动列表样式 */ + .notice-list { + padding: 20rpx 0; + } + + .notice-item { + display: flex; + padding: 28rpx 0; + border-bottom: 1rpx solid #f1f5f9; + gap: 20rpx; + } + + .notice-item:last-child { + border-bottom: none; + } + + .notice-left { + display: flex; + flex-direction: column; + align-items: center; + gap: 8rpx; + } + + .notice-type { + padding: 4rpx 12rpx; + border-radius: 12rpx; + font-size: 20rpx; + font-weight: 500; + min-width: 60rpx; + text-align: center; + } + + .notice-type.report { + background: rgba(59, 130, 246, 0.1); + color: #3b82f6; + } + + .notice-type.prediction { + background: rgba(139, 92, 246, 0.1); + color: #8b5cf6; + } + + .notice-marker { + width: 8rpx; + height: 8rpx; + border-radius: 50%; + background: #94a3b8; + } + + .notice-marker.new { + background: #3b82f6; + animation: blink 2s infinite; + } + + @keyframes blink { + 0%, 100% { + opacity: 1; + } + 50% { + opacity: 0.5; + } + } + + .notice-content { + flex: 1; + display: flex; + flex-direction: column; + gap: 12rpx; + } + + .notice-title-area { + display: flex; + align-items: center; + gap: 12rpx; + flex-wrap: wrap; + } + + .notice-title { + font-size: 28rpx; + font-weight: 500; + color: #1e293b; + flex: 1; + min-width: 200rpx; + } + + .notice-tag { + padding: 4rpx 10rpx; + border-radius: 8rpx; + font-size: 20rpx; + font-weight: 500; + } + + .notice-tag.hot { + background: #fef2f2; + color: #ef4444; + } + + .notice-tag.new { + background: #eff6ff; + color: #3b82f6; + } + + .notice-summary { + font-size: 24rpx; + color: #64748b; + line-height: 1.4; + } + + .notice-footer { + display: flex; + align-items: center; + gap: 20rpx; + font-size: 22rpx; + color: #94a3b8; + } + + /* 卡片底部优化 */ + .card-footer { + padding: 24rpx 32rpx; + background: #f8fafc; + border-top: 1rpx solid #f1f5f9; + display: flex; + justify-content: space-between; + align-items: center; + } + + .update-info { + display: flex; + align-items: center; + gap: 8rpx; + } + + .iconfont.icon-clock { + font-size: 20rpx; + color: #94a3b8; + } + + .update-text { + font-size: 22rpx; + color: #64748b; + } + + .scroll-tip { + display: flex; + align-items: center; + gap: 8rpx; + font-size: 22rpx; + color: #94a3b8; + } + + .scroll-tip .iconfont { + font-size: 20rpx; + } + + .statistics-info { + flex: 1; + } + + .stat-text { + font-size: 22rpx; + color: #64748b; + } + + .auto-scroll-tip { + display: flex; + align-items: center; + gap: 8rpx; + font-size: 22rpx; + color: #94a3b8; + } + + .auto-scroll-tip .iconfont { + font-size: 20rpx; + animation: rotate 2s linear infinite; + } + + + /* 更新页脚优化 */ + .update-footer { + padding: 32rpx 0 100rpx; + text-align: center; + opacity: 0; + transform: translateY(20rpx); + animation: slideIn 0.6s ease 0.3s forwards; + } + + .update-line { + display: flex; + align-items: center; + justify-content: center; + gap: 8rpx; + margin-bottom: 12rpx; + } + + .iconfont.icon-sync { + font-size: 20rpx; + color: #94a3b8; + } + + .update-tip { + font-size: 22rpx; + color: #64748b; + } + + /* 卡片特定样式 */ + .card-sales { + border-top: 4rpx solid #ff6b6b; + } + + .card-feed { + border-top: 4rpx solid #4d96ff; + } + + .card-trend { + border-top: 4rpx solid #ffd166; + } \ No newline at end of file diff --git a/pagesA/pages/wzai/wzai.js b/pagesA/pages/wzai/wzai.js index facee6a..3bd1bc6 100644 --- a/pagesA/pages/wzai/wzai.js +++ b/pagesA/pages/wzai/wzai.js @@ -10,7 +10,7 @@ Page({ autoFocus: false, // 症状选择 quickSymptoms: [], - wzsearch:{}, + wzsearch: {}, selectedSymptoms: [], showSymptomSelector: false, // 状态控制 @@ -54,7 +54,6 @@ Page({ setInterval(() => { this.updateCurrentTime(); }, 60000); - }, // 更新当前时间 @@ -94,61 +93,102 @@ Page({ console.log(666, this.data.messages) - // 模拟AI思考 - this.simulateAIResponse(message); - }, - - // 获取当前时间 - getCurrentTime() { - const now = new Date(); - return `${now.getHours().toString().padStart(2, '0')}:${now.getMinutes().toString().padStart(2, '0')}`; - }, - - // 模拟AI响应 - simulateAIResponse(userMessage) { + // 先显示AI思考状态 this.setData({ isAIThinking: true }); - console.log(888, userMessage); - // 模拟AI思考时间 + // 模拟AI思考时间(1.5-2.5秒) setTimeout(() => { - const aiMessage = this.generateAIResponse(userMessage); - console.log(333, aiMessage); - this.setData({ - messages: [...this.data.messages, aiMessage], - isAIThinking: false - }); - console.log(789, this.data.messages); + this.generateAIResponse(message); }, 1500 + Math.random() * 1000); + }, + // 获取当前时间 + getCurrentTime() { + const now = new Date(); + return `${now.getHours().toString().padStart(2, '0')}:${now.getMinutes().toString().padStart(2, '0')}`; }, // 生成AI响应 generateAIResponse(userMessage) { - console.log(444, userMessage); + console.log(888, userMessage); + http.search({ data: { keyword: userMessage }, success: res => { - console.log('查询结果', res) - - const wzsearch = res.rows[0] - - return { + console.log('查询结果', res); + + let aiMessage; + if (res.rows && res.rows.length > 0) { + const wzsearch = res.rows[0]; + + aiMessage = { + id: Date.now() + 1, + type: 'assistant', + content:'根据您的描述,' + wzsearch.title || '已收到您的症状描述', + diagnosis: wzsearch, + time: this.getCurrentTime() + }; + } else { + // 如果没有查询到结果 + aiMessage = { + id: Date.now() + 1, + type: 'assistant', + content: '已收到您的症状描述', + diagnosis: { + possibleDiseases: '暂无匹配诊断', + severityLevel: '未知', + suggestions: '建议您提供更详细的症状描述,或直接咨询专业兽医' + }, + time: this.getCurrentTime() + }; + } + + // 添加AI消息到聊天记录并隐藏思考状态 + this.setData({ + messages: [...this.data.messages, aiMessage], + isAIThinking: false + }); + + console.log(789, this.data.messages); + }, + fail: err => { + console.error('API请求失败:', err); + + // API失败时的默认响应 + const aiMessage = { id: Date.now() + 1, type: 'assistant', - content: wzsearch.title, - diagnosis: wzsearch, + content: '已收到您的症状描述', + diagnosis: { + disease: '网络请求失败', + severity: 'unknown', + severityText: '未知', + suggestion: '请检查网络连接后重试,或直接联系兽医' + }, time: this.getCurrentTime() }; + + this.setData({ + messages: [...this.data.messages, aiMessage], + isAIThinking: false + }); + }, + complete: () => { + // 确保无论如何都会隐藏思考状态 + if (this.data.isAIThinking) { + this.setData({ + isAIThinking: false + }); + } } - }) + }); + }, - - }, // 选择快捷症状 selectQuickSymptom(e) { @@ -159,9 +199,6 @@ Page({ this.sendMessage(); }, - - - // 返回 goBack() { wx.navigateBack(); diff --git a/pagesA/pages/wzai/wzai.wxml b/pagesA/pages/wzai/wzai.wxml index f91bed9..f556d68 100644 --- a/pagesA/pages/wzai/wzai.wxml +++ b/pagesA/pages/wzai/wzai.wxml @@ -1,5 +1,5 @@ + - @@ -62,7 +62,7 @@ - 根据您的描述,{{item.content}} + {{item.content}} @@ -70,17 +70,17 @@ 可能病症: - {{item.diagnosis.disease}} + {{item.diagnosis.possibleDiseases}} 严重程度: - - {{item.diagnosis.severityText}} + + {{item.diagnosis.severityLevel}} 建议措施: - {{item.diagnosis.suggestion}} + {{item.diagnosis.suggestions}} * 本结果仅供参考,请及时咨询专业兽医 diff --git a/utils/api.js b/utils/api.js index a1415f1..a3bd0cb 100644 --- a/utils/api.js +++ b/utils/api.js @@ -41,8 +41,24 @@ function search(params) { http('/system/base/search', 'get', params) } +// 销售市场 +function sales(params) { + http('/muhu/sales/list', 'get', params) +} + +// 饲料市场 +function feed(params) { + http('/muhu/feed/list', 'get', params) +} + +// 市场趋势 +function trend(params) { + http('/muhu/trend/list', 'get', params) +} + + export default { // 暴露接口 login,carousel,disaster,pharmacy,guidance,getPhoneNumber,inquiry, - search + search,trend,feed,sales } diff --git a/utils/tool.wxs b/utils/tool.wxs index a1753a0..2f0e4a4 100644 --- a/utils/tool.wxs +++ b/utils/tool.wxs @@ -9,11 +9,23 @@ function type(name) { } } +// 严重程度区分 +function ztLevel(type) { + if(type=='轻度'){ + return 'low' + }else if(type=='中度'){ + return 'moderate' + }else{ + return 'high' + } +} + module.exports = { - type:type + type:type, + ztLevel:ztLevel } \ No newline at end of file