|
@ -1,11 +1,31 @@ |
|
|
<template> |
|
|
<template> |
|
|
<div> |
|
|
<div> |
|
|
<div class="head"> |
|
|
<van-tabs @click="onClick"> |
|
|
<div class="arrow" @click="goback"><van-icon name="arrow-left" /></div> |
|
|
<van-tab title="历史信息"> |
|
|
<div class="head-title">产量上报</div> |
|
|
<div class="header font-size17 font-pingfangB text-center flex flex-center2 "> |
|
|
</div> |
|
|
<van-search v-model="searchKey" shape="round" background="#ffffff" placeholder="请输入搜索关键词" class="flex1" /> |
|
|
<div style="height: 54px"></div> |
|
|
</div> |
|
|
<div class="list"> |
|
|
<div class="container"> |
|
|
|
|
|
<div class="card flex flex-y"> |
|
|
|
|
|
<div class="flex flex-x m-bot12 flex-center2" > |
|
|
|
|
|
<img src="../assets/images//icons//date-blue.png" class="img-15"> |
|
|
|
|
|
<div class="font-size14 blue m-left5 ">2024-01</div> |
|
|
|
|
|
|
|
|
|
|
|
</div> |
|
|
|
|
|
<div class="border-btn" v-for="item in hisList"> |
|
|
|
|
|
<div class="font-pingfangB m-top12">{{ item.vegetable }}</div> |
|
|
|
|
|
<div class="gray">种植时间:{{ item.PlantingTime }}</div> |
|
|
|
|
|
<div class="gray">上市时间:{{ item.launchTime }}</div> |
|
|
|
|
|
<div class="gray m-bot12">产量(吨):{{ item.yield }}</div></div> |
|
|
|
|
|
</div> |
|
|
|
|
|
</div> |
|
|
|
|
|
</van-tab> |
|
|
|
|
|
<van-tab title="信息填报"> |
|
|
|
|
|
<div class="flex flex-y"> |
|
|
|
|
|
<div class="header font-size17 font-pingfangB text-center flex flex-center2 "> |
|
|
|
|
|
<div class="m-left25">青岛德龙种业有限公司</div> |
|
|
|
|
|
</div> |
|
|
|
|
|
<div class="list"> |
|
|
<div |
|
|
<div |
|
|
class="list-item" |
|
|
class="list-item" |
|
|
v-for="(item, i) in vegetableList" |
|
|
v-for="(item, i) in vegetableList" |
|
@ -61,9 +81,13 @@ |
|
|
/> |
|
|
/> |
|
|
</van-cell-group> |
|
|
</van-cell-group> |
|
|
</div> |
|
|
</div> |
|
|
<button @click="addRow" class="login-btn1"> |
|
|
<div class="flex flex-x " @click="addRow"> |
|
|
|
|
|
<img class="img-20" src="../assets/images/icons/add.png" > |
|
|
|
|
|
<div >添加品种</div> |
|
|
|
|
|
</div> |
|
|
|
|
|
<!-- <button @click="addRow" class="login-btn1"> |
|
|
<van-icon name="plus" /> 添加 |
|
|
<van-icon name="plus" /> 添加 |
|
|
</button> |
|
|
</button> --> |
|
|
</div> |
|
|
</div> |
|
|
<div v-show="typeShow" class="picker-box"> |
|
|
<div v-show="typeShow" class="picker-box"> |
|
|
<van-picker |
|
|
<van-picker |
|
@ -94,9 +118,16 @@ |
|
|
:value="new Date(vegetableList[index].marketTime)" |
|
|
:value="new Date(vegetableList[index].marketTime)" |
|
|
/> |
|
|
/> |
|
|
</div> |
|
|
</div> |
|
|
<div class="bottom"> |
|
|
<div class="flex flex-x flex-center1 flex-center2"> |
|
|
<button @click="onSubmit" class="login-btn">上报</button> |
|
|
<button @click="onSubmit" class="login-btn">上报</button></div> |
|
|
|
|
|
|
|
|
</div> |
|
|
</div> |
|
|
|
|
|
|
|
|
|
|
|
</van-tab> |
|
|
|
|
|
|
|
|
|
|
|
</van-tabs> |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
</div> |
|
|
</div> |
|
|
</template> |
|
|
</template> |
|
|
|
|
|
|
|
@ -105,6 +136,7 @@ import Toast from "vant/es/toast"; |
|
|
import Dialog from "vant/es/dialog"; |
|
|
import Dialog from "vant/es/dialog"; |
|
|
import axios from "axios"; |
|
|
import axios from "axios"; |
|
|
import config from "@/config/index"; |
|
|
import config from "@/config/index"; |
|
|
|
|
|
import { Image } from "vant"; |
|
|
const baseUrl = |
|
|
const baseUrl = |
|
|
process.env.NODE_ENV === "development" ? "" : config.baseUrl.pro; |
|
|
process.env.NODE_ENV === "development" ? "" : config.baseUrl.pro; |
|
|
export default { |
|
|
export default { |
|
@ -129,6 +161,8 @@ export default { |
|
|
placeOrgName: null, |
|
|
placeOrgName: null, |
|
|
columns: ["白菜", "土豆", "温州", "嘉兴", "湖州"], |
|
|
columns: ["白菜", "土豆", "温州", "嘉兴", "湖州"], |
|
|
list: [], |
|
|
list: [], |
|
|
|
|
|
hisList:[{time:"2024-02",vegetable:"西红柿",PlantingTime:"2024-20",launchTime:"2024-05-26",yield:"200"}, |
|
|
|
|
|
{time:"2024-02",vegetable:"西红柿",PlantingTime:"2024-20",launchTime:"2024-05-26",yield:"200"}] |
|
|
}; |
|
|
}; |
|
|
}, |
|
|
}, |
|
|
mounted() { |
|
|
mounted() { |
|
@ -164,7 +198,7 @@ export default { |
|
|
method: "post", |
|
|
method: "post", |
|
|
url: `${baseUrl}/api/sys/dict/data/yifengScreen/dictlist`, |
|
|
url: `${baseUrl}/api/sys/dict/data/yifengScreen/dictlist`, |
|
|
data: { |
|
|
data: { |
|
|
dictType: "vegetable", |
|
|
dictType: "", |
|
|
}, |
|
|
}, |
|
|
}) |
|
|
}) |
|
|
.then((response) => { |
|
|
.then((response) => { |
|
@ -183,7 +217,7 @@ export default { |
|
|
}); |
|
|
}); |
|
|
}, |
|
|
}, |
|
|
methods: { |
|
|
methods: { |
|
|
onInput(val) {}, |
|
|
onInput(val) { }, |
|
|
onConfirm(val) { |
|
|
onConfirm(val) { |
|
|
this.vegetableList[this.index].vegetableCategory = val; |
|
|
this.vegetableList[this.index].vegetableCategory = val; |
|
|
this.typeShow = false; |
|
|
this.typeShow = false; |
|
@ -366,9 +400,14 @@ export default { |
|
|
</script> |
|
|
</script> |
|
|
|
|
|
|
|
|
<style scoped> |
|
|
<style scoped> |
|
|
|
|
|
.header { |
|
|
|
|
|
height: 50px; |
|
|
|
|
|
background-color: #fff; |
|
|
|
|
|
|
|
|
|
|
|
} |
|
|
.list { |
|
|
.list { |
|
|
padding: 12px; |
|
|
padding: 12px; |
|
|
height: calc(100vh - 170px); |
|
|
height: calc(100vh - 150px); |
|
|
overflow-y: scroll; |
|
|
overflow-y: scroll; |
|
|
} |
|
|
} |
|
|
.list-item { |
|
|
.list-item { |
|
@ -401,26 +440,29 @@ export default { |
|
|
} |
|
|
} |
|
|
.picker-box { |
|
|
.picker-box { |
|
|
width: 100%; |
|
|
width: 100%; |
|
|
position: absolute; |
|
|
position: fixed; |
|
|
bottom: 0px; |
|
|
bottom: 0px; |
|
|
z-index: 100; |
|
|
z-index: 100; |
|
|
} |
|
|
} |
|
|
.login-btn { |
|
|
.login-btn { |
|
|
|
|
|
position: fixed; |
|
|
padding: 10px; |
|
|
padding: 10px; |
|
|
width: 100%; |
|
|
width: 290px; |
|
|
height: 42px; |
|
|
height: 42px; |
|
|
background: #0089f0; |
|
|
background: #0089f0; |
|
|
border-radius: 21px; |
|
|
border-radius: 21px; |
|
|
font-size: 16px; |
|
|
font-size: 16px; |
|
|
|
|
|
bottom: 5px; |
|
|
font-weight: 900; |
|
|
font-weight: 900; |
|
|
background-color: #007bff; |
|
|
background-color: #007bff; |
|
|
color: white; |
|
|
color: white; |
|
|
border: none; |
|
|
border: none; |
|
|
cursor: pointer; |
|
|
cursor: pointer; |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
} |
|
|
} |
|
|
.login-btn1 { |
|
|
.login-btn1 { |
|
|
padding: 10px; |
|
|
padding: 10px; |
|
|
width: calc(100% - 24px); |
|
|
|
|
|
margin-left: 12px; |
|
|
margin-left: 12px; |
|
|
margin-bottom: 24px; |
|
|
margin-bottom: 24px; |
|
|
height: 42px; |
|
|
height: 42px; |
|
@ -432,6 +474,7 @@ export default { |
|
|
color: white; |
|
|
color: white; |
|
|
border: none; |
|
|
border: none; |
|
|
cursor: pointer; |
|
|
cursor: pointer; |
|
|
|
|
|
|
|
|
} |
|
|
} |
|
|
.bottom { |
|
|
.bottom { |
|
|
width: calc(100% - 48px); |
|
|
width: calc(100% - 48px); |
|
|