TraceabilityAPP/components/index/planting.vue

195 lines
3.6 KiB
Vue
Raw Normal View History

2023-10-20 18:45:15 +08:00
<template>
<view class="">
<view class="content">
<view class="border-bgc">
</view>
<view class="" style="height: 30rpx;">
</view>
<view class="card">
<view class="card-li">
农户名称: 魏鹏飞
</view>
<view class="card-li">
种养殖类型: 种植户
</view>
<view class="card-li">
土地面积: 00
</view>
<view class="card-li">
地址: 对话方式打开就会发生的空间和
</view>
</view>
2023-10-23 09:00:12 +08:00
<view class="card" v-for="(item,index) in list" :key="index" @click="navgoFn(item.type)">
2023-10-20 18:45:15 +08:00
<view class="tit card-li">
<view class="">
土地1
</view>
2023-10-23 09:00:12 +08:00
<view class="" style="color: #00A15E;" v-if="item.type==1||item.type==2">
2023-10-20 18:45:15 +08:00
已种植
</view>
2023-10-23 09:00:12 +08:00
<view class="" style="color: #00A15E;" v-if="item.type==0">
未种植
</view>
2023-10-20 18:45:15 +08:00
</view>
<view class="card-li">
<view class="">
面积: 10
</view>
</view>
<view class="card-li tit">
<view class="" style="font-weight: normal;">
农作物: 10
</view>
2023-10-23 09:00:12 +08:00
<view class="" style="color: #FF9B66;" v-if="item.type==2">
2023-10-20 18:45:15 +08:00
已成熟
</view>
</view>
<view class="card-li tit" style="font-weight: normal;">
<view class="">
预计产量: 100kg
</view>
<view class="">
已出售: 500kg
</view>
</view>
</view>
<view style="height: 170rpx;">
</view>
</view>
<view class="bottom">
2023-10-23 09:00:12 +08:00
<view class="add-btn" @click="navgo('/pages/growRecord/index')">
2023-10-20 18:45:15 +08:00
批量处理
</view>
<view class="add-btn add">
增加种植
</view>
</view>
</view>
</template>
<script setup>
import {
reactive
} from "vue"
const list = reactive([{
2023-10-23 09:00:12 +08:00
tit: "土地种植管理",
type: 1,
2023-10-20 18:45:15 +08:00
}, {
2023-10-23 09:00:12 +08:00
tit: "土地种植管理",
type: 0,
2023-10-20 18:45:15 +08:00
}, {
2023-10-23 09:00:12 +08:00
tit: "土地种植管理",
type: 2,
2023-10-20 18:45:15 +08:00
}, {
2023-10-23 09:00:12 +08:00
tit: "土地种植管理",
type: 1,
2023-10-20 18:45:15 +08:00
}, {
2023-10-23 09:00:12 +08:00
tit: "土地种植管理",
type: 0,
2023-10-20 18:45:15 +08:00
}, {
2023-10-23 09:00:12 +08:00
tit: "土地种植管理",
type: 2,
2023-10-20 18:45:15 +08:00
}, {
tit: "土地种植管理"
}, {
tit: "土地种植管理"
}, {
tit: "土地种植管理"
}, {
tit: "土地种植管理"
}, ])
2023-10-23 09:00:12 +08:00
const navgo = (url) => {
uni.navigateTo({
url
})
}
const navgoFn = (type) => {
if (type == 0) {
navgo("/pages/InformationAdd/index")
}
if (type == 1) {
navgo("/pages/detail/plant")
}
if (type == 2) {
navgo('/pages/detail/plant')
}
}
2023-10-20 18:45:15 +08:00
</script>
<style lang="scss">
.content {
min-height: 90vh;
position: relative;
// padding: 0 20rpx;
// padding-top: 50rpx;
background-color: #EAF2EF;
2023-10-23 09:00:12 +08:00
padding: 0;
2023-10-20 18:45:15 +08:00
.border-bgc {
height: 200rpx;
background-color: #34D190;
2023-10-23 09:00:12 +08:00
border-radius: 0 0 40rpx 40rpx;
2023-10-20 18:45:15 +08:00
position: absolute;
width: 750rpx;
}
.card {
position: relative;
width: 693.93rpx;
margin: auto;
background-color: #fff;
box-sizing: border-box;
padding: 20rpx;
border-radius: 21.03rpx 21.03rpx 21.03rpx 21.03rpx;
margin-bottom: 40rpx;
.card-li {
margin-bottom: 17rpx;
}
.tit {
display: flex;
font-size: 33.29rpx;
font-weight: bold;
// background-color: red;
justify-content: space-between;
}
}
}
.bottom {
width: 750rpx;
height: 150rpx;
background-color: #EAF2EF;
position: fixed;
bottom: 0;
display: flex;
align-items: center;
justify-content: center;
.add-btn {
width: 238.32rpx;
height: 84.11rpx;
border: #34D190 1px solid;
border-radius: 42.06rpx 42.06rpx 42.06rpx 42.06rpx;
display: flex;
align-items: center;
color: #00A15E;
font-size: 33.29rpx;
font-weight: bold;
justify-content: center;
margin-right: 20rpx;
}
.add {
background-color: #00A15E;
color: white;
}
}
</style>