李程龙 3 سال پیش
والد
کامیت
0b750737cf

+ 1 - 0
.gitignore

@@ -0,0 +1 @@
+/node_modules

+ 2 - 0
README.md

@@ -32,6 +32,7 @@
 			|-- history.vue					//  气象环境历史记录
 			|-- index.vue					//  气象环境检测列表
 			|-- style.scss					//  气象环境模块样式
+			|-- warn      			 		//  预警消息
 		--|
 		|-- worm    					//  虫情监测模块
 			|-- components					//  虫情监测模块组件
@@ -40,6 +41,7 @@
 			|-- history.vue					//  虫情历史数据
 			|-- image.vue					//  查看图片
 			|-- index.vue					//  虫情监测列表
+			|-- warn      			 		//  预警消息
 		--|
 	--|
 	|-- config							// 全局配置模块

+ 27 - 0
api/warning.js

@@ -0,0 +1,27 @@
+import request from '@/utils/request/index.js'
+import {
+	timeFormat
+} from '@/utils/utils.js'
+
+/**
+ * 预警信息模块
+ */
+
+//预警信息模块请求父类函数
+const  warnRequest = async (url, data) => {
+	const res = await request.post(`api/api_gateway?method=${url}`, data);
+	return res?.data;
+}
+
+
+// 气象站、墒情站预警
+export const getWeatherWarningList =  (data) =>  warnRequest('forecast.worm_lamp.qxz_warning', data);
+
+
+// 测报灯预警
+export const getPestWarningList =  (data) =>  warnRequest('forecast.worm_lamp.cbd_pest_warning', data);
+
+
+
+// 病害-孢子仪预警
+export const getDeviceWarningList =  (data) =>  warnRequest('device.device_picture.bzy_warning_list', data);

+ 46 - 1
api/worm.js

@@ -1,4 +1,8 @@
 import request from '@/utils/request/index.js'
+import {
+	timeFormat
+} from '@/utils/utils.js'
+
 /**
  * 虫情监测模块
  */
@@ -34,7 +38,48 @@ export const getWormDetails = (params) => wormRequest('worm_list', params);
 export const getPestRaiseInfo = (params) => wormRequest('pest_raise_info', params);
 
 // 虫情分析-折线图
-export const getPestStatisticsChart = (params) => wormRequest('pest_statistics_char_new', params);
+export const getPestStatisticsChart = async (params) => {
+	const {
+		char_data,
+		pest_total,
+		at_ah_info
+	} = await wormRequest('pest_statistics_char_new', params);
+
+	//	at_ah_info组装成 categories: [],series: [{name: "",data: []}] 格式
+	let lineChart = {
+		categories: [],
+		series: [{
+			name: '湿度',
+			data: []
+		}, {
+			name: '温度',
+			data: []
+		}],
+	}
+	for (let i = 0; i < at_ah_info.length; i++) {
+		lineChart.categories.push(timeFormat(at_ah_info[i].addtime, 'mm-dd'))
+		lineChart.series[0].data.push(at_ah_info[i].ah)
+		lineChart.series[1].data.push(at_ah_info[i].at)
+	}
+	// at_ah_info组装 完成
+	//饼状图数据组装
+	let pieChart = {
+		series: [{
+			data: []
+		}]
+	}
+	for (let key in pest_total) {
+		pieChart.series[0].data.push({
+			name: key,
+			value: pest_total[key]
+		})
+	}
+	return {
+		lineChart,
+		pieChart,
+		pestTotal: pest_total,
+	}
+};
 
 // 虫情分析-害虫图片溯源
 export const getPestImageSource = (params) => wormRequest('pest_image_source', params);

+ 2 - 1
components/ui-empty/ui-empty.vue

@@ -30,7 +30,7 @@
 			// 顶部距离
 			top: {
 				type: Number,
-				default: 100
+				default: 10
 			},
 			// 是否显示组件
 			show: {
@@ -50,6 +50,7 @@
 
 	.ui-empty {
 		flex-direction: column;
+		padding-bottom: 100rpx;
 
 		&__text {
 			font-size: 32rpx;

تفاوت فایلی نمایش داده نمی شود زیرا این فایل بسیار بزرگ است
+ 0 - 2005
package-lock.json


+ 18 - 0
pages.json

@@ -124,6 +124,24 @@
             }
             
         }
+        ,{
+            "path" : "pages/weather/warn",
+            "style" :                                                                                    
+            {
+                "navigationBarTitleText": "预警信息",
+                "enablePullDownRefresh": false
+            }
+            
+        }
+        ,{
+            "path" : "pages/worm/warn",
+            "style" :                                                                                    
+            {
+                "navigationBarTitleText": "预警信息",
+                "enablePullDownRefresh": false
+            }
+            
+        }
     ],
 	"globalStyle": {
 		"navigationBarTextStyle": "black",

+ 42 - 7
pages/camera/details.vue

@@ -7,17 +7,17 @@
 		</view>
 		<!-- 监控工具 -->
 		<view class="monitor-tools">
-			<view class="row-center tools-btn">
+			<view class="row-center tools-btn" @click="controlDirection(8)">
 				<text>+</text>
 			</view>
 			<view class="tools-control">
-				<view class="slice up"></view>
-				<view class="slice down"></view>
-				<view class="slice left"></view>
-				<view class="slice right"></view>
+				<view class="slice up" @click="controlDirection(0)"></view>
+				<view class="slice down" @click="controlDirection(1)"></view>
+				<view class="slice left" @click="controlDirection(2)"></view>
+				<view class="slice right" @click="controlDirection(3)"></view>
 				<view class="tools-btn"></view>
 			</view>
-			<view class="row-center tools-btn">
+			<view class="row-center tools-btn" @click="controlDirection(9)">
 				<text>━</text>
 			</view>
 		</view>
@@ -25,11 +25,46 @@
 </template>
 
 <script>
+	import {
+		getCameraAddress,
+		controlCamera
+	} from '@/api/camera.js'
 	export default {
 		data() {
 			return {
-
+				deviceId: '', // 设备号
+				// 播放地址
+				cameraAddress: '',
+				// 控制参数
+				controlParams: {
+					device_id: '', //设备号
+					ctrl: 'move', //move 控制球机转动   stop 停止球机转动, 转动后需调用停止接口,不然会造成球机一直转
+					movenum: 0, //	0-上,1-下,2-左,3-右,8-放大,9-缩小
+				}
 			};
+		},
+		onLoad(options) {
+			this.deviceId = options.id;
+		},
+		methods: {
+			// 获取监控播放地址
+			async getCameraAddress() {
+				device_id
+				getCameraAddress({
+					device_id: this.deviceId
+				})
+			},
+			// 控制摄像机
+			async controlDirection(movenum) {
+				this.controlParams.movenum = movenum;
+				this.controlParams.ctrl = 'move'
+				let res = await controlCamera(this.controlParams);
+				if (!res.data) {
+					return;
+				}
+				this.controlParams.ctrl = 'stop'
+				await controlCamera(this.controlParams);
+			}
 		}
 	}
 </script>

+ 21 - 17
pages/camera/index.vue

@@ -1,19 +1,21 @@
 <template>
 	<!-- 可视监控 -->
 	<view class="camera-panel">
-		<!-- 监控列表 -->
-		<block v-for="(item,index) in cameraList" :key="index">
-			<view class="camera-item" @click="openCameraDetails(item.device_id)">
-				<image class="pic" mode="aspectFill"
-					src="https://bjetxgzv.cdn.bspapp.com/VKCEYUGU-uni-app-doc/6acec660-4f31-11eb-a16f-5b3e54966275.jpg">
-				</image>
-				<view class="row-between p-10">
-					<text class="text">2022-9-2 20:12:57</text>
-					<text class="tips"></text>
+		<view class="camera-list">
+			<!-- 监控列表 -->
+			<block v-for="(item,index) in cameraList" :key="index">
+				<view class="camera-item" @click="openCameraDetails(item.device_id)">
+					<image class="pic" mode="aspectFill"
+						src="https://bjetxgzv.cdn.bspapp.com/VKCEYUGU-uni-app-doc/6acec660-4f31-11eb-a16f-5b3e54966275.jpg">
+					</image>
+					<view class="row-between p-10">
+						<text class="text">2022-9-2 20:12:57</text>
+						<text class="tips"></text>
+					</view>
 				</view>
-			</view>
-		</block>
-		<!-- 监控列表end -->
+			</block>
+			<!-- 监控列表end -->
+		</view>
 		<ui-empty v-if="cameraList.length==0"></ui-empty>
 	</view>
 </template>
@@ -59,9 +61,9 @@
 			 * 打开监控详情
 			 * @param {string} id 设备id
 			 */
-			openCameraDetails(id){
+			openCameraDetails(id) {
 				uni.navigateTo({
-					url:`details?id=${id}`
+					url: `details?id=${id}`
 				})
 			}
 		}
@@ -71,13 +73,15 @@
 <style lang="scss">
 	// 可视监控面板
 	.camera-panel {
-		display: flex;
-		flex-wrap: wrap;
+		
 		padding: 24rpx;
 		margin-top: 24rpx;
 		background-color: #fff;
 	}
-
+	.camera-list{
+		display: flex;
+		flex-wrap: wrap;
+	}
 	// 可视列表项
 	.camera-item {
 		width: 336rpx;

+ 6 - 2
pages/index/index.vue

@@ -12,8 +12,12 @@
 			return {
 				urls:[
 					{
-						url:'/pages/weather/index',
-						text:'环境检测'
+						url:'/pages/weather/index?type=5',
+						text:'气象检测'
+					},
+					{
+						url:'/pages/weather/index?type=8',
+						text:'墒情检测'
 					},
 					{
 						url:'/pages/worm/index',

+ 9 - 4
pages/pest/details.vue

@@ -2,11 +2,12 @@
 	<!-- 病虫害百科详情 -->
 	<view class="page-panel pest-panel">
 		<!-- 图片 -->
-		<image src="@/static/demo/demo1.png" class="pest-cover" mode="widthFix"></image>
+		<image :src="pestInfo.img_urls" class="pest-cover" mode="widthFix"></image>
 		<!-- 百科标题 -->
-		<view class="pest-title">小麦赤霉病</view>
+		<view class="pest-title">{{pestInfo.name}}</view>
+		<view class="pest-paragraph">{{pestInfo.prevention}}</view>
 		<!-- 百科内容 -->
-		<view class="pest-subtitle">别称</view>
+		<!-- <view class="pest-subtitle">别称</view>
 		<view class="pest-paragraph">麦穗枯、烂麦头、红麦头</view>
 		<view class="pest-subtitle">病原体</view>
 		<view class="pest-paragraph">真菌、禾谷镰孢、燕麦镰孢等</view>
@@ -17,7 +18,7 @@
 			Sacc.)、串珠镰孢(Fusarium moniliforme sheld.)、黄色镰孢(Fusarium culmorum (W. G. Smith) Sacc)和税顶镰孢(Fusarium acuminatum
 			(ElL et Ev) Wr)等也能引起小麦赤霉病。</view>
 		<view class="pest-subtitle">综合症状</view>
-		<view class="pest-paragraph">麦生长的各个阶段都能受害,苗期侵染引小麦赤霉病的发生流行主要与小麦生育期、气候条件、菌源等因素引起苗腐,中后期侵染引起秆腐和穗腐,以穗腐危害性最大。</view>
+		<view class="pest-paragraph">麦生长的各个阶段都能受害,苗期侵染引小麦赤霉病的发生流行主要与小麦生育期、气候条件、菌源等因素引起苗腐,中后期侵染引起秆腐和穗腐,以穗腐危害性最大。</view> -->
 
 	</view>
 </template>
@@ -26,7 +27,11 @@
 	export default {
 		data() {
 			return {
+				pestInfo:{},
 			};
+		},
+		onLoad(options) {
+			this.pestInfo=JSON.parse(options.params);
 		}
 	}
 </script>

+ 53 - 12
pages/pest/index.vue

@@ -1,12 +1,12 @@
 <template>
 	<!-- 病虫害百科 -->
 	<view>
-		<ui-search placeholder="请输入害虫名字" @confirm="searchLampList"></ui-search>
-		<ui-tabs :list="tabs" :active="tabValue"></ui-tabs>
+		<ui-search placeholder="请输入害虫名字" @confirm="searchPestList"></ui-search>
+		<ui-tabs :list="tabs" :active="params.code" @clickTab="clickPestTab"></ui-tabs>
 		<!-- 病虫害百科列表 -->
 		<view class="page-panel pest-panel">
 			<block v-for="(item,index) in pestList" :key="index">
-				<view class="pest-item">
+				<view class="pest-item" @click="openPestsInfo(item)">
 					<image class="pic" mode="aspectFill" :src="item.img_urls"></image>
 					<view class="row-center p-10">
 						<text class="text">{{item.name}}</text>
@@ -26,31 +26,72 @@
 			return {
 				// 病虫害百科列表
 				pestList: [],
-				tabValue: 1, // 当前状态
+
 				// 搜索条件列表
 				params: {
-					code: 1,
+					code: 2,
 					page: 1,
-					page_size: 8,
+					page_size: 10,
 					pest_name: ''
 				},
+				total: 0, // 设备总数
+
 				// tabs列表
 				tabs: [{
 					text: '虫害百科',
-					value: 1
-				}, {
-					text: '病虫害百科',
 					value: 2
-				}, ]
+				}, {
+					text: '病害百科',
+					value: 1
+				}]
 			};
 		},
 		onLoad() {
 			this.getPestList();
 		},
+		// 触底请求
+		onReachBottom(e) {
+			if (this.pestList.length >= this.total) {
+				return;
+			}
+			this.params.page += 1;
+			this.getPestList();
+		},
 		methods: {
-			// 获取虫害列表
+
+			clickPestTab(value) {
+				this.params.code = value;
+				this.refreshPestList();
+			},
+			// 刷新虫害百科列表
+			refreshPestList() {
+				this.params.page = 1;
+				this.pestList = [];
+				this.getPestList();
+			},
+			// 获取虫害or病害 列表
 			async getPestList() {
-				let res = await loadPestList(this.params);
+				let {
+					disease_nums,
+					pest_nums,
+					data
+				} = await loadPestList(this.params);
+				this.pestList = [...this.pestList, ...(data ?? [])];
+				this.total = this.params.code == 2 ? pest_nums : disease_nums;
+			},
+			/**
+			 * 搜索病虫害
+			 * @param {String} val 搜索内容
+			 */
+			searchPestList(val) {
+				this.params.pest_name = val;
+				this.refreshPestList();
+			},
+			// 打开病虫害
+			openPestsInfo(item){
+				uni.navigateTo({
+					url:`details?params=${JSON.stringify(item)}`
+				})
 			}
 		}
 	}

+ 3 - 3
pages/weather/details.vue

@@ -5,11 +5,11 @@
 		<view class="ui-card forecast-card">
 			<view class="flex-1">
 				<view class="font-16 title">设备名称:{{deviceInfo.equip_name}}</view>
-				<view class="text">设备ID:{{deviceInfo.equip_name}}</view>
-				<view class="text text-ellipsis">地址:{{deviceInfo.equip_name}}</view>
+				<view class="text">设备ID:{{deviceInfo.equip_id}}</view>
+				<view class="text text-ellipsis">地址:{{deviceInfo.address}}</view>
 				<view class="text">最新上报时间:{{deviceInfo.uptime | timeFrom}}</view>
 			</view>
-			<view class="font-12 state">{{deviceInfo.is_online?'在线':'离线'}}</view>
+			<navigator :url="`warn?type=${deviceInfo.device_type}`" class="font-12 state">预警</navigator>
 		</view>
 		<!-- 设备卡片end -->
 		<view class="row-between m-12">

+ 1 - 1
pages/weather/history.vue

@@ -25,7 +25,7 @@
 				</uni-tr>
 				<uni-tr v-for="(item, index) in historyList" :key="index">
 					<block v-for="(val,key,i) in item" :key="i">
-						<uni-td>{{item[key]}}</uni-td>
+						<uni-td align="center">{{item[key]}}</uni-td>
 					</block>
 				</uni-tr>
 			</uni-table>

+ 6 - 3
pages/weather/index.vue

@@ -40,7 +40,9 @@
 				total: 0, // 设备总数
 			};
 		},
-		onLoad() {
+		onLoad(options) {
+			//获取类型 5气象站 8墒情站
+			this.params.device_type=options.type ?? 5;
 			this.getDeviceList();
 		},
 		// 触底请求
@@ -73,7 +75,8 @@
 					equip_id: device.equip_id, //设备号
 					address: device.address, //组织地址
 					is_online: device.is_online, //在线状态 0离线 1在线
-					uptime: device.uptime //数据更新时间  秒级时间戳
+					uptime: device.uptime ,//数据更新时间  秒级时间戳
+					device_type: this.params.device_type, // 5气象站 8墒情站
 				}
 				uni.navigateTo({
 					url: `details?params=${JSON.stringify(params)}`
@@ -84,7 +87,7 @@
 				const {
 					ids,
 					nums
-				} = await getWeatherDeviceList();
+				} = await getWeatherDeviceList(this.params);
 				this.deviceList = [...this.deviceList, ...ids];
 				this.total = nums ?? 0;
 			},

+ 93 - 0
pages/weather/warn.vue

@@ -0,0 +1,93 @@
+<template>
+	<!-- 气象站、墒情站预警信息 -->
+	<view>
+		<block v-for="(item,index) in warningList" :key="index">
+			<view class="ui-card warn-item">
+				<view class="title">{{item.ekey}}</view>
+				<view class="subtitle">设备ID:{{item.device_id}}</view>
+				<view class="paragraph">{{item.warning_content}}</view>
+				<text class="time">{{item.upltime | timeFrom}}</text>
+			</view>
+		</block>
+		<ui-empty v-if="warningList.length==0" text="暂无预警信息"></ui-empty>
+	</view>
+</template>
+
+<script>
+	import {
+		getWeatherWarningList
+	} from '@/api/warning.js'
+	export default {
+		data() {
+			return {
+				// 预警列表
+				warningList: [],
+				params: {
+					page: 1, //页数 默认为1
+					page_size: 10, //数据条数据 默认为10
+					device_type: 5, //5 气象站 8墒情站
+				},
+				total: 0,
+			}
+		},
+		onLoad(options) {
+			//获取类型 5气象站 8墒情站
+			this.params.device_type = options.type ?? 5;
+			this.getWarningList();
+		},
+		// 触底请求
+		onReachBottom(e) {
+			if (this.warningList.length >= this.total) {
+				return;
+			}
+			this.params.page += 1;
+			this.getWarningList();
+		},
+		methods: {
+			// 获取设备列表
+			async getWarningList() {
+				const {
+					data,
+					nusm
+				} = await getWeatherWarningList(this.params);
+				this.warningList = [...this.warningList, ...data];
+				this.total = nusm ?? 0;
+			},
+		}
+	}
+</script>
+
+<style lang="scss">
+	.warn-item {
+		padding: 26rpx 24rpx;
+
+		.title {
+			font-size: $font-size-title;
+			color: $color-title;
+			line-height: $line-height-title;
+		}
+
+		.subtitle {
+			margin-top: 10rpx;
+			font-size: $font-size-subtitle;
+			color: $color-subtitle;
+			line-height: $line-height-subtitle;
+		}
+
+		.paragraph {
+			margin: 10rpx 0 18rpx;
+			font-size: $font-size-paragraph;
+			color: $color-paragraph;
+			line-height: $line-height-paragraph;
+		}
+
+		.time {
+			padding: 6rpx 15rpx;
+			font-size: 28rpx;
+			color: #317AFD;
+			line-height: 1;
+			background: rgba(49, 122, 253, .3);
+			border-radius: 4rpx;
+		}
+	}
+</style>

+ 159 - 87
pages/worm/analyse.vue

@@ -2,125 +2,136 @@
 	<!-- 虫害分析 -->
 	<view>
 		<!-- 时期卡片 -->
-		<raise-card :deviceId="dId"></raise-card>
+		<raise-card :deviceId="deviceId"></raise-card>
 		<!-- 时期卡片end -->
 		<!-- 虫害统计图 -->
 		<view class="ui-card px-13">
 			<!-- 选择时间范围 -->
 			<view class="mb">
-				<uni-datetime-picker v-model="range" type="daterange" rangeSeparator="至" @maskClick="maskClick" />
+				<uni-datetime-picker v-model="searchTime" type="daterange" rangeSeparator="-"
+					@change="changeSearchTime" />
 			</view>
 			<!-- 区域统计图 -->
-			<area-charts :chartData="areaData"></area-charts>
+			<area-charts :chartData="pestLineData"></area-charts>
 			<view style="height: 20rpx;"></view>
 			<!-- 环形统计图 -->
-			<pie-charts :chartData="pieData"></pie-charts>
+			<pie-charts :chartData="pestPieData"></pie-charts>
 			<!-- 统计列表 -->
 			<view class="mt-12">
-				<view class="progress-item">
-					<view class="label">1、贪夜蛾</view>
+				<view class="progress-item" v-for="(val,key,i) in pestTotal" :key="i">
+					<view class="label">{{i+1}}、{{key}}</view>
 					<view class="progress">
-						<progress :percent="10" backgroundColor="#F3F5F9" activeColor="#10AEFF" :stroke-width="9" />
+						<progress :percent="pestTotal[key]" backgroundColor="#F3F5F9" activeColor="#10AEFF" :stroke-width="9" />
 					</view>
-					<view class="percent">52%</view>
+					<view class="percent">{{val}}</view>
 				</view>
-
 			</view>
 		</view>
-
+		<!-- 虫害统计图end -->
 		<!-- 虫害表格数据 -->
 		<view class="ui-card worm-table">
-			<ui-tabs :list="tabs" :active="1"></ui-tabs>
-			<!-- <uni-table class="table-style mt-12" ref="table" :loading="loading" border emptyText="暂无更多数据">
-				<uni-tr>
-					<uni-th width="150" align="center">日期</uni-th>
-					<uni-th width="150" align="center">姓名</uni-th>
-					<uni-th align="center">地址</uni-th>
-					<uni-th width="204" align="center">设置</uni-th>
-				</uni-tr>
-				<uni-tr v-for="(item, index) in tableData" :key="index">
-					<uni-td>{{ item.date }}</uni-td>
-					<uni-td>{{ item.date }}</uni-td>
-					<uni-td>
-						<view class="name">{{ item.name }}</view>
-					</uni-td>
-					<uni-td align="center">{{ item.address }}</uni-td>
-				</uni-tr>
-			</uni-table> -->
-			<!-- 页码 -->
-			<uni-pagination :total="50" title="标题文字" />
-			<!-- 页码end -->
+			<ui-tabs :list="pestTabs" :active="pestTabValue" @clickTab="clickPestTabs"></ui-tabs>
+			<!-- 害虫图片溯源 -->
+			<view v-show="pestTabValue==1">
+				<uni-table class="table-style mt-12" ref="table" border emptyText="暂无更多数据">
+					<uni-tr>
+						<uni-th width="150" align="center">设备号</uni-th>
+						<uni-th width="150" align="center">设备名称</uni-th>
+						<uni-th width="250" align="center">害虫名称</uni-th>
+						<uni-th width="200" align="center">添加时间</uni-th>
+						<uni-th width="200" align="center">地址</uni-th>
+					</uni-tr>
+					<uni-tr v-for="(item, index) in pestImageSourceTable" :key="index">
+						<uni-td>{{ item.deviceId }}</uni-td>
+						<uni-td>{{ item.deviceName }}</uni-td>
+						<uni-td>
+							<view class="name">{{ item.pestName }}</view>
+						</uni-td>
+						<uni-td align="center">{{ item.addtime | timeFrom }}</uni-td>
+						<uni-td align="center">{{ item.location }}</uni-td>
+					</uni-tr>
+				</uni-table>
+				<!-- 页码 -->
+				<uni-pagination :total="imageSourceTotal" @change="getPestImageSourceList" />
+				<!-- 页码end -->
+			</view>
+			<!-- 害虫基础信息溯源 -->
+			<view v-show="pestTabValue==2">
+				<uni-table class="table-style mt-12" ref="table" border emptyText="暂无更多数据">
+					<uni-tr>
+						<uni-th width="150" align="center">害虫名称</uni-th>
+						<uni-th width="150" align="center">害虫数量</uni-th>
+						<uni-th width="180" align="center">添加时间</uni-th>
+					</uni-tr>
+					<uni-tr v-for="(item, index) in pestBaseTable" :key="index">
+						<uni-td align="center">{{ item.pest_name }}</uni-td>
+						<uni-td align="center">{{ item.pest_num }}</uni-td>
+						<uni-td align="center">{{ item.addtime | timeFrom }}</uni-td>
+					</uni-tr>
+				</uni-table>
+				<!-- 页码 -->
+				<uni-pagination :total="baseTotal" @change="getPestBaseDataList" />
+				<!-- 页码end -->
+			</view>
 		</view>
+		<view style="height: 100rpx;"></view>
+		
+		<!-- 返回顶部按钮 -->
+		<ui-back-top :scroll-top="scrollTop" />
 	</view>
 </template>
 
 <script>
 	import {
 		getPestStatisticsChart,
-		getPestRaiseInfo,
 		getPestImageSource,
 		getPestBaseData
 	} from '@/api/worm.js'
+	import {
+		timeFrame,
+		dateToUnix
+	} from '@/utils/utils.js'
 	import areaCharts from './components/w-area-charts.vue'
 	import pieCharts from './components/w-pie-charts.vue'
 	import raiseCard from './components/analyse/raise-card.vue' // 始见期卡片组件
 	export default {
 		data() {
 			return {
-				dId: '', // 设备id
-				pieData: {
-					series: [{
-						data: [{
-							"name": "一班",
-							"value": 50
-						}, {
-							"name": "二班",
-							"value": 30
-						}, {
-							"name": "三班",
-							"value": 20
-						}]
-					}]
-				},
-				areaData: {
-					categories: ["2016", "2017", "2018", "2019", "2020", "2021"],
-					series: [{
-							name: "成交量A",
-							data: [35, 8, 25, 37, 4, 20]
-						},
-						{
-							name: "成交量B",
-							data: [70, 40, 65, 100, 44, 68]
-						}
-					]
+				deviceId: '', // 设备id
+				// 检索时间 折线图,虫害图片溯源,虫害基础数据通用
+				timeParams: {
+					start_time: timeFrame('start'), // 开始时间
+					end_time: timeFrame('end'), // 结束时间
 				},
-				// 日期列表
-				periodList: [{
-						url: '',
-						title: '始见期',
-						time: '2022-08-22',
-						num: 536
-					},
-					{
-						url: '',
-						title: '高峰期',
-						time: '2022-08-22',
-						num: 132
-					}, {
-						url: '',
-						title: '终见期',
-						time: '2022-08-22',
-						num: 0
-					}
-				],
-				range: ['2021-02-1', '2021-3-28'],
-				tabs: [{
+				// === 虫害统计信息参数
+				searchTime: ['', ''],
+				chartLoading: false,
+				// 饼状图数据
+				pestPieData: null,
+				// 折线图数据
+				pestLineData: null,
+				pestTotal: null, // 虫害统计信息
+				// === 虫害统计信息参数 end
+				
+				// === 虫害表格数据
+				pestTabs: [{
 					text: '图像溯源',
 					value: 1
 				}, {
 					text: '虫害基础数据',
 					value: 2
-				}, ]
+				}],
+				pestTabValue: 1, // 当前虫害选项
+				
+				pestImageSourceTable: [], // 害虫图片溯源表格数据,
+				imageSourcePage: 1, // 害虫图片溯源页码
+				imageSourceTotal: 0, // 害虫图片溯源总数
+				
+				pestBaseTable: [], // 害虫基础表格数据
+				basePage: 1, // 害虫基础页码
+				baseTotal: 0, // 害虫基础总数
+				// === 虫害表格数据 end
+				scrollTop: 0,
 			};
 		},
 		components: {
@@ -129,11 +140,75 @@
 			raiseCard
 		},
 		onLoad(options) {
-			this.dId = '15'; //options.id
+			this.deviceId = '15'; //options.id
+			this.getPestStatisticsChart();
+			this.getPestImageSourceList();
+			this.getPestBaseDataList();
+		},
+		onPageScroll(e) {
+			this.scrollTop = e.scrollTop;
 		},
 		methods: {
-			maskClick(e) {
-				console.log('----maskClick事件:', e);
+			// 获取折线图统计信息
+			async getPestStatisticsChart() {
+				this.chartLoading = false;
+
+				const {
+					lineChart,
+					pieChart,
+					pestTotal,
+				} = await getPestStatisticsChart({
+					d_ids: this.deviceId,
+					amend: 0,
+					...this.timeParams
+				});
+				this.pestPieData = pieChart; // 饼状图
+				this.pestLineData = lineChart; // 折线图数据
+				this.pestTotal = pestTotal; // 虫害统计信息
+				this.chartLoading = true;
+			},
+			// 折线图时间切换
+			changeSearchTime(time) {
+				this.timeParams.start_time = time[0] ? dateToUnix(time[0]) : timeFrame('start');
+				this.timeParams.end_time = time[0] ? dateToUnix(time[1]) : timeFrame('end');
+				this.searchTime = time;
+				this.getPestStatisticsChart();
+				this.getPestImageSourceList();
+				this.getPestBaseDataList();
+			},
+			
+			clickPestTabs(value){
+				this.pestTabValue=value;
+			},
+			/**
+			 * 获取虫害图片溯源列表
+			 * @param {Object}  e  获取当前页数 e.current 
+			 */
+			async getPestImageSourceList(e) {
+				this.imageSourcePage = e?.current ?? 1;
+				const res = await getPestImageSource({
+					d_ids: this.deviceId,
+					page: this.imageSourcePage,
+					...this.timeParams
+				});
+				this.pestImageSourceTable = res.pest_image_data;
+				this.imageSourceTotal = res.total_count;
+				this.imageSourcePage = res.current_count
+			},
+			/**
+			 * 获取虫害基础数据列表
+			 * @param {Object}  e  获取当前页数 e.current 
+			 */
+			async getPestBaseDataList(e) {
+				this.basePage = e?.current ?? 1;
+				const res = await getPestBaseData({
+					d_ids: this.deviceId,
+					page: this.basePage,
+					...this.timeParams
+				});
+				this.pestBaseTable = res.pest_image_data;
+				this.baseTotal = res.total_count;
+				this.basePage = res.current_count
 			}
 		}
 	}
@@ -178,11 +253,11 @@
 
 	}
 
-
 	.progress-item {
 		display: flex;
 		align-items: center;
 		justify-content: space-between;
+		margin-top: 12rpx;
 
 		.label,
 		.percent {
@@ -191,7 +266,7 @@
 		}
 
 		.label {
-			width: 160rpx;
+			width: 200rpx;
 		}
 
 		.percent {
@@ -204,15 +279,12 @@
 			height: 18rpx;
 			overflow: hidden;
 			border-radius: 30rpx;
-
-
 		}
 	}
 
 	// 虫害表格数据
 	.worm-table {
 		padding: 10rpx 24rpx 30rpx;
-		margin-bottom: 100rpx;
 		border-radius: 0;
 	}
 </style>

+ 96 - 0
pages/worm/components/analyse/worm-table.vue

@@ -0,0 +1,96 @@
+<template>
+	<!-- 害虫分析表格数据-->
+	<view class="ui-card px-13">
+		
+	</view>
+</template>
+
+<script>
+	/**
+	 * 虫害始见期数据卡片
+	 */
+	import {
+		getPestRaiseInfo
+	} from '@/api/worm.js'
+	export default {
+		name: 'w-raise-card',
+		data() {
+			return {
+				pestList: [], //始见期选项
+				pestInfo: {},
+				pestDate: (new Date()).getUTCFullYear(),
+				pestItem: '',
+			}
+		},
+		props: {
+			// 设备id
+			deviceId: [String, Number]
+		},
+
+		mounted() {
+			this.getPestRaiseInfo();
+		},
+		methods: {
+			// 获取始见期数据
+			async getPestRaiseInfo() {
+				const res = await getPestRaiseInfo({
+					year: this.pestDate,
+					d_ids: this.deviceId,
+				});
+				this.pestList = res.pest_list; //始见期选项
+				this.pestInfo = res.pest_info;
+				this.pestItem = this.pestList[0];
+			},
+			
+			// 选择年份
+			changePestDate(e) {
+				this.pestDate=e.detail.value;
+				this.getPestRaiseInfo();
+			},
+			// 选择始见期类型
+			changePestList(e) {
+				this.pestItem = this.pestList[e.detail.value];
+			},
+		}
+	};
+</script>
+
+<style lang="scss">
+	// 时期样式
+	.period-navs {
+		display: flex;
+		justify-content: space-between;
+	}
+	
+	.period-item {
+		width: 200rpx;
+		height: 264rpx;
+		padding: 122rpx 24rpx 24rpx;
+		background: url('/static/img/startTime.png') center center no-repeat;
+		background-size: 200rpx 264rpx;
+	
+		&.high-time {
+			background-image: url('/static/img/highTime.png');
+		}
+	
+		&.end-time {
+			background-image: url('/static/img/endTime.png');
+		}
+	
+		.title {
+			font-size: 32rpx;
+			font-weight: normal;
+			color: #333333;
+			line-height: 44rpx;
+		}
+	
+		.text {
+			margin-top: 10rpx;
+			font-size: 24rpx;
+			font-weight: normal;
+			color: #999999;
+			line-height: 34rpx;
+		}
+	}
+	
+</style>

+ 13 - 11
pages/worm/components/w-area-charts.vue

@@ -1,7 +1,8 @@
 <template>
 	<!-- 虫情数据 区域统计图 -->
 	<view>
-		<ui-charts ref="wLineCharts" type="area" :ontouch="true" :opts="opts" :chartData="chartData"></ui-charts>
+		<ui-charts ref="wLineCharts" :loadingType="0" type="area" :ontouch="true" :opts="opts" :chartData="chartData">
+		</ui-charts>
 	</view>
 </template>
 
@@ -18,22 +19,23 @@
 
 				opts: {
 					loadingType: 0,
-					color: ["#317afd","#45EAB7"],
-					padding: [10, 0, 0, 5],
+					color: ["#317afd", "#45EAB7"],
+					padding: [20, 10, 10, 10],
+					enableScroll: true,
 					legend: {
 						position: 'top',
-						float: 'left'
+						float: 'center'
 					},
 					dataLabel: false,
-					// dataPointShape: false,
-					dataPointShapeType: 'hollow',
+					dataPointShape: false,
+					// dataPointShapeType: 'hollow',
 					xAxis: {
 						disableGrid: true,
-						          boundaryGap: "justify",
+						boundaryGap: "justify",
 						fontColor: '#999',
 						fontSize: 10,
-						axisLineColor: '#F4F7F9'
-
+						axisLineColor: '#F4F7F9',
+						itemCount: 6
 					},
 					yAxis: {
 						gridColor: '#F4F7F9',
@@ -49,7 +51,7 @@
 						area: {
 							type: "curve",
 							width: 3,
-							gradient:true
+							gradient: true
 						},
 						tooltip: {
 							showArrow: true,
@@ -88,7 +90,7 @@
 			chartData: {
 				deep: true, // 深度监听
 				handler(val) {
-				  this.wLineCharts.updataUChart()
+
 				}
 			}
 		},

+ 2 - 3
pages/worm/components/w-pie-charts.vue

@@ -1,7 +1,7 @@
 <template>
 	<!-- 虫害饼状图-->
 	<view>
-		<ui-charts ref="ringChart" type="ring" :opts="opts" :chartData="chartData"></ui-charts>
+		<ui-charts ref="ringChart"  :loadingType="0"  type="ring" :opts="opts" :chartData="chartData"></ui-charts>
 	</view>
 </template>
 
@@ -19,7 +19,7 @@
 					rotate: false,
 					rotateLock: false,
 					color: ["#43B693", "#317AFD", "#8543E0"],
-					padding: [5, 5, 5, 5],
+					padding: [10, 10, 10, 10],
 					dataLabel: true,
 					legend: {
 						show: false,
@@ -74,7 +74,6 @@
 			chartData: {
 				deep: true, // 深度监听
 				handler(val) {
-					this.ringChart.updataUChart();
 					this.initData();
 				}
 			}

+ 13 - 10
pages/worm/details.vue

@@ -4,12 +4,13 @@
 		<!-- 设备卡片 -->
 		<view class="ui-card forecast-card">
 			<view class="flex-1">
-				<view class="font-16 title">设备名称:{{lampDetails.device_name}}</view>
-				<view class="text">设备ID:{{deviceId}}</view>
+				<view class="font-16 title">虫情监测</view>
+				<view class="text">设备ID:{{deviceImei}}</view>
+				<view class="text">设备名称:测报灯</view>
 				<view class="text text-ellipsis">地址:{{lampDetails.address}}</view>
-				<view class="text">最新上报时间:{{lampDetails.device_name}}</view>
+				<view class="text">最新上报时间:{{uptime | timeFrom}}</view>
 			</view>
-			<view class="font-12 state">预警</view>
+			<navigator :url="`warn`" class="font-12 state">预警</navigator>
 		</view>
 		<!-- 设备卡片end -->
 		<!-- 导航选项 -->
@@ -22,7 +23,7 @@
 				<image src="@/static/img/worm-nav-1.png" class="icon" mode="aspectFill"></image>
 				<view class=" text">害虫分析</view>
 			</navigator>
-			<navigator :url="`history?id=${deviceId}`" class="worm-nav-item" hover-class="none">
+			<navigator :url="`history?imeiId=${deviceImei}`" class="worm-nav-item" hover-class="none">
 				<image src="@/static/img/worm-nav-3.png" class="icon" mode="aspectFill"></image>
 				<view class="text">历史数据</view>
 			</navigator>
@@ -71,15 +72,15 @@
 			<view class="ui-card latest-item">
 				<view class="icon"></view>
 				<view class="column-between text-info font-12">
-					<view class="text">环境温度</view>
-					<view class="text"></view>
+					<view class="text">环境温度(°C)</view>
+					<view class="text">{{lampDetails.at}}</view>
 				</view>
 			</view>
 			<view class="ui-card latest-item">
 				<view class="icon"></view>
 				<view class="column-between text-info font-12">
-					<view class="text">环境湿度</view>
-					<view class="text"></view>
+					<view class="text">环境湿度(%)</view>
+					<view class="text">{{lampDetails.ah}}</view>
 				</view>
 			</view>
 			<view class="ui-card latest-item">
@@ -165,13 +166,15 @@
 			return {
 				deviceId: '', // 设备id
 				deviceImei:'',// 设备号
+				uptime:0,//上报时间
 				lampDetails:{},//设备详情
 				latestList:[],//实时列表
 			};
 		},
 		onLoad(options) {
-			this.deviceId = options.id; // 设备id
+			this.deviceId = options.id; // 设备id;
 			this.deviceImei = options.imei;// 设备号
+			this.uptime=options.uptime;
 		},
 		methods: {
 			// 获取测报灯详情

+ 94 - 76
pages/worm/history.vue

@@ -6,9 +6,12 @@
 			<!-- 按钮组合 -->
 			<view class="time-btn-group">
 				<block v-for="(time,index) in timeList" :key="index">
-					<view class="row-center time-btn">{{time.text}}</view>
+					<view class="row-center time-btn" :class="params.start_time==time.value?'active':''"
+						@click="selectTime(time.value)"> {{time.text}}</view>
 				</block>
 			</view>
+			<!-- 区域折线图 -->
+			<area-charts :chartData="historyChartData"></area-charts>
 		</view>
 		<!-- 统计图end -->
 		<!-- 历史数据列表 -->
@@ -17,98 +20,130 @@
 				<view class="">数据列表</view>
 			</view>
 			<!-- 历史数据表格 -->
-			<uni-table class="table-style" ref="table" :loading="loading" border emptyText="暂无更多数据">
+			<uni-table class="table-style" :loading="loading" border emptyText="暂无更多数据">
 				<uni-tr>
 					<uni-th width="150" align="center">日期</uni-th>
-					<uni-th width="150" align="center">姓名</uni-th>
-					<uni-th align="center">地址</uni-th>
-					<uni-th width="204" align="center">设置</uni-th>
+					<uni-th width="150" align="center">环境温度(°C)</uni-th>
+					<uni-th align="center">环境湿度(%)</uni-th>
+					<uni-th width="204" align="center">加热仓温度(°C)</uni-th>
 				</uni-tr>
-				<uni-tr v-for="(item, index) in tableData" :key="index">
-					<uni-td>{{ item.date }}</uni-td>
-					<uni-td>{{ item.date }}</uni-td>
+				<uni-tr v-for="(item, index) in historyList" :key="index">
+					<uni-td>{{ item.addtime | timeFrom}}</uni-td>
+					<uni-td>{{ item.at }}</uni-td>
 					<uni-td>
-						<view class="name">{{ item.name }}</view>
+						<view class="name">{{ item.ah }}</view>
 					</uni-td>
-					<uni-td align="center">{{ item.address }}</uni-td>
+					<uni-td align="center">{{ item.hrt }}</uni-td>
 				</uni-tr>
 			</uni-table>
 			<!-- 页码 -->
-			<uni-pagination :total="50" title="标题文字" />
+			<uni-pagination :total="total" @change="getHistoryList" />
 			<!-- 页码end -->
 		</view>
 		<!-- 历史数据列表end -->
-
 	</view>
 </template>
 
 <script>
 	import {
-		getWormLampList
+		getWormLampHistory
 	} from '@/api/worm.js'
 	import areaCharts from './components/w-area-charts.vue'
+	import moment from 'moment';
+	// 获取开始还见
+	const startTime = (num, str) => {
+		let time = moment().subtract(num, str);
+		return moment(time).unix();
+	}
 	export default {
 		data() {
 			return {
-				areaData: {
-					categories: ["2016", "2017", "2018", "2019", "2020", "2021"],
-					series: [{
-							name: "成交量A",
-							data: [35, 8, 25, 37, 4, 20]
-						},
-						{
-							name: "成交量B",
-							data: [70, 40, 65, 100, 44, 68]
-						},
-						{
-							name: "成交量C",
-							data: [100, 80, 95, 150, 112, 132]
-						}
-					]
-				},
 				// 时间列表
 				timeList: [{
 						text: '24小时',
-						value: 1,
+						value: startTime(1, 'days'),
 					},
 					{
 						text: '近一个月',
-						value: 2,
+						value: startTime(1, 'months'),
 					}, {
 						text: '近半年',
-						value: 3,
+						value: startTime(6, 'months'),
 					}, {
 						text: '近一年',
-						value: 4,
+						value: startTime(1, 'years'),
 					}
 				],
-				range: ['2021-02-1', '2021-3-28'],
 				loading: false, // 表格加载状态
-				tableData: [{
-					"date": "2020-09-01",
-					"name": "Dcloud1",
-					"address": "上海市普陀区金沙江路 1518 弄"
-				}, {
-					"date": "2020-09-02",
-					"name": "Dcloud2",
-					"address": "上海市普陀区金沙江路 1517 弄"
-				}, {
-					"date": "2020-09-03",
-					"name": "Dcloud3",
-					"address": "上海市普陀区金沙江路 1519 弄"
-				}, {
-					"date": "2020-09-04",
-					"name": "Dcloud4",
-					"address": "上海市普陀区金沙江路 1516 弄"
-				}],
+				params: {
+					device_type_id: 3, // 设备类型id 3测报灯 6孢子仪
+					device_id: '', // 设备号
+					start_time: 0, //开始时间
+					end_time: moment().unix(), // 结束时间
+					page: 1,
+				},
+				// 历史数据列表
+				historyList: [],
+				total: 0,
+				// 历史数据折线图
+				historyChartData: {
+					categories: [],
+					//{name: "",data: []}
+					series: []
+				}
 			};
 		},
+		onLoad(options) {
+			this.params.device_id = options.imeiId;
+			this.params.start_time = this.timeList[0].value;
+			this.getHistoryList();
+		},
 		components: {
 			areaCharts
 		},
 		methods: {
-			maskClick(e) {
-				console.log('----maskClick事件:', e);
+			// 选择时间范围
+			selectTime(value) {
+				this.params.start_time = value;
+				this.getHistoryList();
+			},
+			/**
+			 * 获取历史数据列表
+			 * @param {Object}  e  获取当前页数 e.current 
+			 */
+			async getHistoryList(e) {
+				this.params.page = e?.current ?? 1;
+				const {
+					data,
+					counts
+				} = await getWormLampHistory(this.params);
+				const historyList = data.map(item => item.d_h_t);
+				this.historyList = historyList;
+				this.total = counts;
+				let categories = [];
+				let series = [];
+				let seriesKey = {
+					at: '环境温度(°C)',
+					ah: '环境湿度(%)',
+					hrt: '加热仓温度(°C)'
+				}
+				for (let key in seriesKey) {
+					series.push({
+						name: seriesKey[key],
+						data: [],
+						key,
+					});
+				}
+				this.historyList.forEach((item) => {
+					categories.push(moment(item.addtime*1000).format('MM-月DD日'));
+					series.forEach(serieItem=>{
+						serieItem.data.push(item[serieItem.key]);
+					})
+				})
+				this.historyChartData = {
+					categories,
+					series: series
+				}
 			}
 		}
 	}
@@ -123,6 +158,7 @@
 		display: flex;
 		justify-content: center;
 		margin-bottom: 24rpx;
+
 		.time-btn {
 			width: 125rpx;
 			height: 55rpx;
@@ -130,6 +166,11 @@
 			color: #999;
 			border-radius: 8rpx;
 			border: 1rpx solid #DDDDDD;
+
+			&.active {
+				border-color: #317afd;
+				color: #317afd;
+			}
 		}
 	}
 
@@ -137,27 +178,4 @@
 		padding: 24rpx 26rpx;
 		margin-bottom: 56rpx;
 	}
-
-	.table-style {
-		margin-bottom: 42rpx;
-
-		.uni-table-th,
-		.uni-table-td {
-			color: #333333;
-			font-weight: normal;
-			font-size: 24rpx;
-			color: #333333;
-			line-height: 34rpx;
-			text-align: center;
-		}
-
-		.uni-table-th {
-			background-color: #F9F9F9;
-			padding: 10rpx 20rpx;
-		}
-
-		.uni-table-td {
-			padding: 12rpx 20rpx;
-		}
-	}
 </style>

+ 5 - 4
pages/worm/index.vue

@@ -6,9 +6,9 @@
 		<!-- 搜索框end -->
 		<!-- 监测列表 -->
 		<block v-for="(item,index) in lampList" :key="index">
-			<view class="ui-card forecast-item" @click="openLampDetails(item.d_id,item.imei)">
+			<view class="ui-card forecast-item" @click="openLampDetails(item)">
 				<view class="flex-1 info">
-					<view class="font-16  title" :class="item.is_online?'on':'off'">{{item.device_name}}</view>
+					<view class="font-16  title" :class="item.is_online?'on':'off'">{{item.device_name?item.device_name:'测报灯'}}</view>
 					<view class="text">设备ID:{{item.imei}}</view>
 					<view class="text">最新上报时间:{{ item.uptime | timeFrom}}</view>
 				</view>
@@ -84,10 +84,11 @@
 			 * 打开虫情详情列表
 			 * @param {String} id  设备id
 			 * @param {String} imei 设备号
+			 * @param {Number} uptime 上报时间
 			 */
-			openLampDetails(id,imei) {
+			openLampDetails({id,imei,uptime}) {
 				uni.navigateTo({
-					url: `details?id=${id}&imei=${imei}`
+					url: `details?id=${id}&imei=${imei}&uptime=${uptime}`
 				})
 			}
 		},

+ 95 - 0
pages/worm/warn.vue

@@ -0,0 +1,95 @@
+<template>
+	<!-- 测报灯预警信息 -->
+	<view>
+		<block v-for="(item,index) in warningList" :key="index">
+			<view class="ui-card warn-item">
+				<view class="title">{{item.ekey}}</view>
+				<view class="subtitle">设备ID:{{item.device_id}}</view>
+				<view class="paragraph">
+					<text  v-for="(val,key,i) in item.warning_content" :key="i">
+						{{key+':'+val}},
+					</text>
+				</view>
+				<text class="time">{{item.upltime | timeFrom}}</text>
+			</view>
+		</block>
+		<ui-empty v-if="warningList.length==0" text="暂无预警信息"></ui-empty>
+	</view>
+</template>
+
+<script>
+	import {
+		getPestWarningList
+	} from '@/api/warning.js'
+	export default {
+		data() {
+			return {
+			
+				// 预警列表
+				warningList: [],
+				params: {
+					page: 1, //页数 默认为1
+					page_size: 10, //数据条数据 默认为10
+				},
+				total: 0,
+			}
+		},
+		onLoad(options) {
+			this.getWarningList();
+		},
+		// 触底请求
+		onReachBottom(e) {
+			if (this.warningList.length >= this.total) {
+				return;
+			}
+			this.params.page += 1;
+			this.getWarningList();
+		},
+		methods: {
+			// 获取设备列表
+			async getWarningList() {
+				const {
+					data,
+					nusm
+				} = await getPestWarningList(this.params);
+				this.warningList = [...this.warningList, ...data];
+				this.total = nusm ?? 0;
+			},
+		}
+	}
+</script>
+
+<style lang="scss">
+	.warn-item {
+		padding: 26rpx 24rpx;
+
+		.title {
+			font-size: $font-size-title;
+			color: $color-title;
+			line-height: $line-height-title;
+		}
+
+		.subtitle {
+			margin-top: 10rpx;
+			font-size: $font-size-subtitle;
+			color: $color-subtitle;
+			line-height: $line-height-subtitle;
+		}
+
+		.paragraph {
+			margin: 10rpx 0 18rpx;
+			font-size: $font-size-paragraph;
+			color: $color-paragraph;
+			line-height: $line-height-paragraph;
+		}
+
+		.time {
+			padding: 6rpx 15rpx;
+			font-size: 28rpx;
+			color: #317AFD;
+			line-height: 1;
+			background: rgba(49, 122, 253, .3);
+			border-radius: 4rpx;
+		}
+	}
+</style>

+ 3 - 3
uni_modules/uni-table/components/uni-table/uni-table.vue

@@ -361,8 +361,8 @@ $border-color: #ebeef5;
 	/* #ifndef APP-NVUE */
 	display: table-row;
 	/* #endif */
-	height: 50px;
-	line-height: 50px;
+	height: 100px;
+	line-height: 100px;
 	overflow: hidden;
 	box-sizing: border-box;
 }
@@ -371,9 +371,9 @@ $border-color: #ebeef5;
 }
 .uni-table-text {
 	position: absolute;
-	top:25rpx;
 	right: 0;
 	left: 0;
+	top: 50px;
 	text-align: center;
 	font-size: 14px;
 	color: #999;