From fe3ce21a469f7e2584dbcb85cb75022d149f436c Mon Sep 17 00:00:00 2001 From: zuoxiao <zuoxiao> Date: 星期二, 25 三月 2025 19:28:56 +0800 Subject: [PATCH] 更新灌溉计划页面,添加项目选择器和总灌溉时间计算功能;优化界面样式,增加SVG图标;修复项目列表和轮灌组显示逻辑;调整配置文件,添加libVersion字段。 --- pages/createIrrigation/createIrrigation.wxss | 157 +++++++++++++++++++++++++++++++++++++++++++++++----- 1 files changed, 142 insertions(+), 15 deletions(-) diff --git a/pages/createIrrigation/createIrrigation.wxss b/pages/createIrrigation/createIrrigation.wxss index 93c27a6..3872378 100644 --- a/pages/createIrrigation/createIrrigation.wxss +++ b/pages/createIrrigation/createIrrigation.wxss @@ -14,7 +14,7 @@ flex-direction: row; align-items: center; background-color: #fff; - padding: 30rpx; + padding: 15rpx 30rpx; margin-bottom: 2rpx; width: 100%; box-sizing: border-box; @@ -58,6 +58,12 @@ padding-right: 20rpx; } +.picker-text { + flex: 1; + text-align: right; + padding-right: 20rpx; +} + .placeholder { color: #999; } @@ -80,11 +86,28 @@ height: calc(100vh - 300rpx); /* 璁剧疆鍥哄畾楂樺害锛屽噺鍘婚《閮ㄨ〃鍗曞拰搴曢儴鎸夐挳鐨勯珮搴� */ } +/* 鍒楄〃澶撮儴鏍峰紡 */ +.list-header { + padding: 30rpx; + border-bottom: 1rpx solid #eee; + background-color: #fff; +} + +.list-title-container { + display: flex; + justify-content: space-between; + align-items: center; +} + .list-title { - font-size: 28rpx; + font-size: 32rpx; color: #333; - margin-bottom: 30rpx; font-weight: 500; +} + +.list-subtitle { + font-size: 24rpx; + color: #999; } /* 椤圭洰鍒楄〃鏍峰紡 */ @@ -145,15 +168,11 @@ /* 杞亴缁勫垪琛ㄦ牱寮� */ .group-list { - display: none; + display: flex; flex-direction: column; background-color: #fff; - max-height: none; /* 绉婚櫎鏈�澶ч珮搴﹂檺鍒� */ - height: auto; /* 鑷�傚簲楂樺害 */ -} - -.group-list.expanded { - display: flex; + height: 100%; /* 鎭㈠涓�100%楂樺害锛屽洜涓轰笉鍐嶉渶瑕佷负搴曢儴缁熻鐣欑┖闂� */ + overflow-y: auto; } .group-item { @@ -162,6 +181,25 @@ align-items: center; padding: 25rpx 30rpx; border-top: 1rpx solid #eee; + position: relative; + transition: all 0.3s ease; +} + +.group-item::after { + content: ''; + position: absolute; + right: 30rpx; /* 淇敼涓轰笌宸︿晶padding涓�鑷� */ + top: 50%; + transform: translateY(-50%); + width: 16rpx; + height: 16rpx; + border-top: 2rpx solid #999; + border-right: 2rpx solid #999; + transform: translateY(-50%) rotate(45deg); +} + +.group-item:active { + background-color: #e6f7ff; } .group-item.selected { @@ -172,16 +210,44 @@ flex: 1; display: flex; align-items: center; + flex-wrap: wrap; } .group-name { font-size: 26rpx; color: #666; + position: relative; + padding-left: 10rpx; + background-color: rgba(24, 144, 255, 0.1); + padding: 4rpx 20rpx; + border-radius: 10rpx; } + +.group-hint { + font-size: 22rpx; + color: #1890FF; + margin-left: 10rpx; + background-color: rgba(24, 144, 255, 0.1); + padding: 4rpx 10rpx; + border-radius: 10rpx; +} + +/* .group-name::before { + content: ''; + position: absolute; + left: 0; + top: 50%; + transform: translateY(-50%); + width: 6rpx; + height: 6rpx; + background-color: #1890FF; + border-radius: 50%; +} */ .group-duration { display: flex; align-items: center; + margin-right: 40rpx; /* 澧炲姞鍙宠竟璺濓紝涓虹澶寸暀鍑虹┖闂� */ } .duration-input { @@ -218,20 +284,81 @@ padding: 20rpx 30rpx; background-color: #fff; box-shadow: 0 -2rpx 10rpx rgba(0, 0, 0, 0.05); - z-index: 100; /* 鎻愰珮z-index纭繚鎸夐挳鍦ㄦ渶涓婂眰 */ + z-index: 100; } .confirm-button { width: 100%; - height: 88rpx; - line-height: 88rpx; + height: 80rpx; + line-height: 80rpx; text-align: center; background-color: #1890FF; color: #fff; - font-size: 30rpx; - border-radius: 44rpx; + font-size: 28rpx; + border-radius: 8rpx; } .confirm-button-hover { opacity: 0.8; +} + +/* TDesign Picker 鏍峰紡瑕嗙洊 */ +.t-picker { + z-index: 1000; +} + +.t-picker__header { + background-color: #fff; + border-bottom: 1rpx solid #eee; +} + +.t-picker__title { + font-size: 32rpx; + color: #333; + font-weight: 500; +} + +.t-picker__cancel, +.t-picker__confirm { + font-size: 28rpx; + padding: 20rpx 30rpx; +} + +.t-picker__cancel { + color: #999; +} + +.t-picker__confirm { + color: #1890FF; +} + +.t-picker__content { + background-color: #fff; +} + +.t-picker__item { + font-size: 32rpx; + color: #333; +} + +.t-picker__item--active { + color: #1890FF; +} + +/* 鎬荤亴婧夋椂闂寸粺璁℃牱寮� */ +.total-duration { + display: flex; + align-items: center; +} + +.total-duration-label { + font-size: 28rpx; + color: #666; + margin-right: 10rpx; +} + +.total-duration-value { + font-size: 32rpx; + color: #1890FF; + font-weight: 500; } \ No newline at end of file -- Gitblit v1.8.0