From 8720abb0b62a591d295abfd3c4523a4b91fb3bc1 Mon Sep 17 00:00:00 2001
From: zmj <1493694146@qq.com>
Date: Wed, 25 Oct 2023 19:55:18 +0800
Subject: [PATCH] =?UTF-8?q?=E6=8E=A5=E5=8F=A3?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
App.vue | 7 +-
api/animal.js | 18 +
api/chick.js | 18 +
api/file.js | 6 +
api/plant.js | 22 +
api/test.js | 6 -
components/InformationAdd/plant.vue | 105 +-
components/imgCard.vue | 18 +-
components/index/chick.vue | 190 +-
components/index/cultivation.vue | 169 +-
components/index/fishing.vue | 6 +-
components/index/planting.vue | 53 +-
components/myTable/index.vue | 32 +-
components/plant/landInfo.vue | 89 +
components/supervision/index.vue | 223 +
pages.json | 106 +
pages/allPlant/index.vue | 72 +-
pages/aquatic/detail.vue | 1 -
pages/aquatic/updateGrow.vue | 4 -
pages/detail/plant.vue | 410 +-
pages/feedIng/addPoultry.vue | 198 +-
pages/feedIng/feedDetail.vue | 18 +-
pages/feedIng/feedList.vue | 52 +-
pages/feedIng/histroyFeed.vue | 79 +-
pages/index/index.vue | 75 +-
pages/poultry/addPoultry.vue | 327 +
pages/poultry/allFeed.vue | 79 +
pages/poultry/allRecording.vue | 78 +
pages/poultry/feedDetail.vue | 305 +
pages/poultry/feedList.vue | 180 +
pages/poultry/histroyFeed.vue | 134 +
pages/poultry/histroyNote.vue | 11 +
pages/poultry/updateFeed.vue | 250 +
pages/poultry/vaccineInfo.vue | 219 +
pages/profile/index.vue | 4 -
pages/records/index.vue | 8 +
pages/supervision/captain.vue | 194 +
pages/supervision/detail.vue | 227 +
pages/supervision/farmerDeatil.vue | 210 +
pages/supervision/group.vue | 159 +
pages/test/index.vue | 7 +-
store/counter.js | 15 -
store/userInfo.js | 15 +
.../dist/dev/app-plus/app-config-service.js | 2 +-
unpackage/dist/dev/app-plus/app-service.js | 15681 +++++++++-------
unpackage/dist/dev/app-plus/app.css | 4 +
.../dist/dev/app-plus/pages/index/index.css | 143 +-
utils/syhttp.js | 4 +-
utils/uplodeImg.js | 43 +
49 files changed, 13173 insertions(+), 7103 deletions(-)
create mode 100644 api/animal.js
create mode 100644 api/chick.js
create mode 100644 api/file.js
create mode 100644 api/plant.js
delete mode 100644 api/test.js
create mode 100644 components/plant/landInfo.vue
create mode 100644 components/supervision/index.vue
create mode 100644 pages/poultry/addPoultry.vue
create mode 100644 pages/poultry/allFeed.vue
create mode 100644 pages/poultry/allRecording.vue
create mode 100644 pages/poultry/feedDetail.vue
create mode 100644 pages/poultry/feedList.vue
create mode 100644 pages/poultry/histroyFeed.vue
create mode 100644 pages/poultry/histroyNote.vue
create mode 100644 pages/poultry/updateFeed.vue
create mode 100644 pages/poultry/vaccineInfo.vue
create mode 100644 pages/supervision/captain.vue
create mode 100644 pages/supervision/detail.vue
create mode 100644 pages/supervision/farmerDeatil.vue
create mode 100644 pages/supervision/group.vue
delete mode 100644 store/counter.js
create mode 100644 store/userInfo.js
create mode 100644 utils/uplodeImg.js
diff --git a/App.vue b/App.vue
index 502747f..0d16aa3 100644
--- a/App.vue
+++ b/App.vue
@@ -1,8 +1,13 @@
\ No newline at end of file
diff --git a/components/imgCard.vue b/components/imgCard.vue
index 6d9802b..99bc1cb 100644
--- a/components/imgCard.vue
+++ b/components/imgCard.vue
@@ -1,17 +1,28 @@
+
-
+
- 更新时间: 2023-11-16
+ {{props.text}}
-
\ No newline at end of file
diff --git a/components/supervision/index.vue b/components/supervision/index.vue
new file mode 100644
index 0000000..83c3a8a
--- /dev/null
+++ b/components/supervision/index.vue
@@ -0,0 +1,223 @@
+
+
+
+
+ 监管详情
+
+
+
+ 查看全部监管记录
+
+
+
+
+
+
+ 1号土地
+
+
+ 溯源码: 123148
+
+
+
+
+ 当前种植: 土豆
+
+
+ 标志品种: 土豆大煞风景
+
+
+
+
+ 监管状况:
+
+
+
+
+
+
+ {{item}}
+
+
+
+
+
+
+
+
+
+
+ 监管图片
+
+
+
+
+
+ 点击上传图片
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/pages.json b/pages.json
index 70fdd71..2a93ac6 100644
--- a/pages.json
+++ b/pages.json
@@ -129,7 +129,80 @@
"navigationBarBackgroundColor": "#F4F4F4",
"navigationBarTextStyle": "black"
}
+ },
+
+
+
+ {
+ "path": "pages/poultry/feedList",
+ "style": {
+ "navigationBarTitleText": "养殖列表",
+ "enablePullDownRefresh": false,
+ "navigationBarBackgroundColor": "#F4F4F4",
+ "navigationBarTextStyle": "black"
+ }
+ },
+ {
+ "path": "pages/poultry/feedDetail",
+ "style": {
+ "navigationBarTitleText": "养殖详情",
+ "enablePullDownRefresh": false,
+ "navigationBarBackgroundColor": "#F4F4F4",
+ "navigationBarTextStyle": "black"
+ }
+ },
+ {
+ "path": "pages/poultry/histroyFeed",
+ "style": {
+ "navigationBarTitleText": "历史养殖记录",
+ "enablePullDownRefresh": false,
+ "navigationBarBackgroundColor": "#F4F4F4",
+ "navigationBarTextStyle": "black"
+ }
+ },
+ {
+ "path": "pages/poultry/updateFeed",
+ "style": {
+ "navigationBarTitleText": "更新饲养状态",
+ "enablePullDownRefresh": false,
+ "navigationBarBackgroundColor": "#F4F4F4",
+ "navigationBarTextStyle": "black"
+ }
+ },
+ {
+ "path": "pages/poultry/vaccineInfo",
+ "style": {
+ "navigationBarTitleText": "疫苗信息",
+ "enablePullDownRefresh": false,
+ "navigationBarBackgroundColor": "#F4F4F4",
+ "navigationBarTextStyle": "black"
+ }
}, {
+ "path": "pages/poultry/addPoultry",
+ "style": {
+ "navigationBarTitleText": "添加饲养动物",
+ "enablePullDownRefresh": false,
+ "navigationBarBackgroundColor": "#F4F4F4",
+ "navigationBarTextStyle": "black"
+ }
+ }, {
+ "path": "pages/poultry/allFeed",
+ "style": {
+ "navigationBarTitleText": "全部养殖记录",
+ "enablePullDownRefresh": false,
+ "navigationBarBackgroundColor": "#F4F4F4",
+ "navigationBarTextStyle": "black"
+ }
+ }, {
+ "path": "pages/poultry/allRecording",
+ "style": {
+ "navigationBarTitleText": "全部记录",
+ "enablePullDownRefresh": false,
+ "navigationBarBackgroundColor": "#F4F4F4",
+ "navigationBarTextStyle": "black"
+ }
+ },
+ {
"path": "pages/aquatic/addAquatic",
"style": {
"navigationBarTitleText": "添加养殖",
@@ -153,9 +226,42 @@
"navigationBarBackgroundColor": "#F4F4F4",
"navigationBarTextStyle": "black"
}
+ }, {
+ "path": "pages/supervision/group",
+ "style": {
+ "navigationBarTitleText": "小组公司监管",
+ "enablePullDownRefresh": false,
+ "navigationBarBackgroundColor": "#F4F4F4",
+ "navigationBarTextStyle": "black"
+ }
+ }, {
+ "path": "pages/supervision/captain",
+ "style": {
+ "navigationBarTitleText": "生产队长监管",
+ "enablePullDownRefresh": false,
+ "navigationBarBackgroundColor": "#F4F4F4",
+ "navigationBarTextStyle": "black"
+ }
+ }, {
+ "path": "pages/supervision/farmerDeatil",
+ "style": {
+ "navigationBarTitleText": "农户详情",
+ "enablePullDownRefresh": false,
+ "navigationBarBackgroundColor": "#F4F4F4",
+ "navigationBarTextStyle": "black"
+ }
+ }, {
+ "path": "pages/supervision/detail",
+ "style": {
+ "navigationBarTitleText": "土地详情",
+ "enablePullDownRefresh": false,
+ "navigationBarBackgroundColor": "#F4F4F4",
+ "navigationBarTextStyle": "black"
+ }
},
+
{
"path": "pages/test/index",
"style": {
diff --git a/pages/allPlant/index.vue b/pages/allPlant/index.vue
index 5e745e1..b25aef0 100644
--- a/pages/allPlant/index.vue
+++ b/pages/allPlant/index.vue
@@ -50,56 +50,23 @@
今日种植状态
-
-
-
-
-
-
- 更新时间: 2023-11-16
-
-
-
+
+
播种图片
-
-
-
-
-
-
- 更新时间: 2023-11-16
-
-
-
+
+
生长情况
-
-
-
-
-
-
- 更新时间: 2023-11-16
-
-
-
-
-
-
-
-
-
- 更新时间: 2023-11-16
-
-
-
+
@@ -108,7 +75,30 @@
-
\ No newline at end of file
diff --git a/pages/feedIng/addPoultry.vue b/pages/feedIng/addPoultry.vue
index 3a508bf..d328997 100644
--- a/pages/feedIng/addPoultry.vue
+++ b/pages/feedIng/addPoultry.vue
@@ -1,34 +1,8 @@
-
-
-
-
- 编号: 13254
-
-
- 健康
-
-
-
-
-
- 养殖品种: 黑山🐖
-
-
- 养殖类型: 黑山🐖
-
-
- 年龄: 黑山🐖
-
-
- 体重: 黑山🐖
-
-
-
-
-
-
+
+
+ 已添加{{addList.length}}条畜生
@@ -37,7 +11,15 @@
养殖品种
-
+
+
+
+
+
+ 具体品类
+
+
+
@@ -45,13 +27,13 @@
年龄
-
+
- 养殖类型:
+ 养殖类型:
@@ -70,17 +52,17 @@
- 状态:
+ 状态:
+ @click="changSelectfn1(index)" :style="{color:indexs1==index?'black':'#B3B3B3'}">
{{item}}
-
+
@@ -92,23 +74,29 @@
体重
-
+
-
-
- 点击上传图片
+
+
+
+
+
+ 上传
+
+
+
-
+
下一个
-
+
完成添加
@@ -119,80 +107,101 @@
reactive,
ref
} from "vue"
+ import uplodeImg from "@/utils/uplodeImg.js"
+ import {
+ addAnimalAPI,
+
+ } from "@/api/chick.js"
+ const navgo = () => {
+ uni.navigateTo({
+ url: "/pages/index/index"
+ })
+ }
+ const updateImgFn = () => {
+ uplodeImg().then(res => {
+ formData.pic = res.data.image
+ })
+
+ }
const off = () => {
selectAct.value = false
selectAct1.value = false
}
const selectList = reactive([
- "幼崽", "公猪", "母猪"
+ "公猪", "母猪"
])
+ const gender = ref("")
+ const status = ref("")
const selectList1 = reactive([
"健康", "怀孕中", "生病隔离中", "可出栏"
])
const value = ref("")
+ const value1 = ref("")
const selectAct = ref(false)
const selectAct1 = ref(false)
const selectFoucsFn = (e) => {
selectAct.value = true
+ selectAct1.value = false
}
const selectFoucsFn1 = (e) => {
selectAct1.value = true
+ selectAct.value = false
}
const indexs = ref(0)
+ const indexs1 = ref(0)
const changSelectfn = (index) => {
indexs.value = index
value.value = selectList[index]
+ formData.gender = index + 1
+ gender.value = selectList[index]
+ selectAct.value = false
+ selectAct1.value = false
}
- const updateImgFn = () => {
- uni.chooseImage({
- count: 1,
- sizeType: ['compressed'],
- sourceType: ['album'],
- success: (res) => {
- console.log('chooseImage success, temp path is', res.tempFilePaths[0])
- var imageSrc = res.tempFilePaths[0]
- uni.showLoading({
- title: '上传中'
- })
- this.task = uni.uploadFile({
- url: 'https://unidemo.dcloud.net.cn/upload', //仅为示例,非真实的接口地址
- filePath: imageSrc,
- name: 'file',
- formData: {
- 'user': 'test'
- },
- success: (res) => {
- if (this.pageVisible) {
- console.log('uploadImage success, res is:', res)
- uni.hideLoading();
- uni.showToast({
- title: '上传成功',
- icon: 'success',
- duration: 1000
- })
- this.imageSrc = imageSrc
- }
- },
- fail: (err) => {
- if (this.pageVisible) {
- console.log('uploadImage fail', err);
- uni.hideLoading();
- uni.showModal({
- content: err.errMsg,
- showCancel: false
- });
- }
- },
- });
- },
- fail: (err) => {
- console.log('chooseImage fail', err)
- }
+ const changSelectfn1 = (index) => {
+ indexs1.value = index
+ value1.value = selectList[index]
+ formData.status = index + 1
+ status.value = selectList1[index]
+ selectAct.value = false
+ selectAct1.value = false
+ }
+ const baseFormData = reactive({
+ user_id: 307,
+ kind: "",
+ breed: "",
+ gender: 1,
+ age: "",
+ status: 1,
+ weight: "",
+ pic: ""
+ })
+ const objFn = (res, obj) => {
+ for (let key in res) {
+ obj[key] = res[key]
+ }
+ }
+ const formData = reactive({})
+ objFn(baseFormData, formData)
+
+ const nextFn = () => {
+ addAnimalAPI({
+ ...formData
+ }).then(res => {
+ status.value = ''
+ gender.value = ''
+ addList.push(1)
+ objFn(baseFormData, formData)
+ uni.showToast({
+ title: '添加成功',
+ icon: 'success',
+ duration: 1000,
+ })
})
}
-
+ const addList = reactive([])
+
\ No newline at end of file
diff --git a/pages/feedIng/feedDetail.vue b/pages/feedIng/feedDetail.vue
index 2e634c4..d550fd1 100644
--- a/pages/feedIng/feedDetail.vue
+++ b/pages/feedIng/feedDetail.vue
@@ -52,7 +52,7 @@
编号: 13645
-
+
查看养殖详情
@@ -118,10 +118,16 @@
\ No newline at end of file
diff --git a/pages/poultry/allFeed.vue b/pages/poultry/allFeed.vue
new file mode 100644
index 0000000..f4fab5b
--- /dev/null
+++ b/pages/poultry/allFeed.vue
@@ -0,0 +1,79 @@
+
+
+
+
+
+ 编号: 52656
+
+
+ 溯源码: 52656
+
+
+
+
+ 养殖品种: 土豆
+
+
+ 年龄: 的划分等级
+
+
+
+
+ 养殖类型: 20亩
+
+
+ 体重: 45kg
+
+
+
+
+
+
+
+
+ 当前养殖状态
+
+
+ 健康
+
+
+
+
+
+
+ 饲养记录
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/pages/poultry/allRecording.vue b/pages/poultry/allRecording.vue
new file mode 100644
index 0000000..30d1cef
--- /dev/null
+++ b/pages/poultry/allRecording.vue
@@ -0,0 +1,78 @@
+
+
+
+
+
+ 农户名称: 1号土地
+
+
+
+
+ 种养殖类型: 土豆
+
+
+ 养殖头数: 的划分等级
+
+
+
+
+ 土地面积: 20亩
+
+
+ 公猪: 的划分等级
+
+
+
+
+ 养殖种类: 20亩
+
+
+ 母猪: 的划分等级
+
+
+
+
+ 具体种类: 20亩
+
+
+ 幼崽: 的划分等级
+
+
+
+
+
+ 饲养记录
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/pages/poultry/feedDetail.vue b/pages/poultry/feedDetail.vue
new file mode 100644
index 0000000..2e0fb0a
--- /dev/null
+++ b/pages/poultry/feedDetail.vue
@@ -0,0 +1,305 @@
+
+
+
+
+
+
+ 农户名称: 1号土地
+
+
+
+
+ 种养殖类型: 土豆
+
+
+ 养殖头数: 的划分等级
+
+
+
+
+ 土地面积: 20亩
+
+
+ 公猪: 的划分等级
+
+
+
+
+ 养殖种类: 20亩
+
+
+ 母猪: 的划分等级
+
+
+
+
+ 具体种类: 20亩
+
+
+ 幼崽: 的划分等级
+
+
+
+
+
+
+
+ 搜索
+
+
+
+
+ 编号: 13645
+
+
+ 查看养殖详情
+
+
+
+
+
+
+
+ 养殖类型: 母猪
+
+
+ 体重:
+
+
+
+
+ 年龄: 2年
+
+
+ 状态:
+
+
+
+
+
+
+ {{item}}
+
+
+
+
+
+
+
+
+
+
+ 上传新的种植情况
+
+
+
+
+
+ 饲养记录
+
+
+ 更新生长记录
+
+
+
+
+ 标记状态为出栏
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/pages/poultry/feedList.vue b/pages/poultry/feedList.vue
new file mode 100644
index 0000000..3b3b3aa
--- /dev/null
+++ b/pages/poultry/feedList.vue
@@ -0,0 +1,180 @@
+
+
+
+
+
+ 农户名称: 1号土地
+
+
+
+
+ 种养殖类型: 土豆
+
+
+ 养殖头数: 的划分等级
+
+
+
+
+ 土地面积: 20亩
+
+
+ 公猪: 的划分等级
+
+
+
+
+ 养殖种类: 20亩
+
+
+ 母猪: 的划分等级
+
+
+
+
+ 具体种类: 20亩
+
+
+ 幼崽: 的划分等级
+
+
+
+
+
+
+
+ 搜索
+
+
+
+
+
+ 编号: {{item.code}}
+
+
+ 健康
+
+
+ 怀孕中
+
+
+ 可出栏
+
+
+ 生病隔离中
+
+
+
+
+ 养殖类型: {{item.kind}}
+
+
+ 年龄: {{item.age}}年
+
+
+ 体重: {{item.weight}}kg
+
+
+
+
+
+ 添加新动物
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/pages/poultry/histroyFeed.vue b/pages/poultry/histroyFeed.vue
new file mode 100644
index 0000000..f9e2618
--- /dev/null
+++ b/pages/poultry/histroyFeed.vue
@@ -0,0 +1,134 @@
+
+
+
+
+
+ 编号: 52656
+
+
+ 溯源码: 52656
+
+
+
+
+ 养殖品种: 土豆
+
+
+ 年龄: 的划分等级
+
+
+
+
+ 养殖类型: 20亩
+
+
+ 体重: 45kg
+
+
+
+
+
+
+
+
+ 当前养殖状态
+
+
+ 健康
+
+
+
+
+
+
+
+ 今日养殖状态
+
+
+
+ 养殖情况
+
+
+
+
+
+ 上传新的种植情况
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/pages/poultry/histroyNote.vue b/pages/poultry/histroyNote.vue
new file mode 100644
index 0000000..407b787
--- /dev/null
+++ b/pages/poultry/histroyNote.vue
@@ -0,0 +1,11 @@
+
+
+ dsfsd
+
+
+
+
+
+
\ No newline at end of file
diff --git a/pages/poultry/updateFeed.vue b/pages/poultry/updateFeed.vue
new file mode 100644
index 0000000..62b827e
--- /dev/null
+++ b/pages/poultry/updateFeed.vue
@@ -0,0 +1,250 @@
+
+
+
+
+
+
+ 农户名称: 1号土地
+
+
+
+
+ 种养殖类型: 土豆
+
+
+ 养殖头数: 的划分等级
+
+
+
+
+ 土地面积: 20亩
+
+
+ 公猪: 的划分等级
+
+
+
+
+ 养殖种类: 20亩
+
+
+ 母猪: 的划分等级
+
+
+
+
+ 具体种类: 20亩
+
+
+ 幼崽: 的划分等级
+
+
+
+
+
+ 今日操作
+
+
+
+
+ 喂食
+
+
+ +添加喂食记录
+
+
+
+
+
+
+ 注射疫苗
+
+
+ +添加喂食记录
+
+
+
+
+
+ 具体操作内容
+
+
+
+
+ 喂食
+
+
+
+ 删除
+
+
+ 编辑
+
+
+
+
+
+
+
+ 饲料类型: 无机盐饲料
+
+
+ 饲料品牌: 双胞胎
+
+
+
+
+ 喂食记录: 200kg
+
+
+ 备注: 双胞胎
+
+
+
+
+
+
+ 疫苗注射对象
+
+
+
+ 删除
+
+
+ 编辑
+
+
+
+
+
+
+
+ 疫苗名称: 无机盐饲料
+
+
+ 疫苗品牌: 双胞胎
+
+
+
+
+ 操作人员: 200kg
+
+
+ 注射数量: 双胞胎
+
+
+
+ 疫苗条形码
+
+
+
+
+
+
+ 完成今日统计
+
+
+
+
+
+
+ 添加喂食记录
+
+
+ 饲料类型
+
+
+
+
+
+ 饲料品牌
+
+
+
+
+
+
+ 确认
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/pages/poultry/vaccineInfo.vue b/pages/poultry/vaccineInfo.vue
new file mode 100644
index 0000000..8bd1937
--- /dev/null
+++ b/pages/poultry/vaccineInfo.vue
@@ -0,0 +1,219 @@
+
+
+
+ 疫苗相关信息
+
+
+
+
+ 疫苗名称
+
+
+
+
+
+
+
+ 疫苗品牌
+
+
+
+
+
+
+
+ 操作人员
+
+
+
+
+
+
+
+
+ 疫苗条形码
+
+
+
+
+
+ 点击上传图片
+
+
+
+
+
+
+ 注射对象
+
+
+ 扫描动物耳标/脚标
+
+
+
+
+
+
+
+
+
+
+ 编号: 123456
+
+
+ 健康
+
+
+ 怀孕中
+
+
+ 可出栏
+
+
+
+
+
+ 养殖品种:黑山猪
+
+
+ 年龄: 5年
+
+
+ 体重: 150kg
+
+
+
+
+
+
+
+
+
+ 确认
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/pages/profile/index.vue b/pages/profile/index.vue
index abbfca8..7f325ce 100644
--- a/pages/profile/index.vue
+++ b/pages/profile/index.vue
@@ -45,10 +45,6 @@
+
+
\ No newline at end of file
diff --git a/pages/supervision/detail.vue b/pages/supervision/detail.vue
new file mode 100644
index 0000000..84d435d
--- /dev/null
+++ b/pages/supervision/detail.vue
@@ -0,0 +1,227 @@
+
+
+
+
+
+
+ 农户名称: 1号土地
+
+
+
+
+ 种养殖类型: 土豆
+
+
+ 土地面积: 的划分等级
+
+
+
+
+ 联系方式: 20亩
+
+
+ 1号土地: 的划分等级
+
+
+
+
+ 2号土地: 20亩
+
+
+ 3号土地: 计划G几乎是官方
+
+
+
+
+ 地址: 四川省巴中市恩阳区三
+
+
+
+
+
+
+
+
+
+
+
+ 农户上传操作记录
+
+
+
+
+
+ 确定
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/pages/supervision/farmerDeatil.vue b/pages/supervision/farmerDeatil.vue
new file mode 100644
index 0000000..5895b42
--- /dev/null
+++ b/pages/supervision/farmerDeatil.vue
@@ -0,0 +1,210 @@
+
+
+
+
+
+
+
+
+
+
+ 农户名称: {{userInfo.name}}
+
+
+ 种养殖类型: 种植户
+
+
+ 土地面积: {{userInfo.total_land_area}}亩
+
+
+ 地址: {{userInfo.area_name}}{{userInfo.street_name}}{{userInfo.village_name}}{{userInfo.brigade_name}}
+
+
+
+
+
+
+ {{item.land_notes}}
+
+
+ 已种植
+
+
+ 未种植
+
+
+
+
+ 面积: {{item.land_area}}亩
+
+
+
+
+ 农作物: {{item.crop_name}}
+
+
+ 已成熟
+
+
+
+
+ 预计产量: {{item.crop_yield}}kg
+
+
+ 已出售: 500kg
+
+
+
+
+
+
+
+
+
+ 批量处理
+
+
+ 增加种植
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/pages/supervision/group.vue b/pages/supervision/group.vue
new file mode 100644
index 0000000..b5a2414
--- /dev/null
+++ b/pages/supervision/group.vue
@@ -0,0 +1,159 @@
+
+
+
+
+
+
+ 1号小组
+
+
+ 通滩指导养殖合作服务公司
+
+
+
+
+
+
+ 监管土地
+
+
+
+
+
+
+
+
+
+ 张队长
+
+
+
+ 管辖: 会发生肯德基回复
+
+
+
+
+ 监管农户: 100hu1
+
+
+ 涉及土地面积: 100hu1
+
+
+
+
+
+
+
+
+ 监管农户: 100hu1
+
+
+ 涉及土地面积: 100hu1
+
+
+
+
+ 种植户: 100hu1
+
+
+ 占地面积: 100hu1
+
+
+
+
+ 养殖户-大型动物: 100hu1
+
+
+ 占地面积: 100hu1
+
+
+
+
+ 养殖户-禽类: 100hu1
+
+
+ 占地面积: 100hu1
+
+
+
+
+ 养殖户-水产: 100hu1
+
+
+ 占地面积: 100hu1
+
+
+
+
+
+
+ 收起
+
+
+
+ 查看监管详情
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/pages/test/index.vue b/pages/test/index.vue
index 20032ec..e66b7ee 100644
--- a/pages/test/index.vue
+++ b/pages/test/index.vue
@@ -1,11 +1,8 @@
- {{counter.count}}
+
\ No newline at end of file
diff --git a/store/counter.js b/store/counter.js
deleted file mode 100644
index 8402069..0000000
--- a/store/counter.js
+++ /dev/null
@@ -1,15 +0,0 @@
-import {
- defineStore
-} from 'pinia'
-
-export const counterStore = defineStore('counter', {
- state: () => ({
- count: 0
- }),
- getters: {},
- actions: {
- increment() {
- this.count++
- }
- }
-})
\ No newline at end of file
diff --git a/store/userInfo.js b/store/userInfo.js
new file mode 100644
index 0000000..dfcf38c
--- /dev/null
+++ b/store/userInfo.js
@@ -0,0 +1,15 @@
+import {
+ defineStore
+} from 'pinia'
+
+export const userInfoStore = defineStore('counter', {
+ state: () => ({
+ user_id: ""
+ }),
+ getters: {},
+ actions: {
+ saveUserInfo(userInfo) {
+ this.user_id = userInfo
+ }
+ }
+})
\ No newline at end of file
diff --git a/unpackage/dist/dev/app-plus/app-config-service.js b/unpackage/dist/dev/app-plus/app-config-service.js
index b983d43..c0c8441 100644
--- a/unpackage/dist/dev/app-plus/app-config-service.js
+++ b/unpackage/dist/dev/app-plus/app-config-service.js
@@ -2,7 +2,7 @@
;(function(){
let u=void 0,isReady=false,onReadyCallbacks=[],isServiceReady=false,onServiceReadyCallbacks=[];
const __uniConfig = {"pages":[],"globalStyle":{"backgroundColor":"#F8F8F8","navigationBar":{"backgroundColor":"#F8F8F8","titleText":"uni-app","type":"default","titleColor":"#000000"},"isNVue":false},"nvue":{"compiler":"uni-app","styleCompiler":"uni-app","flex-direction":"column"},"renderer":"auto","appname":"test","splashscreen":{"alwaysShowBeforeRender":true,"autoclose":true},"compilerVersion":"3.8.12","entryPagePath":"pages/index/index","entryPageQuery":"","realEntryPagePath":"","networkTimeout":{"request":60000,"connectSocket":60000,"uploadFile":60000,"downloadFile":60000},"locales":{},"darkmode":false,"themeConfig":{}};
- const __uniRoutes = [{"path":"pages/index/index","meta":{"isQuit":true,"isEntry":true,"navigationBar":{"style":"custom","type":"default"},"isNVue":false}},{"path":"pages/InformationAdd/index","meta":{"enablePullDownRefresh":false,"navigationBar":{"backgroundColor":"#F4F4F4","titleText":"信息添加","type":"default","titleColor":"#000000"},"isNVue":false}},{"path":"pages/growRecord/index","meta":{"enablePullDownRefresh":false,"navigationBar":{"backgroundColor":"#F4F4F4","titleText":"生长记录","type":"default","titleColor":"#000000"},"isNVue":false}},{"path":"pages/detail/plant","meta":{"enablePullDownRefresh":false,"navigationBar":{"backgroundColor":"#F4F4F4","titleText":"详情","type":"default","titleColor":"#000000"},"isNVue":false}},{"path":"pages/allPlant/index","meta":{"enablePullDownRefresh":false,"navigationBar":{"backgroundColor":"#F4F4F4","titleText":"全部种植","type":"default","titleColor":"#000000"},"isNVue":false}},{"path":"pages/records/index","meta":{"enablePullDownRefresh":false,"navigationBar":{"backgroundColor":"#F4F4F4","titleText":"生长记录","type":"default","titleColor":"#000000"},"isNVue":false}},{"path":"pages/profile/index","meta":{"enablePullDownRefresh":false,"navigationBar":{"backgroundColor":"#F4F4F4","titleText":"生长概况","type":"default","titleColor":"#000000"},"isNVue":false}},{"path":"pages/feedIng/feedList","meta":{"enablePullDownRefresh":false,"navigationBar":{"backgroundColor":"#F4F4F4","titleText":"养殖列表","type":"default","titleColor":"#000000"},"isNVue":false}},{"path":"pages/feedIng/feedDetail","meta":{"enablePullDownRefresh":false,"navigationBar":{"backgroundColor":"#F4F4F4","titleText":"养殖详情","type":"default","titleColor":"#000000"},"isNVue":false}},{"path":"pages/feedIng/histroyFeed","meta":{"enablePullDownRefresh":false,"navigationBar":{"backgroundColor":"#F4F4F4","titleText":"历史养殖记录","type":"default","titleColor":"#000000"},"isNVue":false}},{"path":"pages/feedIng/updateFeed","meta":{"enablePullDownRefresh":false,"navigationBar":{"backgroundColor":"#F4F4F4","titleText":"更新饲养状态","type":"default","titleColor":"#000000"},"isNVue":false}},{"path":"pages/feedIng/vaccineInfo","meta":{"enablePullDownRefresh":false,"navigationBar":{"backgroundColor":"#F4F4F4","titleText":"疫苗信息","type":"default","titleColor":"#000000"},"isNVue":false}},{"path":"pages/feedIng/addPoultry","meta":{"enablePullDownRefresh":false,"navigationBar":{"backgroundColor":"#F4F4F4","titleText":"添加饲养动物","type":"default","titleColor":"#000000"},"isNVue":false}},{"path":"pages/feedIng/allFeed","meta":{"enablePullDownRefresh":false,"navigationBar":{"backgroundColor":"#F4F4F4","titleText":"全部养殖记录","type":"default","titleColor":"#000000"},"isNVue":false}},{"path":"pages/feedIng/allRecording","meta":{"enablePullDownRefresh":false,"navigationBar":{"backgroundColor":"#F4F4F4","titleText":"全部记录","type":"default","titleColor":"#000000"},"isNVue":false}},{"path":"pages/test/index","meta":{"enablePullDownRefresh":true,"navigationBar":{"titleText":"uni-app","type":"default"},"isNVue":false}},{"path":"pages/test/index1","meta":{"enablePullDownRefresh":true,"navigationBar":{"titleText":"uni-app","type":"default"},"isNVue":false}}].map(uniRoute=>(uniRoute.meta.route=uniRoute.path,__uniConfig.pages.push(uniRoute.path),uniRoute.path='/'+uniRoute.path,uniRoute));
+ const __uniRoutes = [{"path":"pages/index/index","meta":{"isQuit":true,"isEntry":true,"navigationBar":{"style":"custom","type":"default"},"isNVue":false}},{"path":"pages/InformationAdd/index","meta":{"enablePullDownRefresh":false,"navigationBar":{"backgroundColor":"#F4F4F4","titleText":"信息添加","type":"default","titleColor":"#000000"},"isNVue":false}},{"path":"pages/growRecord/index","meta":{"enablePullDownRefresh":false,"navigationBar":{"backgroundColor":"#F4F4F4","titleText":"生长记录","type":"default","titleColor":"#000000"},"isNVue":false}},{"path":"pages/detail/plant","meta":{"enablePullDownRefresh":false,"navigationBar":{"backgroundColor":"#F4F4F4","titleText":"详情","type":"default","titleColor":"#000000"},"isNVue":false}},{"path":"pages/allPlant/index","meta":{"enablePullDownRefresh":false,"navigationBar":{"backgroundColor":"#F4F4F4","titleText":"全部种植","type":"default","titleColor":"#000000"},"isNVue":false}},{"path":"pages/records/index","meta":{"enablePullDownRefresh":false,"navigationBar":{"backgroundColor":"#F4F4F4","titleText":"生长记录","type":"default","titleColor":"#000000"},"isNVue":false}},{"path":"pages/profile/index","meta":{"enablePullDownRefresh":false,"navigationBar":{"backgroundColor":"#F4F4F4","titleText":"生长概况","type":"default","titleColor":"#000000"},"isNVue":false}},{"path":"pages/feedIng/feedList","meta":{"enablePullDownRefresh":false,"navigationBar":{"backgroundColor":"#F4F4F4","titleText":"养殖列表","type":"default","titleColor":"#000000"},"isNVue":false}},{"path":"pages/feedIng/feedDetail","meta":{"enablePullDownRefresh":false,"navigationBar":{"backgroundColor":"#F4F4F4","titleText":"养殖详情","type":"default","titleColor":"#000000"},"isNVue":false}},{"path":"pages/feedIng/histroyFeed","meta":{"enablePullDownRefresh":false,"navigationBar":{"backgroundColor":"#F4F4F4","titleText":"历史养殖记录","type":"default","titleColor":"#000000"},"isNVue":false}},{"path":"pages/feedIng/updateFeed","meta":{"enablePullDownRefresh":false,"navigationBar":{"backgroundColor":"#F4F4F4","titleText":"更新饲养状态","type":"default","titleColor":"#000000"},"isNVue":false}},{"path":"pages/feedIng/vaccineInfo","meta":{"enablePullDownRefresh":false,"navigationBar":{"backgroundColor":"#F4F4F4","titleText":"疫苗信息","type":"default","titleColor":"#000000"},"isNVue":false}},{"path":"pages/feedIng/addPoultry","meta":{"enablePullDownRefresh":false,"navigationBar":{"backgroundColor":"#F4F4F4","titleText":"添加饲养动物","type":"default","titleColor":"#000000"},"isNVue":false}},{"path":"pages/feedIng/allFeed","meta":{"enablePullDownRefresh":false,"navigationBar":{"backgroundColor":"#F4F4F4","titleText":"全部养殖记录","type":"default","titleColor":"#000000"},"isNVue":false}},{"path":"pages/feedIng/allRecording","meta":{"enablePullDownRefresh":false,"navigationBar":{"backgroundColor":"#F4F4F4","titleText":"全部记录","type":"default","titleColor":"#000000"},"isNVue":false}},{"path":"pages/aquatic/addAquatic","meta":{"enablePullDownRefresh":false,"navigationBar":{"backgroundColor":"#F4F4F4","titleText":"添加养殖","type":"default","titleColor":"#000000"},"isNVue":false}},{"path":"pages/aquatic/updateGrow","meta":{"enablePullDownRefresh":false,"navigationBar":{"backgroundColor":"#F4F4F4","titleText":"更新生长记录","type":"default","titleColor":"#000000"},"isNVue":false}},{"path":"pages/aquatic/detail","meta":{"enablePullDownRefresh":false,"navigationBar":{"backgroundColor":"#F4F4F4","titleText":"详情","type":"default","titleColor":"#000000"},"isNVue":false}},{"path":"pages/supervision/group","meta":{"enablePullDownRefresh":false,"navigationBar":{"backgroundColor":"#F4F4F4","titleText":"小组公司监管","type":"default","titleColor":"#000000"},"isNVue":false}},{"path":"pages/supervision/captain","meta":{"enablePullDownRefresh":false,"navigationBar":{"backgroundColor":"#F4F4F4","titleText":"生产队长监管","type":"default","titleColor":"#000000"},"isNVue":false}},{"path":"pages/supervision/farmerDeatil","meta":{"enablePullDownRefresh":false,"navigationBar":{"backgroundColor":"#F4F4F4","titleText":"农户详情","type":"default","titleColor":"#000000"},"isNVue":false}},{"path":"pages/supervision/detail","meta":{"enablePullDownRefresh":false,"navigationBar":{"backgroundColor":"#F4F4F4","titleText":"土地详情","type":"default","titleColor":"#000000"},"isNVue":false}},{"path":"pages/test/index","meta":{"enablePullDownRefresh":true,"navigationBar":{"titleText":"uni-app","type":"default"},"isNVue":false}},{"path":"pages/test/index1","meta":{"enablePullDownRefresh":true,"navigationBar":{"titleText":"uni-app","type":"default"},"isNVue":false}}].map(uniRoute=>(uniRoute.meta.route=uniRoute.path,__uniConfig.pages.push(uniRoute.path),uniRoute.path='/'+uniRoute.path,uniRoute));
__uniConfig.styles=[];//styles
__uniConfig.onReady=function(callback){if(__uniConfig.ready){callback()}else{onReadyCallbacks.push(callback)}};Object.defineProperty(__uniConfig,"ready",{get:function(){return isReady},set:function(val){isReady=val;if(!isReady){return}const callbacks=onReadyCallbacks.slice(0);onReadyCallbacks.length=0;callbacks.forEach(function(callback){callback()})}});
__uniConfig.onServiceReady=function(callback){if(__uniConfig.serviceReady){callback()}else{onServiceReadyCallbacks.push(callback)}};Object.defineProperty(__uniConfig,"serviceReady",{get:function(){return isServiceReady},set:function(val){isServiceReady=val;if(!isServiceReady){return}const callbacks=onServiceReadyCallbacks.slice(0);onServiceReadyCallbacks.length=0;callbacks.forEach(function(callback){callback()})}});
diff --git a/unpackage/dist/dev/app-plus/app-service.js b/unpackage/dist/dev/app-plus/app-service.js
index 5da0da5..cdb93d0 100644
--- a/unpackage/dist/dev/app-plus/app-service.js
+++ b/unpackage/dist/dev/app-plus/app-service.js
@@ -245,6 +245,7 @@ if (uni.restoreGlobal) {
"uicon-zh": "",
"uicon-en": ""
};
+ const ON_LOAD = "onLoad";
function formatAppLog(type, filename, ...args) {
if (uni.__log__) {
uni.__log__(type, filename, ...args);
@@ -255,6 +256,10 @@ if (uni.restoreGlobal) {
function resolveEasycom(component, easycom2) {
return shared.isString(component) ? easycom2 : component;
}
+ const createHook = (lifecycle) => (hook, target = vue.getCurrentInstance()) => {
+ !vue.isInSSRComponentSetup && vue.injectHook(lifecycle, hook, target);
+ };
+ const onLoad = /* @__PURE__ */ createHook(ON_LOAD);
const version = "3";
{
formatAppLog("log", "at node_modules/uview-plus/libs/config/config.js:5", `
@@ -1706,7 +1711,7 @@ if (uni.restoreGlobal) {
previewImage: true
}
};
- const props$e = {
+ const props$i = {
...ActionSheet,
...Album,
...Alert,
@@ -1796,92 +1801,92 @@ if (uni.restoreGlobal) {
...Transition,
...Upload
};
- const props$d = {
+ const props$h = {
props: {
// 图标类名
name: {
type: String,
- default: props$e.icon.name
+ default: props$i.icon.name
},
// 图标颜色,可接受主题色
color: {
type: String,
- default: props$e.icon.color
+ default: props$i.icon.color
},
// 字体大小,单位px
size: {
type: [String, Number],
- default: props$e.icon.size
+ default: props$i.icon.size
},
// 是否显示粗体
bold: {
type: Boolean,
- default: props$e.icon.bold
+ default: props$i.icon.bold
},
// 点击图标的时候传递事件出去的index(用于区分点击了哪一个)
index: {
type: [String, Number],
- default: props$e.icon.index
+ default: props$i.icon.index
},
// 触摸图标时的类名
hoverClass: {
type: String,
- default: props$e.icon.hoverClass
+ default: props$i.icon.hoverClass
},
// 自定义扩展前缀,方便用户扩展自己的图标库
customPrefix: {
type: String,
- default: props$e.icon.customPrefix
+ default: props$i.icon.customPrefix
},
// 图标右边或者下面的文字
label: {
type: [String, Number],
- default: props$e.icon.label
+ default: props$i.icon.label
},
// label的位置,只能右边或者下边
labelPos: {
type: String,
- default: props$e.icon.labelPos
+ default: props$i.icon.labelPos
},
// label的大小
labelSize: {
type: [String, Number],
- default: props$e.icon.labelSize
+ default: props$i.icon.labelSize
},
// label的颜色
labelColor: {
type: String,
- default: props$e.icon.labelColor
+ default: props$i.icon.labelColor
},
// label与图标的距离
space: {
type: [String, Number],
- default: props$e.icon.space
+ default: props$i.icon.space
},
// 图片的mode
imgMode: {
type: String,
- default: props$e.icon.imgMode
+ default: props$i.icon.imgMode
},
// 用于显示图片小图标时,图片的宽度
width: {
type: [String, Number],
- default: props$e.icon.width
+ default: props$i.icon.width
},
// 用于显示图片小图标时,图片的高度
height: {
type: [String, Number],
- default: props$e.icon.height
+ default: props$i.icon.height
},
// 用于解决某些情况下,让图标垂直居中的用途
top: {
type: [String, Number],
- default: props$e.icon.top
+ default: props$i.icon.top
},
// 是否阻止事件传播
stop: {
type: Boolean,
- default: props$e.icon.stop
+ default: props$i.icon.stop
}
}
};
@@ -2022,13 +2027,13 @@ if (uni.restoreGlobal) {
}
return target;
};
- const _sfc_main$R = {
+ const _sfc_main$12 = {
name: "u-icon",
data() {
return {};
},
emits: ["click"],
- mixins: [mpMixin, mixin, props$d],
+ mixins: [mpMixin, mixin, props$h],
computed: {
uClasses() {
let classes = [];
@@ -2072,7 +2077,7 @@ if (uni.restoreGlobal) {
}
}
};
- function _sfc_render$B(_ctx, _cache, $props, $setup, $data, $options) {
+ function _sfc_render$z(_ctx, _cache, $props, $setup, $data, $options) {
return vue.openBlock(), vue.createElementBlock(
"view",
{
@@ -2116,28 +2121,28 @@ if (uni.restoreGlobal) {
/* CLASS */
);
}
- const __easycom_0$7 = /* @__PURE__ */ _export_sfc(_sfc_main$R, [["render", _sfc_render$B], ["__scopeId", "data-v-1c933a9a"], ["__file", "D:/zmj/uniapp/TraceabilityAPP/node_modules/uview-plus/components/u-icon/u-icon.vue"]]);
- const props$c = {
+ const __easycom_0$7 = /* @__PURE__ */ _export_sfc(_sfc_main$12, [["render", _sfc_render$z], ["__scopeId", "data-v-1c933a9a"], ["__file", "D:/zmj/uniapp/TraceabilityAPP/node_modules/uview-plus/components/u-icon/u-icon.vue"]]);
+ const props$g = {
props: {
// 是否展示组件
show: {
type: Boolean,
- default: props$e.transition.show
+ default: props$i.transition.show
},
// 使用的动画模式
mode: {
type: String,
- default: props$e.transition.mode
+ default: props$i.transition.mode
},
// 动画的执行时间,单位ms
duration: {
type: [String, Number],
- default: props$e.transition.duration
+ default: props$i.transition.duration
},
// 使用的动画过渡函数
timingFunction: {
type: String,
- default: props$e.transition.timingFunction
+ default: props$i.transition.timingFunction
}
}
};
@@ -2198,7 +2203,7 @@ if (uni.restoreGlobal) {
}
}
};
- const _sfc_main$Q = {
+ const _sfc_main$11 = {
name: "u-transition",
data() {
return {
@@ -2231,7 +2236,7 @@ if (uni.restoreGlobal) {
}
},
// 将mixin挂在到组件中,uni.$u.mixin实际上为一个vue格式对象
- mixins: [mpMixin, mixin, transition, props$c],
+ mixins: [mpMixin, mixin, transition, props$g],
watch: {
show: {
handler(newVal) {
@@ -2242,7 +2247,7 @@ if (uni.restoreGlobal) {
}
}
};
- function _sfc_render$A(_ctx, _cache, $props, $setup, $data, $options) {
+ function _sfc_render$y(_ctx, _cache, $props, $setup, $data, $options) {
return $data.inited ? (vue.openBlock(), vue.createElementBlock(
"view",
{
@@ -2260,94 +2265,94 @@ if (uni.restoreGlobal) {
/* CLASS, STYLE, HYDRATE_EVENTS */
)) : vue.createCommentVNode("v-if", true);
}
- const __easycom_4$1 = /* @__PURE__ */ _export_sfc(_sfc_main$Q, [["render", _sfc_render$A], ["__scopeId", "data-v-0573594d"], ["__file", "D:/zmj/uniapp/TraceabilityAPP/node_modules/uview-plus/components/u-transition/u-transition.vue"]]);
- const props$b = {
+ const __easycom_4$1 = /* @__PURE__ */ _export_sfc(_sfc_main$11, [["render", _sfc_render$y], ["__scopeId", "data-v-0573594d"], ["__file", "D:/zmj/uniapp/TraceabilityAPP/node_modules/uview-plus/components/u-transition/u-transition.vue"]]);
+ const props$f = {
props: {
// 图片地址
src: {
type: String,
- default: props$e.image.src
+ default: props$i.image.src
},
// 裁剪模式
mode: {
type: String,
- default: props$e.image.mode
+ default: props$i.image.mode
},
// 宽度,单位任意
width: {
type: [String, Number],
- default: props$e.image.width
+ default: props$i.image.width
},
// 高度,单位任意
height: {
type: [String, Number],
- default: props$e.image.height
+ default: props$i.image.height
},
// 图片形状,circle-圆形,square-方形
shape: {
type: String,
- default: props$e.image.shape
+ default: props$i.image.shape
},
// 圆角,单位任意
radius: {
type: [String, Number],
- default: props$e.image.radius
+ default: props$i.image.radius
},
// 是否懒加载,微信小程序、App、百度小程序、字节跳动小程序
lazyLoad: {
type: Boolean,
- default: props$e.image.lazyLoad
+ default: props$i.image.lazyLoad
},
// 开启长按图片显示识别微信小程序码菜单
showMenuByLongpress: {
type: Boolean,
- default: props$e.image.showMenuByLongpress
+ default: props$i.image.showMenuByLongpress
},
// 加载中的图标,或者小图片
loadingIcon: {
type: String,
- default: props$e.image.loadingIcon
+ default: props$i.image.loadingIcon
},
// 加载失败的图标,或者小图片
errorIcon: {
type: String,
- default: props$e.image.errorIcon
+ default: props$i.image.errorIcon
},
// 是否显示加载中的图标或者自定义的slot
showLoading: {
type: Boolean,
- default: props$e.image.showLoading
+ default: props$i.image.showLoading
},
// 是否显示加载错误的图标或者自定义的slot
showError: {
type: Boolean,
- default: props$e.image.showError
+ default: props$i.image.showError
},
// 是否需要淡入效果
fade: {
type: Boolean,
- default: props$e.image.fade
+ default: props$i.image.fade
},
// 只支持网络资源,只对微信小程序有效
webp: {
type: Boolean,
- default: props$e.image.webp
+ default: props$i.image.webp
},
// 过渡时间,单位ms
duration: {
type: [String, Number],
- default: props$e.image.duration
+ default: props$i.image.duration
},
// 背景颜色,用于深色页面加载图片时,为了和背景色融合
bgColor: {
type: String,
- default: props$e.image.bgColor
+ default: props$i.image.bgColor
}
}
};
- const _sfc_main$P = {
+ const _sfc_main$10 = {
name: "u-image",
- mixins: [mpMixin, mixin, props$b],
+ mixins: [mpMixin, mixin, props$f],
data() {
return {
// 图片是否加载错误,如果是,则显示错误占位图
@@ -2417,7 +2422,7 @@ if (uni.restoreGlobal) {
}
}
};
- function _sfc_render$z(_ctx, _cache, $props, $setup, $data, $options) {
+ function _sfc_render$x(_ctx, _cache, $props, $setup, $data, $options) {
const _component_u_icon = resolveEasycom(vue.resolveDynamicComponent("u-icon"), __easycom_0$7);
const _component_u_transition = resolveEasycom(vue.resolveDynamicComponent("u-transition"), __easycom_4$1);
return vue.openBlock(), vue.createBlock(_component_u_transition, {
@@ -2505,7 +2510,7 @@ if (uni.restoreGlobal) {
/* FORWARDED */
}, 8, ["show", "duration"]);
}
- const __easycom_0$6 = /* @__PURE__ */ _export_sfc(_sfc_main$P, [["render", _sfc_render$z], ["__scopeId", "data-v-9d58ba7c"], ["__file", "D:/zmj/uniapp/TraceabilityAPP/node_modules/uview-plus/components/u-image/u-image.vue"]]);
+ const __easycom_0$6 = /* @__PURE__ */ _export_sfc(_sfc_main$10, [["render", _sfc_render$x], ["__scopeId", "data-v-9d58ba7c"], ["__file", "D:/zmj/uniapp/TraceabilityAPP/node_modules/uview-plus/components/u-image/u-image.vue"]]);
let BASE_URL;
{
BASE_URL = "http://ceshi-suyuan.lihaink.cn/";
@@ -2518,7 +2523,6 @@ if (uni.restoreGlobal) {
"TOKEN": uni.getStorageSync("SY_TOKEN") || ""
}
};
- formatAppLog("log", "at utils/syhttp.js:4", "指定");
function baseRequest(url2, method, data, {
noAuth = false,
noVerify = false,
@@ -2527,7 +2531,7 @@ if (uni.restoreGlobal) {
let Url = config.HTTP_REQUEST_URL, header = config.HEADER;
return new Promise((reslove, reject) => {
uni.request({
- url: Url + "adminapi" + url2,
+ url: Url + "api" + url2,
method: method || "GET",
header: {
...header
@@ -2579,7 +2583,5761 @@ if (uni.restoreGlobal) {
["options", "get", "post", "put", "head", "delete", "trace", "connect"].forEach((method) => {
syhttp[method] = (api, data, opt) => baseRequest(api, method, data, opt || {});
});
- const companyMine = (data) => syhttp.post("/SuYuan/monitorDetail", data);
+ const userInfoAPI = (data) => syhttp.get("/user/userInfo", data);
+ const landInfoAPI = (data) => syhttp.get("/LandPlant/landInfo", data);
+ const AddlandInfoAPI = (data) => syhttp.post("/LandPlant/addLandCrop", data);
+ const addLandCropPicAPI = (data) => syhttp.post("/LandPlant/addLandCropPic", data);
+ const landCropRecordListAPI = (data) => syhttp.get("/LandPlant/landCropRecordList", data);
+ const landEnvDataCurrAPI = (data) => syhttp.get("/LandPlant/landEnvDataCurr", data);
+ const setLandCropRipeAPI = (data) => syhttp.get("/LandPlant/setLandCropRipe", data);
+ const landCropPicListAPI = (data) => syhttp.get("/LandPlant/landCropPicList", data);
+ const actionsListAPI = (data) => syhttp.get("/user/actions", data);
+ const _sfc_main$$ = {
+ name: "uniTh",
+ options: {
+ virtualHost: true
+ },
+ components: {},
+ emits: ["sort-change", "filter-change"],
+ props: {
+ width: {
+ type: [String, Number],
+ default: ""
+ },
+ align: {
+ type: String,
+ default: "left"
+ },
+ rowspan: {
+ type: [Number, String],
+ default: 1
+ },
+ colspan: {
+ type: [Number, String],
+ default: 1
+ },
+ sortable: {
+ type: Boolean,
+ default: false
+ },
+ filterType: {
+ type: String,
+ default: ""
+ },
+ filterData: {
+ type: Array,
+ default() {
+ return [];
+ }
+ },
+ filterDefaultValue: {
+ type: [Array, String],
+ default() {
+ return "";
+ }
+ }
+ },
+ data() {
+ return {
+ border: false,
+ ascending: false,
+ descending: false
+ };
+ },
+ computed: {
+ // 根据props中的width属性 自动匹配当前th的宽度(px)
+ customWidth() {
+ if (typeof this.width === "number") {
+ return this.width;
+ } else if (typeof this.width === "string") {
+ let regexHaveUnitPx = new RegExp(/^[1-9][0-9]*px$/g);
+ let regexHaveUnitRpx = new RegExp(/^[1-9][0-9]*rpx$/g);
+ let regexHaveNotUnit = new RegExp(/^[1-9][0-9]*$/g);
+ if (this.width.match(regexHaveUnitPx) !== null) {
+ return this.width.replace("px", "");
+ } else if (this.width.match(regexHaveUnitRpx) !== null) {
+ let numberRpx = Number(this.width.replace("rpx", ""));
+ let widthCoe = uni.getSystemInfoSync().screenWidth / 750;
+ return Math.round(numberRpx * widthCoe);
+ } else if (this.width.match(regexHaveNotUnit) !== null) {
+ return this.width;
+ } else {
+ return "";
+ }
+ } else {
+ return "";
+ }
+ },
+ contentAlign() {
+ let align = "left";
+ switch (this.align) {
+ case "left":
+ align = "flex-start";
+ break;
+ case "center":
+ align = "center";
+ break;
+ case "right":
+ align = "flex-end";
+ break;
+ }
+ return align;
+ }
+ },
+ created() {
+ this.root = this.getTable("uniTable");
+ this.rootTr = this.getTable("uniTr");
+ this.rootTr.minWidthUpdate(this.customWidth ? this.customWidth : 140);
+ this.border = this.root.border;
+ this.root.thChildren.push(this);
+ },
+ methods: {
+ sort() {
+ if (!this.sortable)
+ return;
+ this.clearOther();
+ if (!this.ascending && !this.descending) {
+ this.ascending = true;
+ this.$emit("sort-change", { order: "ascending" });
+ return;
+ }
+ if (this.ascending && !this.descending) {
+ this.ascending = false;
+ this.descending = true;
+ this.$emit("sort-change", { order: "descending" });
+ return;
+ }
+ if (!this.ascending && this.descending) {
+ this.ascending = false;
+ this.descending = false;
+ this.$emit("sort-change", { order: null });
+ }
+ },
+ ascendingFn() {
+ this.clearOther();
+ this.ascending = !this.ascending;
+ this.descending = false;
+ this.$emit("sort-change", { order: this.ascending ? "ascending" : null });
+ },
+ descendingFn() {
+ this.clearOther();
+ this.descending = !this.descending;
+ this.ascending = false;
+ this.$emit("sort-change", { order: this.descending ? "descending" : null });
+ },
+ clearOther() {
+ this.root.thChildren.map((item) => {
+ if (item !== this) {
+ item.ascending = false;
+ item.descending = false;
+ }
+ return item;
+ });
+ },
+ ondropdown(e) {
+ this.$emit("filter-change", e);
+ },
+ /**
+ * 获取父元素实例
+ */
+ getTable(name) {
+ let parent = this.$parent;
+ let parentName = parent.$options.name;
+ while (parentName !== name) {
+ parent = parent.$parent;
+ if (!parent)
+ return false;
+ parentName = parent.$options.name;
+ }
+ return parent;
+ }
+ }
+ };
+ function _sfc_render$w(_ctx, _cache, $props, $setup, $data, $options) {
+ return vue.openBlock(), vue.createElementBlock(
+ "view",
+ {
+ class: vue.normalizeClass(["uni-table-th", { "table--border": $data.border }]),
+ style: vue.normalizeStyle({ width: $options.customWidth + "px", "text-align": $props.align })
+ },
+ [
+ vue.renderSlot(_ctx.$slots, "default", {}, void 0, true)
+ ],
+ 6
+ /* CLASS, STYLE */
+ );
+ }
+ const __easycom_0$5 = /* @__PURE__ */ _export_sfc(_sfc_main$$, [["render", _sfc_render$w], ["__scopeId", "data-v-bf970acd"], ["__file", "D:/zmj/uniapp/TraceabilityAPP/uni_modules/uni-table/components/uni-th/uni-th.vue"]]);
+ const _sfc_main$_ = {
+ name: "TableCheckbox",
+ emits: ["checkboxSelected"],
+ props: {
+ indeterminate: {
+ type: Boolean,
+ default: false
+ },
+ checked: {
+ type: [Boolean, String],
+ default: false
+ },
+ disabled: {
+ type: Boolean,
+ default: false
+ },
+ index: {
+ type: Number,
+ default: -1
+ },
+ cellData: {
+ type: Object,
+ default() {
+ return {};
+ }
+ }
+ },
+ watch: {
+ checked(newVal) {
+ if (typeof this.checked === "boolean") {
+ this.isChecked = newVal;
+ } else {
+ this.isChecked = true;
+ }
+ },
+ indeterminate(newVal) {
+ this.isIndeterminate = newVal;
+ }
+ },
+ data() {
+ return {
+ isChecked: false,
+ isDisabled: false,
+ isIndeterminate: false
+ };
+ },
+ created() {
+ if (typeof this.checked === "boolean") {
+ this.isChecked = this.checked;
+ }
+ this.isDisabled = this.disabled;
+ },
+ methods: {
+ selected() {
+ if (this.isDisabled)
+ return;
+ this.isIndeterminate = false;
+ this.isChecked = !this.isChecked;
+ this.$emit("checkboxSelected", {
+ checked: this.isChecked,
+ data: this.cellData
+ });
+ }
+ }
+ };
+ function _sfc_render$v(_ctx, _cache, $props, $setup, $data, $options) {
+ return vue.openBlock(), vue.createElementBlock("view", {
+ class: "uni-table-checkbox",
+ onClick: _cache[0] || (_cache[0] = (...args) => $options.selected && $options.selected(...args))
+ }, [
+ !$props.indeterminate ? (vue.openBlock(), vue.createElementBlock(
+ "view",
+ {
+ key: 0,
+ class: vue.normalizeClass(["checkbox__inner", { "is-checked": $data.isChecked, "is-disable": $data.isDisabled }])
+ },
+ [
+ vue.createElementVNode("view", { class: "checkbox__inner-icon" })
+ ],
+ 2
+ /* CLASS */
+ )) : (vue.openBlock(), vue.createElementBlock("view", {
+ key: 1,
+ class: "checkbox__inner checkbox--indeterminate"
+ }, [
+ vue.createElementVNode("view", { class: "checkbox__inner-icon" })
+ ]))
+ ]);
+ }
+ const tableCheckbox = /* @__PURE__ */ _export_sfc(_sfc_main$_, [["render", _sfc_render$v], ["__scopeId", "data-v-25e435b1"], ["__file", "D:/zmj/uniapp/TraceabilityAPP/uni_modules/uni-table/components/uni-tr/table-checkbox.vue"]]);
+ const _sfc_main$Z = {
+ name: "uniTr",
+ components: { tableCheckbox },
+ props: {
+ disabled: {
+ type: Boolean,
+ default: false
+ },
+ keyValue: {
+ type: [String, Number],
+ default: ""
+ }
+ },
+ options: {
+ virtualHost: true
+ },
+ data() {
+ return {
+ value: false,
+ border: false,
+ selection: false,
+ widthThArr: [],
+ ishead: true,
+ checked: false,
+ indeterminate: false
+ };
+ },
+ created() {
+ this.root = this.getTable();
+ this.head = this.getTable("uniThead");
+ if (this.head) {
+ this.ishead = false;
+ this.head.init(this);
+ }
+ this.border = this.root.border;
+ this.selection = this.root.type;
+ this.root.trChildren.push(this);
+ const rowData = this.root.data.find((v2) => v2[this.root.rowKey] === this.keyValue);
+ if (rowData) {
+ this.rowData = rowData;
+ }
+ this.root.isNodata();
+ },
+ mounted() {
+ if (this.widthThArr.length > 0) {
+ const selectionWidth = this.selection === "selection" ? 50 : 0;
+ this.root.minWidth = this.widthThArr.reduce((a2, b2) => Number(a2) + Number(b2)) + selectionWidth;
+ }
+ },
+ unmounted() {
+ const index2 = this.root.trChildren.findIndex((i2) => i2 === this);
+ this.root.trChildren.splice(index2, 1);
+ this.root.isNodata();
+ },
+ methods: {
+ minWidthUpdate(width) {
+ this.widthThArr.push(width);
+ },
+ // 选中
+ checkboxSelected(e) {
+ let rootData = this.root.data.find((v2) => v2[this.root.rowKey] === this.keyValue);
+ this.checked = e.checked;
+ this.root.check(rootData || this, e.checked, rootData ? this.keyValue : null);
+ },
+ change(e) {
+ this.root.trChildren.forEach((item) => {
+ if (item === this) {
+ this.root.check(this, e.detail.value.length > 0 ? true : false);
+ }
+ });
+ },
+ /**
+ * 获取父元素实例
+ */
+ getTable(name = "uniTable") {
+ let parent = this.$parent;
+ let parentName = parent.$options.name;
+ while (parentName !== name) {
+ parent = parent.$parent;
+ if (!parent)
+ return false;
+ parentName = parent.$options.name;
+ }
+ return parent;
+ }
+ }
+ };
+ function _sfc_render$u(_ctx, _cache, $props, $setup, $data, $options) {
+ const _component_table_checkbox = vue.resolveComponent("table-checkbox");
+ return vue.openBlock(), vue.createElementBlock("view", { class: "uni-table-tr" }, [
+ $data.selection === "selection" ? (vue.openBlock(), vue.createElementBlock(
+ "view",
+ {
+ key: 0,
+ class: vue.normalizeClass(["checkbox", { "tr-table--border": $data.border }])
+ },
+ [
+ vue.createVNode(_component_table_checkbox, {
+ checked: $data.checked,
+ indeterminate: $data.indeterminate,
+ disabled: $props.disabled,
+ onCheckboxSelected: $options.checkboxSelected
+ }, null, 8, ["checked", "indeterminate", "disabled", "onCheckboxSelected"])
+ ],
+ 2
+ /* CLASS */
+ )) : vue.createCommentVNode("v-if", true),
+ vue.renderSlot(_ctx.$slots, "default", {}, void 0, true)
+ ]);
+ }
+ const __easycom_1$7 = /* @__PURE__ */ _export_sfc(_sfc_main$Z, [["render", _sfc_render$u], ["__scopeId", "data-v-b48b3e32"], ["__file", "D:/zmj/uniapp/TraceabilityAPP/uni_modules/uni-table/components/uni-tr/uni-tr.vue"]]);
+ const _sfc_main$Y = {
+ name: "uniTd",
+ options: {
+ virtualHost: true
+ },
+ props: {
+ width: {
+ type: [String, Number],
+ default: ""
+ },
+ align: {
+ type: String,
+ default: "left"
+ },
+ rowspan: {
+ type: [Number, String],
+ default: 1
+ },
+ colspan: {
+ type: [Number, String],
+ default: 1
+ }
+ },
+ data() {
+ return {
+ border: false
+ };
+ },
+ created() {
+ this.root = this.getTable();
+ this.border = this.root.border;
+ },
+ methods: {
+ /**
+ * 获取父元素实例
+ */
+ getTable() {
+ let parent = this.$parent;
+ let parentName = parent.$options.name;
+ while (parentName !== "uniTable") {
+ parent = parent.$parent;
+ if (!parent)
+ return false;
+ parentName = parent.$options.name;
+ }
+ return parent;
+ }
+ }
+ };
+ function _sfc_render$t(_ctx, _cache, $props, $setup, $data, $options) {
+ return vue.openBlock(), vue.createElementBlock(
+ vue.Fragment,
+ null,
+ [
+ vue.createCommentVNode(` :class="{'table--border':border}" `),
+ vue.createElementVNode(
+ "view",
+ {
+ class: vue.normalizeClass(["uni-table-td", { "table--border": $data.border }]),
+ style: vue.normalizeStyle({ width: $props.width + "px", "text-align": $props.align })
+ },
+ [
+ vue.renderSlot(_ctx.$slots, "default", {}, void 0, true)
+ ],
+ 6
+ /* CLASS, STYLE */
+ )
+ ],
+ 2112
+ /* STABLE_FRAGMENT, DEV_ROOT_FRAGMENT */
+ );
+ }
+ const __easycom_2$4 = /* @__PURE__ */ _export_sfc(_sfc_main$Y, [["render", _sfc_render$t], ["__scopeId", "data-v-edae4802"], ["__file", "D:/zmj/uniapp/TraceabilityAPP/uni_modules/uni-table/components/uni-td/uni-td.vue"]]);
+ const _sfc_main$X = {
+ name: "uniTable",
+ options: {
+ virtualHost: true
+ },
+ emits: ["selection-change"],
+ props: {
+ data: {
+ type: Array,
+ default() {
+ return [];
+ }
+ },
+ // 是否有竖线
+ border: {
+ type: Boolean,
+ default: false
+ },
+ // 是否显示斑马线
+ stripe: {
+ type: Boolean,
+ default: false
+ },
+ // 多选
+ type: {
+ type: String,
+ default: ""
+ },
+ // 没有更多数据
+ emptyText: {
+ type: String,
+ default: "没有更多数据"
+ },
+ loading: {
+ type: Boolean,
+ default: false
+ },
+ rowKey: {
+ type: String,
+ default: ""
+ }
+ },
+ data() {
+ return {
+ noData: true,
+ minWidth: 0,
+ multiTableHeads: []
+ };
+ },
+ watch: {
+ loading(val) {
+ },
+ data(newVal) {
+ this.theadChildren;
+ if (this.theadChildren) {
+ this.theadChildren.rowspan;
+ }
+ this.noData = false;
+ }
+ },
+ created() {
+ this.trChildren = [];
+ this.thChildren = [];
+ this.theadChildren = null;
+ this.backData = [];
+ this.backIndexData = [];
+ },
+ methods: {
+ isNodata() {
+ this.theadChildren;
+ let rowspan = 1;
+ if (this.theadChildren) {
+ rowspan = this.theadChildren.rowspan;
+ }
+ this.noData = this.trChildren.length - rowspan <= 0;
+ },
+ /**
+ * 选中所有
+ */
+ selectionAll() {
+ let startIndex = 1;
+ let theadChildren = this.theadChildren;
+ if (!this.theadChildren) {
+ theadChildren = this.trChildren[0];
+ } else {
+ startIndex = theadChildren.rowspan - 1;
+ }
+ let isHaveData = this.data && this.data.length > 0;
+ theadChildren.checked = true;
+ theadChildren.indeterminate = false;
+ this.trChildren.forEach((item, index2) => {
+ if (!item.disabled) {
+ item.checked = true;
+ if (isHaveData && item.keyValue) {
+ const row = this.data.find((v2) => v2[this.rowKey] === item.keyValue);
+ if (!this.backData.find((v2) => v2[this.rowKey] === row[this.rowKey])) {
+ this.backData.push(row);
+ }
+ }
+ if (index2 > startIndex - 1 && this.backIndexData.indexOf(index2 - startIndex) === -1) {
+ this.backIndexData.push(index2 - startIndex);
+ }
+ }
+ });
+ this.$emit("selection-change", {
+ detail: {
+ value: this.backData,
+ index: this.backIndexData
+ }
+ });
+ },
+ /**
+ * 用于多选表格,切换某一行的选中状态,如果使用了第二个参数,则是设置这一行选中与否(selected 为 true 则选中)
+ */
+ toggleRowSelection(row, selected) {
+ row = [].concat(row);
+ this.trChildren.forEach((item, index2) => {
+ const select = row.findIndex((v2) => {
+ if (typeof v2 === "number") {
+ return v2 === index2 - 1;
+ } else {
+ return v2[this.rowKey] === item.keyValue;
+ }
+ });
+ let ischeck = item.checked;
+ if (select !== -1) {
+ if (typeof selected === "boolean") {
+ item.checked = selected;
+ } else {
+ item.checked = !item.checked;
+ }
+ if (ischeck !== item.checked) {
+ this.check(item.rowData || item, item.checked, item.rowData ? item.keyValue : null, true);
+ }
+ }
+ });
+ this.$emit("selection-change", {
+ detail: {
+ value: this.backData,
+ index: this.backIndexData
+ }
+ });
+ },
+ /**
+ * 用于多选表格,清空用户的选择
+ */
+ clearSelection() {
+ let theadChildren = this.theadChildren;
+ if (!this.theadChildren) {
+ theadChildren = this.trChildren[0];
+ }
+ theadChildren.checked = false;
+ theadChildren.indeterminate = false;
+ this.trChildren.forEach((item) => {
+ item.checked = false;
+ });
+ this.backData = [];
+ this.backIndexData = [];
+ this.$emit("selection-change", {
+ detail: {
+ value: [],
+ index: []
+ }
+ });
+ },
+ /**
+ * 用于多选表格,切换所有行的选中状态
+ */
+ toggleAllSelection() {
+ let list = [];
+ let startIndex = 1;
+ let theadChildren = this.theadChildren;
+ if (!this.theadChildren) {
+ theadChildren = this.trChildren[0];
+ } else {
+ startIndex = theadChildren.rowspan - 1;
+ }
+ this.trChildren.forEach((item, index2) => {
+ if (!item.disabled) {
+ if (index2 > startIndex - 1) {
+ list.push(index2 - startIndex);
+ }
+ }
+ });
+ this.toggleRowSelection(list);
+ },
+ /**
+ * 选中\取消选中
+ * @param {Object} child
+ * @param {Object} check
+ * @param {Object} rowValue
+ */
+ check(child, check, keyValue, emit) {
+ let theadChildren = this.theadChildren;
+ if (!this.theadChildren) {
+ theadChildren = this.trChildren[0];
+ }
+ let childDomIndex = this.trChildren.findIndex((item, index2) => child === item);
+ if (childDomIndex < 0) {
+ childDomIndex = this.data.findIndex((v2) => v2[this.rowKey] === keyValue) + 1;
+ }
+ this.trChildren.filter((v2) => !v2.disabled && v2.keyValue).length;
+ if (childDomIndex === 0) {
+ check ? this.selectionAll() : this.clearSelection();
+ return;
+ }
+ if (check) {
+ if (keyValue) {
+ this.backData.push(child);
+ }
+ this.backIndexData.push(childDomIndex - 1);
+ } else {
+ const index2 = this.backData.findIndex((v2) => v2[this.rowKey] === keyValue);
+ const idx = this.backIndexData.findIndex((item) => item === childDomIndex - 1);
+ if (keyValue) {
+ this.backData.splice(index2, 1);
+ }
+ this.backIndexData.splice(idx, 1);
+ }
+ const domCheckAll = this.trChildren.find((item, index2) => index2 > 0 && !item.checked && !item.disabled);
+ if (!domCheckAll) {
+ theadChildren.indeterminate = false;
+ theadChildren.checked = true;
+ } else {
+ theadChildren.indeterminate = true;
+ theadChildren.checked = false;
+ }
+ if (this.backIndexData.length === 0) {
+ theadChildren.indeterminate = false;
+ }
+ if (!emit) {
+ this.$emit("selection-change", {
+ detail: {
+ value: this.backData,
+ index: this.backIndexData
+ }
+ });
+ }
+ }
+ }
+ };
+ function _sfc_render$s(_ctx, _cache, $props, $setup, $data, $options) {
+ return vue.openBlock(), vue.createElementBlock(
+ "view",
+ {
+ class: vue.normalizeClass(["uni-table-scroll", { "table--border": $props.border, "border-none": !$data.noData }])
+ },
+ [
+ vue.createElementVNode(
+ "view",
+ {
+ class: vue.normalizeClass(["uni-table", { "table--stripe": $props.stripe }]),
+ style: vue.normalizeStyle({ "min-width": $data.minWidth + "px" })
+ },
+ [
+ vue.renderSlot(_ctx.$slots, "default", {}, void 0, true),
+ $data.noData ? (vue.openBlock(), vue.createElementBlock("view", {
+ key: 0,
+ class: "uni-table-loading"
+ }, [
+ vue.createElementVNode(
+ "view",
+ {
+ class: vue.normalizeClass(["uni-table-text", { "empty-border": $props.border }])
+ },
+ vue.toDisplayString($props.emptyText),
+ 3
+ /* TEXT, CLASS */
+ )
+ ])) : vue.createCommentVNode("v-if", true),
+ $props.loading ? (vue.openBlock(), vue.createElementBlock(
+ "view",
+ {
+ key: 1,
+ class: vue.normalizeClass(["uni-table-mask", { "empty-border": $props.border }])
+ },
+ [
+ vue.createElementVNode("div", { class: "uni-table--loader" })
+ ],
+ 2
+ /* CLASS */
+ )) : vue.createCommentVNode("v-if", true)
+ ],
+ 6
+ /* CLASS, STYLE */
+ )
+ ],
+ 2
+ /* CLASS */
+ );
+ }
+ const __easycom_4 = /* @__PURE__ */ _export_sfc(_sfc_main$X, [["render", _sfc_render$s], ["__scopeId", "data-v-c1ea9b5d"], ["__file", "D:/zmj/uniapp/TraceabilityAPP/uni_modules/uni-table/components/uni-table/uni-table.vue"]]);
+ const _sfc_main$W = {
+ __name: "index",
+ props: {
+ dataList: Object,
+ tit: String,
+ route: String
+ },
+ setup(__props) {
+ const props2 = __props;
+ const tit_b = vue.ref(props2.tit);
+ const navgo = () => {
+ uni.navigateTo({
+ url: props2.route
+ });
+ };
+ const objFn = (obj) => {
+ for (const [key, value] of Object.entries(JSON.parse(obj))) {
+ return `${key}: ${value}`;
+ }
+ };
+ return (_ctx, _cache) => {
+ const _component_uni_th = resolveEasycom(vue.resolveDynamicComponent("uni-th"), __easycom_0$5);
+ const _component_uni_tr = resolveEasycom(vue.resolveDynamicComponent("uni-tr"), __easycom_1$7);
+ const _component_uni_td = resolveEasycom(vue.resolveDynamicComponent("uni-td"), __easycom_2$4);
+ const _component_u__image = resolveEasycom(vue.resolveDynamicComponent("u--image"), __easycom_0$6);
+ const _component_uni_table = resolveEasycom(vue.resolveDynamicComponent("uni-table"), __easycom_4);
+ return vue.openBlock(), vue.createElementBlock("view", { class: "card" }, [
+ vue.createVNode(_component_uni_table, {
+ border: "",
+ emptyText: "暂无更多数据",
+ width: "600rpx"
+ }, {
+ default: vue.withCtx(() => [
+ vue.createCommentVNode(" 表头行 "),
+ vue.createVNode(_component_uni_tr, null, {
+ default: vue.withCtx(() => [
+ vue.createVNode(_component_uni_th, {
+ width: "120rpx",
+ align: "center"
+ }, {
+ default: vue.withCtx(() => [
+ vue.createTextVNode("日期")
+ ]),
+ _: 1
+ /* STABLE */
+ }),
+ vue.createVNode(_component_uni_th, {
+ width: "200rpx",
+ align: "center"
+ }, {
+ default: vue.withCtx(() => [
+ vue.createTextVNode("操作")
+ ]),
+ _: 1
+ /* STABLE */
+ }),
+ vue.createVNode(_component_uni_th, {
+ width: "300.22rpx",
+ align: "center"
+ }, {
+ default: vue.withCtx(() => [
+ vue.createTextVNode("相关信息")
+ ]),
+ _: 1
+ /* STABLE */
+ })
+ ]),
+ _: 1
+ /* STABLE */
+ }),
+ vue.createCommentVNode(" 表格数据行 "),
+ (vue.openBlock(true), vue.createElementBlock(
+ vue.Fragment,
+ null,
+ vue.renderList(props2.dataList, (item, index2) => {
+ return vue.openBlock(), vue.createBlock(
+ _component_uni_tr,
+ { key: index2 },
+ {
+ default: vue.withCtx(() => [
+ vue.createCommentVNode(" {(item.create_time).slice(5,11)}} "),
+ vue.createVNode(_component_uni_td, null, {
+ default: vue.withCtx(() => [
+ vue.createTextVNode("5,11")
+ ]),
+ _: 1
+ /* STABLE */
+ }),
+ vue.createVNode(
+ _component_uni_td,
+ { style: { "text-align": "center" } },
+ {
+ default: vue.withCtx(() => [
+ vue.createTextVNode(
+ vue.toDisplayString(item.action_name),
+ 1
+ /* TEXT */
+ )
+ ]),
+ _: 2
+ /* DYNAMIC */
+ },
+ 1024
+ /* DYNAMIC_SLOTS */
+ ),
+ item.img ? (vue.openBlock(), vue.createBlock(_component_uni_td, { key: 0 }, {
+ default: vue.withCtx(() => [
+ vue.createVNode(_component_u__image, {
+ src: "/static/img/GJ.jpg",
+ width: "100%",
+ height: "210.28rpx",
+ alt: ""
+ })
+ ]),
+ _: 1
+ /* STABLE */
+ })) : (vue.openBlock(), vue.createBlock(
+ _component_uni_td,
+ { key: 1 },
+ {
+ default: vue.withCtx(() => [
+ vue.createTextVNode(
+ vue.toDisplayString(objFn(item.action_content)),
+ 1
+ /* TEXT */
+ )
+ ]),
+ _: 2
+ /* DYNAMIC */
+ },
+ 1024
+ /* DYNAMIC_SLOTS */
+ ))
+ ]),
+ _: 2
+ /* DYNAMIC */
+ },
+ 1024
+ /* DYNAMIC_SLOTS */
+ );
+ }),
+ 128
+ /* KEYED_FRAGMENT */
+ ))
+ ]),
+ _: 1
+ /* STABLE */
+ }),
+ vue.withDirectives(vue.createElementVNode(
+ "view",
+ {
+ class: "tit_b",
+ onClick: navgo
+ },
+ [
+ vue.createTextVNode(
+ vue.toDisplayString(tit_b.value) + " ",
+ 1
+ /* TEXT */
+ ),
+ vue.createVNode(_component_u__image, {
+ src: "/static/img/CKGD.png",
+ style: { "margin-left": "5rpx" },
+ width: "31.54rpx",
+ height: "31.54rpx"
+ })
+ ],
+ 512
+ /* NEED_PATCH */
+ ), [
+ [vue.vShow, tit_b.value]
+ ])
+ ]);
+ };
+ }
+ };
+ const myTable = /* @__PURE__ */ _export_sfc(_sfc_main$W, [["__scopeId", "data-v-90822214"], ["__file", "D:/zmj/uniapp/TraceabilityAPP/components/myTable/index.vue"]]);
+ const animalListAPI$1 = (data) => syhttp.get("/AnimalBreed/animalList", data);
+ const animalEnvDataAPI$1 = (data) => syhttp.get("/AnimalBreed/animalEnvData", data);
+ const addAnimalAPI = (data) => syhttp.post("/AnimalBreed/addAnimal", data);
+ const actionsAPI = (data) => syhttp.get("/user/actions", data);
+ const animalPicListAPI = (data) => syhttp.get("/AnimalBreed/animalPicList", data);
+ const addAnimalPicAPI = (data) => syhttp.post("/AnimalBreed/addAnimalPic", data);
+ const _sfc_main$V = {
+ __name: "cultivation",
+ props: {
+ userInfo: Object
+ },
+ setup(__props) {
+ const props2 = __props;
+ const userInfo = vue.reactive(props2.userInfo);
+ const data = vue.reactive([
+ {
+ tit: "环境温度",
+ icon: "WD",
+ dw: "℃",
+ cont: "hj_temp",
+ flag: false
+ },
+ {
+ tit: "环境湿度",
+ icon: "JYL",
+ dw: "%RH",
+ cont: "hj_humi"
+ },
+ {
+ tit: "氧气浓度",
+ icon: "FX",
+ cont: "o_content",
+ dw: "%"
+ },
+ {
+ tit: "二氧化碳含量",
+ icon: "FS",
+ dw: "mg/L",
+ cont: "c_content"
+ },
+ {
+ tit: "光照强度",
+ icon: "JYL",
+ dw: "lux",
+ cont: "light"
+ },
+ {
+ tit: "大气压强",
+ icon: "GZ",
+ dw: "hpa",
+ cont: "dqy"
+ },
+ {
+ tit: "有害气体",
+ icon: "EYHT",
+ cont: "yhqt"
+ }
+ ]);
+ const baseData = vue.reactive({});
+ const urlFn = (name) => {
+ return `/static/img/${name}.png`;
+ };
+ const navgo = (url2) => {
+ uni.navigateTo({
+ url: url2
+ });
+ };
+ const animalList = vue.reactive([]);
+ animalListAPI$1({
+ user_id: 307,
+ page_no: 1,
+ page_size: 3
+ }).then((res) => {
+ res.data.forEach((item) => {
+ animalList.push(item);
+ });
+ });
+ animalEnvDataAPI$1({
+ user_id: 307
+ }).then((res) => {
+ for (let key in res.data) {
+ baseData[key] = res.data[key];
+ }
+ });
+ const actionList = vue.reactive({});
+ actionsAPI({
+ type: 3
+ }).then((res) => {
+ for (let key in res.data) {
+ actionList[key] = res.data[key];
+ }
+ formatAppLog("log", "at components/index/cultivation.vue:250", actionList);
+ });
+ return (_ctx, _cache) => {
+ const _component_u__image = resolveEasycom(vue.resolveDynamicComponent("u--image"), __easycom_0$6);
+ return vue.openBlock(), vue.createElementBlock("view", { class: "content" }, [
+ vue.createElementVNode("view", { class: "card" }, [
+ vue.createElementVNode("view", { class: "tit" }, [
+ vue.createElementVNode(
+ "view",
+ { class: "" },
+ " 农户名称: " + vue.toDisplayString(userInfo.name),
+ 1
+ /* TEXT */
+ )
+ ]),
+ vue.createElementVNode("view", { class: "card-li" }, [
+ vue.createElementVNode("view", { class: "" }, " 种养殖类型: 养殖户 "),
+ vue.createElementVNode(
+ "view",
+ { class: "" },
+ " 养殖头数: " + vue.toDisplayString(userInfo.animal_detail.total_count) + "头 ",
+ 1
+ /* TEXT */
+ )
+ ]),
+ vue.createElementVNode("view", { class: "card-li" }, [
+ vue.createElementVNode(
+ "view",
+ { class: "" },
+ " 土地面积:" + vue.toDisplayString(userInfo.total_land_area) + "亩 ",
+ 1
+ /* TEXT */
+ ),
+ vue.createElementVNode(
+ "view",
+ { class: "" },
+ " 公: " + vue.toDisplayString(userInfo.animal_detail.male_count) + "头 ",
+ 1
+ /* TEXT */
+ )
+ ]),
+ vue.createElementVNode("view", { class: "card-li" }, [
+ vue.createElementVNode(
+ "view",
+ { class: "" },
+ " 养殖种类: " + vue.toDisplayString(userInfo.animal_detail.kind[0]) + "," + vue.toDisplayString(userInfo.animal_detail.kind[1]),
+ 1
+ /* TEXT */
+ ),
+ vue.createElementVNode(
+ "view",
+ { class: "" },
+ " 母: " + vue.toDisplayString(userInfo.animal_detail.maternal_count) + "头 ",
+ 1
+ /* TEXT */
+ )
+ ]),
+ vue.createElementVNode("view", { class: "card-li" }, [
+ vue.createElementVNode(
+ "view",
+ { class: "" },
+ " 具体种类: " + vue.toDisplayString(userInfo.animal_detail.breed[0]),
+ 1
+ /* TEXT */
+ )
+ ])
+ ]),
+ vue.createElementVNode("view", { class: "circumstance" }, [
+ vue.createElementVNode("view", { class: "card-tit" }, [
+ vue.createElementVNode("view", { class: "" }, " 养殖情况 ")
+ ]),
+ (vue.openBlock(true), vue.createElementBlock(
+ vue.Fragment,
+ null,
+ vue.renderList(animalList, (item, index2) => {
+ return vue.openBlock(), vue.createElementBlock("view", {
+ class: "card",
+ key: index2,
+ onClick: ($event) => navgo(`/pages/feedIng/feedDetail?id=${item.id}`)
+ }, [
+ vue.createElementVNode("view", { class: "tit" }, [
+ vue.createElementVNode(
+ "view",
+ { class: "" },
+ " 编号: " + vue.toDisplayString(item.animal_code),
+ 1
+ /* TEXT */
+ ),
+ item.animal_status == 1 ? (vue.openBlock(), vue.createElementBlock("view", {
+ key: 0,
+ class: "",
+ style: { "color": "#00A15E" }
+ }, " 健康 ")) : vue.createCommentVNode("v-if", true),
+ item.animal_status == 2 ? (vue.openBlock(), vue.createElementBlock("view", {
+ key: 1,
+ class: "",
+ style: { "color": "#FFD736" }
+ }, " 怀孕中 ")) : vue.createCommentVNode("v-if", true),
+ item.animal_status == 4 ? (vue.openBlock(), vue.createElementBlock("view", {
+ key: 2,
+ class: "",
+ style: { "color": "#3274F9" }
+ }, " 可出栏 ")) : vue.createCommentVNode("v-if", true),
+ item.animal_status == 3 ? (vue.openBlock(), vue.createElementBlock("view", {
+ key: 3,
+ class: "",
+ style: { "color": "#F84221" }
+ }, " 生病隔离中 ")) : vue.createCommentVNode("v-if", true)
+ ]),
+ vue.createElementVNode("view", { class: "card-li" }, [
+ vue.createElementVNode(
+ "view",
+ { class: "" },
+ " 养殖类型: " + vue.toDisplayString(item.animal_kind),
+ 1
+ /* TEXT */
+ ),
+ vue.createElementVNode(
+ "view",
+ { class: "" },
+ " 年龄: " + vue.toDisplayString(item.animal_age) + "年 ",
+ 1
+ /* TEXT */
+ ),
+ vue.createElementVNode(
+ "view",
+ { class: "" },
+ " 体重: " + vue.toDisplayString(item.animal_weight) + "kg ",
+ 1
+ /* TEXT */
+ )
+ ])
+ ], 8, ["onClick"]);
+ }),
+ 128
+ /* KEYED_FRAGMENT */
+ )),
+ vue.createElementVNode("view", {
+ class: "check",
+ onClick: _cache[0] || (_cache[0] = ($event) => navgo("/pages/feedIng/feedList"))
+ }, [
+ vue.createTextVNode(" 查看全部养殖动物"),
+ vue.createVNode(_component_u__image, {
+ src: "/static/img/CKGD.png",
+ style: { "margin-left": "5rpx" },
+ width: "31.54rpx",
+ height: "31.54rpx"
+ })
+ ])
+ ]),
+ (vue.openBlock(true), vue.createElementBlock(
+ vue.Fragment,
+ null,
+ vue.renderList(actionList, (item, index2) => {
+ return vue.openBlock(), vue.createElementBlock("view", {
+ class: "circumstance",
+ key: index2
+ }, [
+ vue.createCommentVNode(" {{item.action_record}} "),
+ vue.createElementVNode("view", { class: "card-tit" }, [
+ vue.createElementVNode(
+ "view",
+ { class: "" },
+ vue.toDisplayString(index2),
+ 1
+ /* TEXT */
+ ),
+ vue.createElementVNode(
+ "view",
+ {
+ class: "updata-btn",
+ onClick: _cache[1] || (_cache[1] = ($event) => navgo("/pages/growRecord/index"))
+ },
+ " 更新" + vue.toDisplayString(index2.slice(0, -2)),
+ 1
+ /* TEXT */
+ )
+ ]),
+ vue.createVNode(myTable, {
+ tit: `查看${index2.slice(0, -2)}`,
+ dataList: item.action_record,
+ route: "/pages/feedIng/allRecording"
+ }, null, 8, ["tit", "dataList"])
+ ]);
+ }),
+ 128
+ /* KEYED_FRAGMENT */
+ )),
+ vue.createCommentVNode(` \r
+ \r
+ \r
+ 消毒情况\r
+ \r
+ \r
+ 更新消毒情况\r
+ \r
+ \r
+ \r
+ `),
+ vue.createElementVNode("view", { class: "data" }, [
+ vue.createElementVNode("view", { class: "tit" }, [
+ vue.createElementVNode("view", {
+ class: "",
+ style: { "display": "flex", "justify-content": "space-between", "font-size": "29.79rpx" }
+ }, [
+ vue.createElementVNode("view", { class: "" }, " 环境监测数据 ")
+ ]),
+ vue.createElementVNode("view", { class: "tit-b" }, [
+ vue.createVNode(_component_u__image, {
+ src: urlFn("sj"),
+ style: { "margin": "0 5rpx" },
+ width: "28.04rpx",
+ height: "28.04rpx"
+ }, null, 8, ["src"]),
+ vue.createElementVNode("text", null, "刷新时间: 2022-3-3")
+ ])
+ ]),
+ vue.createElementVNode("view", { class: "data-cont" }, [
+ (vue.openBlock(true), vue.createElementBlock(
+ vue.Fragment,
+ null,
+ vue.renderList(data, (item, index2) => {
+ return vue.openBlock(), vue.createElementBlock("view", {
+ class: "data-cont-li center",
+ key: index2
+ }, [
+ vue.createElementVNode("view", { style: { "margin": "0 20rpx" } }, [
+ vue.createElementVNode("view", { class: "center" }, [
+ vue.createVNode(_component_u__image, {
+ src: urlFn(item.icon),
+ style: { "margin": "0 5rpx" },
+ width: "38.55rpx",
+ height: "38.54rpx"
+ }, null, 8, ["src"]),
+ vue.createTextVNode(
+ " " + vue.toDisplayString(item.tit),
+ 1
+ /* TEXT */
+ )
+ ]),
+ vue.createElementVNode("view", { class: "b-cls" }, [
+ vue.createElementVNode(
+ "view",
+ {
+ class: "",
+ style: vue.normalizeStyle({ color: item.flag ? "#0095FF" : "" })
+ },
+ [
+ vue.createElementVNode(
+ "text",
+ { style: { "font-size": "70.09rpx" } },
+ vue.toDisplayString(baseData[item.cont]),
+ 1
+ /* TEXT */
+ ),
+ vue.createTextVNode(
+ vue.toDisplayString(item.dw),
+ 1
+ /* TEXT */
+ )
+ ],
+ 4
+ /* STYLE */
+ ),
+ item.flag ? (vue.openBlock(), vue.createElementBlock("view", {
+ key: 0,
+ class: "",
+ style: { "display": "flex", "align-items": "center" }
+ }, [
+ vue.createVNode(_component_u__image, {
+ src: urlFn("D"),
+ style: { "margin": "0 5rpx" },
+ width: "31.54rpx",
+ height: "31.54rpx"
+ }, null, 8, ["src"]),
+ vue.createElementVNode("text", { style: { "color": "#0095FF" } }, "5")
+ ])) : vue.createCommentVNode("v-if", true)
+ ])
+ ])
+ ]);
+ }),
+ 128
+ /* KEYED_FRAGMENT */
+ ))
+ ])
+ ])
+ ]);
+ };
+ }
+ };
+ const cultivation = /* @__PURE__ */ _export_sfc(_sfc_main$V, [["__scopeId", "data-v-91fd8d70"], ["__file", "D:/zmj/uniapp/TraceabilityAPP/components/index/cultivation.vue"]]);
+ const _sfc_main$U = {
+ __name: "planting",
+ props: {
+ userInfo: Object
+ },
+ setup(__props) {
+ const props2 = __props;
+ const userInfo = vue.reactive(props2.userInfo);
+ vue.reactive([{
+ tit: "土地种植管理",
+ type: 1
+ }, {
+ tit: "土地种植管理",
+ type: 0
+ }, {
+ tit: "土地种植管理",
+ type: 2
+ }, {
+ tit: "土地种植管理",
+ type: 1
+ }, {
+ tit: "土地种植管理",
+ type: 0
+ }, {
+ tit: "土地种植管理",
+ type: 2
+ }, {
+ tit: "土地种植管理"
+ }, {
+ tit: "土地种植管理"
+ }, {
+ tit: "土地种植管理"
+ }, {
+ tit: "土地种植管理"
+ }]);
+ const navgo = (url2) => {
+ uni.navigateTo({
+ url: url2
+ });
+ };
+ const navgoFn = (type, id) => {
+ if (!type) {
+ navgo(`/pages/InformationAdd/index?land_id=${id}`);
+ } else if (type) {
+ navgo(`/pages/detail/plant?land_id=${id}`);
+ }
+ if (type == 2) {
+ navgo("/pages/detail/plant");
+ }
+ };
+ return (_ctx, _cache) => {
+ return vue.openBlock(), vue.createElementBlock("view", { class: "" }, [
+ vue.createElementVNode("view", { class: "content" }, [
+ vue.createElementVNode("view", { class: "border-bgc" }),
+ vue.createElementVNode("view", {
+ class: "",
+ style: { "height": "30rpx" }
+ }),
+ vue.createElementVNode("view", { class: "card" }, [
+ vue.createElementVNode(
+ "view",
+ { class: "card-li" },
+ " 农户名称: " + vue.toDisplayString(userInfo.name),
+ 1
+ /* TEXT */
+ ),
+ vue.createElementVNode("view", { class: "card-li" }, " 种养殖类型: 种植户 "),
+ vue.createElementVNode(
+ "view",
+ { class: "card-li" },
+ " 土地面积: " + vue.toDisplayString(userInfo.total_land_area) + "亩 ",
+ 1
+ /* TEXT */
+ ),
+ vue.createElementVNode(
+ "view",
+ { class: "card-li" },
+ " 地址: " + vue.toDisplayString(userInfo.area_name) + vue.toDisplayString(userInfo.street_name) + vue.toDisplayString(userInfo.village_name) + vue.toDisplayString(userInfo.brigade_name),
+ 1
+ /* TEXT */
+ )
+ ]),
+ (vue.openBlock(true), vue.createElementBlock(
+ vue.Fragment,
+ null,
+ vue.renderList(userInfo.land_detail, (item, index2) => {
+ return vue.openBlock(), vue.createElementBlock("view", {
+ class: "card",
+ key: index2,
+ onClick: ($event) => navgoFn(item.is_cropped, item.land_id)
+ }, [
+ vue.createElementVNode("view", { class: "tit card-li" }, [
+ vue.createElementVNode(
+ "view",
+ { class: "" },
+ vue.toDisplayString(item.land_notes),
+ 1
+ /* TEXT */
+ ),
+ item.is_cropped ? (vue.openBlock(), vue.createElementBlock("view", {
+ key: 0,
+ class: "",
+ style: { "color": "#00A15E" }
+ }, " 已种植 ")) : (vue.openBlock(), vue.createElementBlock("view", {
+ key: 1,
+ class: "",
+ style: { "color": "#00A15E" }
+ }, " 未种植 "))
+ ]),
+ vue.createElementVNode("view", { class: "card-li" }, [
+ vue.createElementVNode(
+ "view",
+ { class: "" },
+ " 面积: " + vue.toDisplayString(item.land_area) + "亩 ",
+ 1
+ /* TEXT */
+ )
+ ]),
+ item.crop_name ? (vue.openBlock(), vue.createElementBlock("view", {
+ key: 0,
+ class: "card-li tit"
+ }, [
+ vue.createElementVNode(
+ "view",
+ {
+ class: "",
+ style: { "font-weight": "normal" }
+ },
+ " 农作物: " + vue.toDisplayString(item.crop_name),
+ 1
+ /* TEXT */
+ ),
+ item.ripe_time ? (vue.openBlock(), vue.createElementBlock("view", {
+ key: 0,
+ class: "",
+ style: { "color": "#FF9B66" }
+ }, " 已成熟 ")) : vue.createCommentVNode("v-if", true)
+ ])) : vue.createCommentVNode("v-if", true),
+ vue.withDirectives(vue.createElementVNode(
+ "view",
+ {
+ class: "card-li tit",
+ style: { "font-weight": "normal" }
+ },
+ [
+ vue.createElementVNode(
+ "view",
+ { class: "" },
+ " 预计产量: " + vue.toDisplayString(item.crop_yield) + "kg ",
+ 1
+ /* TEXT */
+ ),
+ vue.createCommentVNode("v-if", true)
+ ],
+ 512
+ /* NEED_PATCH */
+ ), [
+ [vue.vShow, item.crop_yield]
+ ])
+ ], 8, ["onClick"]);
+ }),
+ 128
+ /* KEYED_FRAGMENT */
+ )),
+ vue.createElementVNode("view", { style: { "height": "170rpx" } })
+ ]),
+ vue.createElementVNode("view", { class: "bottom" }, [
+ vue.createElementVNode("view", {
+ class: "add-btn",
+ onClick: _cache[0] || (_cache[0] = ($event) => navgo("/pages/growRecord/index"))
+ }, " 批量处理 "),
+ vue.createCommentVNode(` \r
+ 增加种植\r
+ `)
+ ])
+ ]);
+ };
+ }
+ };
+ const planting = /* @__PURE__ */ _export_sfc(_sfc_main$U, [["__scopeId", "data-v-093aaff7"], ["__file", "D:/zmj/uniapp/TraceabilityAPP/components/index/planting.vue"]]);
+ const _sfc_main$T = {
+ __name: "fishing",
+ props: {
+ userInfo: Object
+ },
+ setup(__props) {
+ const props2 = __props;
+ const userInfo = vue.reactive(props2.userInfo);
+ const list = vue.reactive([{
+ tit: "土地种植管理",
+ type: 1
+ }, {
+ tit: "土地种植管理",
+ type: 0
+ }, {
+ tit: "土地种植管理",
+ type: 2
+ }, {
+ tit: "土地种植管理",
+ type: 1
+ }, {
+ tit: "土地种植管理",
+ type: 0
+ }, {
+ tit: "土地种植管理",
+ type: 2
+ }, {
+ tit: "土地种植管理"
+ }, {
+ tit: "土地种植管理"
+ }, {
+ tit: "土地种植管理"
+ }, {
+ tit: "土地种植管理"
+ }]);
+ const navgo = (url2) => {
+ uni.navigateTo({
+ url: url2
+ });
+ };
+ const navgoFn = (type) => {
+ if (type == 0) {
+ navgo("/pages/InformationAdd/index");
+ }
+ if (type == 1) {
+ navgo("/pages/detail/plant");
+ }
+ if (type == 2) {
+ navgo("/pages/detail/plant");
+ }
+ };
+ return (_ctx, _cache) => {
+ return vue.openBlock(), vue.createElementBlock("view", { class: "" }, [
+ vue.createElementVNode("view", { class: "content" }, [
+ vue.createElementVNode("view", { class: "border-bgc" }),
+ vue.createElementVNode("view", {
+ class: "",
+ style: { "height": "30rpx" }
+ }),
+ vue.createElementVNode("view", { class: "card" }, [
+ vue.createElementVNode(
+ "view",
+ { class: "card-li" },
+ " 农户名称: " + vue.toDisplayString(userInfo.name),
+ 1
+ /* TEXT */
+ ),
+ vue.createElementVNode("view", { class: "card-li" }, " 种养殖类型: 养殖户 "),
+ vue.createElementVNode("view", { class: "card-li" }, " 养殖种类: 鱼类 "),
+ vue.createElementVNode("view", { class: "card-li" }, " 土地面积: 00 "),
+ vue.createElementVNode("view", { class: "card-li" }, " 地址: 对话方式打开就会发生的空间和 ")
+ ]),
+ (vue.openBlock(true), vue.createElementBlock(
+ vue.Fragment,
+ null,
+ vue.renderList(list, (item, index2) => {
+ return vue.openBlock(), vue.createElementBlock("view", {
+ class: "card",
+ key: index2,
+ onClick: ($event) => navgoFn(item.type)
+ }, [
+ vue.createElementVNode("view", { class: "tit card-li" }, [
+ vue.createElementVNode("view", { class: "" }, " 池塘1 "),
+ item.type == 1 || item.type == 2 ? (vue.openBlock(), vue.createElementBlock("view", {
+ key: 0,
+ class: "",
+ style: { "color": "#00A15E" }
+ }, " 已养殖 ")) : vue.createCommentVNode("v-if", true),
+ item.type == 0 ? (vue.openBlock(), vue.createElementBlock("view", {
+ key: 1,
+ class: "",
+ style: { "color": "#00A15E" }
+ }, " 未养殖 ")) : vue.createCommentVNode("v-if", true)
+ ]),
+ vue.createElementVNode("view", { class: "card-li" }, [
+ vue.createElementVNode("view", { class: "" }, " 面积: 10亩 ")
+ ]),
+ vue.createElementVNode("view", { class: "card-li tit" }, [
+ vue.createElementVNode("view", {
+ class: "",
+ style: { "font-weight": "normal" }
+ }, " 养殖品种: 10亩 ")
+ ]),
+ vue.createElementVNode("view", {
+ class: "card-li tit",
+ style: { "font-weight": "normal" }
+ }, [
+ vue.createElementVNode("view", { class: "" }, " 养殖数量: 100kg ")
+ ])
+ ], 8, ["onClick"]);
+ }),
+ 128
+ /* KEYED_FRAGMENT */
+ )),
+ vue.createElementVNode("view", { style: { "height": "170rpx" } })
+ ]),
+ vue.createElementVNode("view", { class: "bottom" }, [
+ vue.createElementVNode("view", {
+ class: "add-btn",
+ onClick: _cache[0] || (_cache[0] = ($event) => navgo("/pages/growRecord/index"))
+ }, " 批量处理 "),
+ vue.createElementVNode("view", {
+ class: "add-btn add",
+ onClick: _cache[1] || (_cache[1] = ($event) => navgo("/pages/InformationAdd/index"))
+ }, " 增加种植 ")
+ ])
+ ]);
+ };
+ }
+ };
+ const fishing = /* @__PURE__ */ _export_sfc(_sfc_main$T, [["__scopeId", "data-v-bdc223d1"], ["__file", "D:/zmj/uniapp/TraceabilityAPP/components/index/fishing.vue"]]);
+ const animalListAPI = (data) => syhttp.get("/PoultryBreed/poultryList", data);
+ const animalEnvDataAPI = (data) => syhttp.get("/PoultryBreed/poultryEnvData", data);
+ const _sfc_main$S = {
+ __name: "chick",
+ props: {
+ userInfo: Object
+ },
+ setup(__props) {
+ const props2 = __props;
+ const userInfo = vue.reactive(props2.userInfo);
+ const data = vue.reactive([
+ {
+ tit: "环境温度",
+ icon: "WD",
+ dw: "℃",
+ cont: "hj_temp",
+ flag: false
+ },
+ {
+ tit: "环境湿度",
+ icon: "JYL",
+ dw: "%RH",
+ cont: "hj_humi"
+ },
+ {
+ tit: "氧气浓度",
+ icon: "FX",
+ cont: "o_content",
+ dw: "%"
+ },
+ {
+ tit: "二氧化碳含量",
+ icon: "FS",
+ dw: "mg/L",
+ cont: "c_content"
+ },
+ {
+ tit: "光照强度",
+ icon: "JYL",
+ dw: "lux",
+ cont: "light"
+ },
+ {
+ tit: "大气压强",
+ icon: "GZ",
+ dw: "hpa",
+ cont: "dqy"
+ },
+ {
+ tit: "有害气体",
+ icon: "EYHT",
+ cont: "yhqt"
+ }
+ ]);
+ const baseData = vue.reactive({});
+ const urlFn = (name) => {
+ return `/static/img/${name}.png`;
+ };
+ const navgo = (url2) => {
+ uni.navigateTo({
+ url: url2
+ });
+ };
+ const animalList = vue.reactive([]);
+ animalListAPI({
+ user_id: 307,
+ page_no: 1,
+ page_size: 3
+ }).then((res) => {
+ res.data.forEach((item) => {
+ animalList.push(item);
+ });
+ formatAppLog("log", "at components/index/chick.vue:235", animalList);
+ });
+ animalEnvDataAPI({
+ user_id: 307
+ }).then((res) => {
+ for (let key in res.data) {
+ baseData[key] = res.data[key];
+ }
+ });
+ const actionList = vue.reactive({});
+ return (_ctx, _cache) => {
+ const _component_u__image = resolveEasycom(vue.resolveDynamicComponent("u--image"), __easycom_0$6);
+ return vue.openBlock(), vue.createElementBlock("view", { class: "content" }, [
+ vue.createElementVNode("view", { class: "card" }, [
+ vue.createElementVNode("view", { class: "tit" }, [
+ vue.createElementVNode(
+ "view",
+ { class: "" },
+ " 农户名称: " + vue.toDisplayString(userInfo.name),
+ 1
+ /* TEXT */
+ )
+ ]),
+ vue.createElementVNode("view", { class: "card-li" }, [
+ vue.createElementVNode("view", { class: "" }, " 种养殖类型: 养殖户 "),
+ vue.createElementVNode(
+ "view",
+ { class: "" },
+ " 养殖头数: " + vue.toDisplayString(userInfo.poultry_detail.total_count) + "头 ",
+ 1
+ /* TEXT */
+ )
+ ]),
+ vue.createElementVNode("view", { class: "card-li" }, [
+ vue.createElementVNode(
+ "view",
+ { class: "" },
+ " 土地面积:" + vue.toDisplayString(userInfo.total_land_area) + "亩 ",
+ 1
+ /* TEXT */
+ ),
+ vue.createElementVNode(
+ "view",
+ { class: "" },
+ " 公: " + vue.toDisplayString(userInfo.poultry_detail.male_count) + "头 ",
+ 1
+ /* TEXT */
+ )
+ ]),
+ vue.createElementVNode("view", { class: "card-li" }, [
+ vue.createElementVNode(
+ "view",
+ { class: "" },
+ " 养殖种类: " + vue.toDisplayString(userInfo.poultry_detail.kind[0]) + "," + vue.toDisplayString(userInfo.poultry_detail.kind[1]),
+ 1
+ /* TEXT */
+ ),
+ vue.createElementVNode(
+ "view",
+ { class: "" },
+ " 母: " + vue.toDisplayString(userInfo.poultry_detail.maternal_count) + "头 ",
+ 1
+ /* TEXT */
+ )
+ ]),
+ vue.createElementVNode("view", { class: "card-li" }, [
+ vue.createElementVNode(
+ "view",
+ { class: "" },
+ " 具体种类: " + vue.toDisplayString(userInfo.poultry_detail.breed[0]),
+ 1
+ /* TEXT */
+ )
+ ])
+ ]),
+ vue.createElementVNode("view", { class: "circumstance" }, [
+ vue.createElementVNode("view", { class: "card-tit" }, [
+ vue.createElementVNode("view", { class: "" }, " 养殖情况 ")
+ ]),
+ (vue.openBlock(true), vue.createElementBlock(
+ vue.Fragment,
+ null,
+ vue.renderList(animalList, (item, index2) => {
+ return vue.openBlock(), vue.createElementBlock("view", {
+ class: "card",
+ key: index2,
+ onClick: ($event) => navgo(`/pages/poultry/feedDetail?id=${item.id}`)
+ }, [
+ vue.createElementVNode("view", { class: "tit" }, [
+ vue.createElementVNode(
+ "view",
+ { class: "" },
+ " 编号: " + vue.toDisplayString(item.code),
+ 1
+ /* TEXT */
+ ),
+ item.status == 1 ? (vue.openBlock(), vue.createElementBlock("view", {
+ key: 0,
+ class: "",
+ style: { "color": "#00A15E" }
+ }, " 健康 ")) : vue.createCommentVNode("v-if", true),
+ item.status == 2 ? (vue.openBlock(), vue.createElementBlock("view", {
+ key: 1,
+ class: "",
+ style: { "color": "#FFD736" }
+ }, " 产蛋期 ")) : vue.createCommentVNode("v-if", true),
+ item.status == 4 ? (vue.openBlock(), vue.createElementBlock("view", {
+ key: 2,
+ class: "",
+ style: { "color": "#3274F9" }
+ }, " 可出栏 ")) : vue.createCommentVNode("v-if", true),
+ item.status == 3 ? (vue.openBlock(), vue.createElementBlock("view", {
+ key: 3,
+ class: "",
+ style: { "color": "#F84221" }
+ }, " 生病隔离中 ")) : vue.createCommentVNode("v-if", true)
+ ]),
+ vue.createElementVNode("view", { class: "card-li" }, [
+ vue.createElementVNode(
+ "view",
+ { class: "" },
+ " 养殖类型: " + vue.toDisplayString(item.kind),
+ 1
+ /* TEXT */
+ ),
+ vue.createElementVNode(
+ "view",
+ { class: "" },
+ " 年龄: " + vue.toDisplayString(item.age) + "年 ",
+ 1
+ /* TEXT */
+ ),
+ vue.createElementVNode(
+ "view",
+ { class: "" },
+ " 体重: " + vue.toDisplayString(item.weight) + "kg ",
+ 1
+ /* TEXT */
+ )
+ ])
+ ], 8, ["onClick"]);
+ }),
+ 128
+ /* KEYED_FRAGMENT */
+ )),
+ vue.createElementVNode("view", {
+ class: "check",
+ onClick: _cache[0] || (_cache[0] = ($event) => navgo("/pages/poultry/feedList"))
+ }, [
+ vue.createTextVNode(" 查看全部养殖动物"),
+ vue.createVNode(_component_u__image, {
+ src: "/static/img/CKGD.png",
+ style: { "margin-left": "5rpx" },
+ width: "31.54rpx",
+ height: "31.54rpx"
+ })
+ ])
+ ]),
+ (vue.openBlock(true), vue.createElementBlock(
+ vue.Fragment,
+ null,
+ vue.renderList(actionList, (item, index2) => {
+ return vue.openBlock(), vue.createElementBlock("view", {
+ class: "circumstance",
+ key: index2
+ }, [
+ vue.createCommentVNode(" {{item.action_record}} "),
+ vue.createElementVNode("view", { class: "card-tit" }, [
+ vue.createElementVNode(
+ "view",
+ { class: "" },
+ vue.toDisplayString(index2),
+ 1
+ /* TEXT */
+ ),
+ vue.createElementVNode(
+ "view",
+ {
+ class: "updata-btn",
+ onClick: _cache[1] || (_cache[1] = ($event) => navgo("/pages/growRecord/index"))
+ },
+ " 更新" + vue.toDisplayString(index2.slice(0, -2)),
+ 1
+ /* TEXT */
+ )
+ ]),
+ vue.createVNode(myTable, {
+ tit: `查看${index2.slice(0, -2)}`,
+ dataList: item.action_record,
+ route: "/pages/poultry/allRecording"
+ }, null, 8, ["tit", "dataList"])
+ ]);
+ }),
+ 128
+ /* KEYED_FRAGMENT */
+ )),
+ vue.createCommentVNode(` \r
+ \r
+ \r
+ 消毒情况\r
+ \r
+ \r
+ 更新消毒情况\r
+ \r
+ \r
+ \r
+ `),
+ vue.createElementVNode("view", { class: "data" }, [
+ vue.createElementVNode("view", { class: "tit" }, [
+ vue.createElementVNode("view", {
+ class: "",
+ style: { "display": "flex", "justify-content": "space-between", "font-size": "29.79rpx" }
+ }, [
+ vue.createElementVNode("view", { class: "" }, " 环境监测数据 ")
+ ]),
+ vue.createElementVNode("view", { class: "tit-b" }, [
+ vue.createVNode(_component_u__image, {
+ src: urlFn("sj"),
+ style: { "margin": "0 5rpx" },
+ width: "28.04rpx",
+ height: "28.04rpx"
+ }, null, 8, ["src"]),
+ vue.createElementVNode("text", null, "刷新时间: 2022-3-3")
+ ])
+ ]),
+ vue.createElementVNode("view", { class: "data-cont" }, [
+ (vue.openBlock(true), vue.createElementBlock(
+ vue.Fragment,
+ null,
+ vue.renderList(data, (item, index2) => {
+ return vue.openBlock(), vue.createElementBlock("view", {
+ class: "data-cont-li center",
+ key: index2
+ }, [
+ vue.createElementVNode("view", { style: { "margin": "0 20rpx" } }, [
+ vue.createElementVNode("view", { class: "center" }, [
+ vue.createVNode(_component_u__image, {
+ src: urlFn(item.icon),
+ style: { "margin": "0 5rpx" },
+ width: "38.55rpx",
+ height: "38.54rpx"
+ }, null, 8, ["src"]),
+ vue.createTextVNode(
+ " " + vue.toDisplayString(item.tit),
+ 1
+ /* TEXT */
+ )
+ ]),
+ vue.createElementVNode("view", { class: "b-cls" }, [
+ vue.createElementVNode(
+ "view",
+ {
+ class: "",
+ style: vue.normalizeStyle({ color: item.flag ? "#0095FF" : "" })
+ },
+ [
+ vue.createElementVNode(
+ "text",
+ { style: { "font-size": "70.09rpx" } },
+ vue.toDisplayString(baseData[item.cont]),
+ 1
+ /* TEXT */
+ ),
+ vue.createTextVNode(
+ vue.toDisplayString(item.dw),
+ 1
+ /* TEXT */
+ )
+ ],
+ 4
+ /* STYLE */
+ ),
+ item.flag ? (vue.openBlock(), vue.createElementBlock("view", {
+ key: 0,
+ class: "",
+ style: { "display": "flex", "align-items": "center" }
+ }, [
+ vue.createVNode(_component_u__image, {
+ src: urlFn("D"),
+ style: { "margin": "0 5rpx" },
+ width: "31.54rpx",
+ height: "31.54rpx"
+ }, null, 8, ["src"]),
+ vue.createElementVNode("text", { style: { "color": "#0095FF" } }, "5")
+ ])) : vue.createCommentVNode("v-if", true)
+ ])
+ ])
+ ]);
+ }),
+ 128
+ /* KEYED_FRAGMENT */
+ ))
+ ])
+ ])
+ ]);
+ };
+ }
+ };
+ const chick = /* @__PURE__ */ _export_sfc(_sfc_main$S, [["__scopeId", "data-v-c4e0dba5"], ["__file", "D:/zmj/uniapp/TraceabilityAPP/components/index/chick.vue"]]);
+ const _sfc_main$R = {
+ __name: "index",
+ setup(__props) {
+ const flag2 = vue.ref(1);
+ const scollChangeFn = (index2) => {
+ flag2.value = index2;
+ };
+ const list = vue.reactive([]);
+ const userInfo = vue.reactive({});
+ const initUserinfoFn = () => {
+ userInfoAPI({
+ user_id: 307
+ }).then((res) => {
+ for (const key in res.data) {
+ userInfo[key] = res.data[key];
+ if (key == "land_detail") {
+ list.push({
+ tit: "土地种植管理",
+ id: 1
+ });
+ } else if (key == "animal_detail") {
+ list.push({
+ tit: "家畜养殖管理",
+ id: 2
+ });
+ } else if (key == "poultry_detail") {
+ list.push({
+ tit: "家禽养殖管理",
+ id: 3
+ });
+ } else if (key == "pond_detail") {
+ list.push({
+ tit: "水产养殖管理",
+ id: 4
+ });
+ }
+ }
+ list.sort(function(a2, b2) {
+ return a2.id - b2.id;
+ });
+ });
+ };
+ initUserinfoFn();
+ return (_ctx, _cache) => {
+ const _component_u__image = resolveEasycom(vue.resolveDynamicComponent("u--image"), __easycom_0$6);
+ return vue.openBlock(), vue.createElementBlock("view", { class: "" }, [
+ vue.createElementVNode("view", { class: "tabbar" }, [
+ vue.createElementVNode("view", {
+ class: "",
+ style: { "padding-top": "var(--status-bar-height)" }
+ }),
+ vue.createElementVNode("view", {
+ class: "",
+ style: { "display": "flex" }
+ }, [
+ vue.createVNode(_component_u__image, {
+ src: "/static/img/FH.png",
+ width: "50.82rpx",
+ height: "50.82rpx",
+ alt: ""
+ }),
+ vue.createElementVNode("view", { class: "scoll-list" }, [
+ (vue.openBlock(true), vue.createElementBlock(
+ vue.Fragment,
+ null,
+ vue.renderList(list, (item, index2) => {
+ return vue.openBlock(), vue.createElementBlock("view", {
+ key: index2,
+ class: "scoll-list-li",
+ style: vue.normalizeStyle({ color: flag2.value == item.id ? "white" : "" }),
+ onClick: ($event) => scollChangeFn(item.id)
+ }, vue.toDisplayString(item.tit), 13, ["onClick"]);
+ }),
+ 128
+ /* KEYED_FRAGMENT */
+ ))
+ ])
+ ])
+ ]),
+ vue.createElementVNode("view", { style: { "background-color": "#34D190" } }, [
+ vue.createElementVNode("view", {
+ class: "",
+ style: { "padding-top": "var(--status-bar-height)" }
+ }),
+ vue.createElementVNode("view", {
+ class: "",
+ style: { "height": "100rpx" }
+ })
+ ]),
+ vue.createCommentVNode(" 种植户首页 "),
+ flag2.value == 1 ? (vue.openBlock(), vue.createBlock(planting, {
+ key: 0,
+ userInfo
+ }, null, 8, ["userInfo"])) : vue.createCommentVNode("v-if", true),
+ vue.createCommentVNode(" 养猪的 "),
+ flag2.value == 2 ? (vue.openBlock(), vue.createBlock(cultivation, {
+ key: 1,
+ userInfo
+ }, null, 8, ["userInfo"])) : vue.createCommentVNode("v-if", true),
+ vue.createCommentVNode(" 养鸡的 "),
+ flag2.value == 3 ? (vue.openBlock(), vue.createBlock(chick, {
+ key: 2,
+ userInfo
+ }, null, 8, ["userInfo"])) : vue.createCommentVNode("v-if", true),
+ vue.createCommentVNode(" 卖鱼的首页 "),
+ flag2.value == 4 ? (vue.openBlock(), vue.createBlock(fishing, {
+ key: 3,
+ userInfo
+ }, null, 8, ["userInfo"])) : vue.createCommentVNode("v-if", true)
+ ]);
+ };
+ }
+ };
+ const PagesIndexIndex = /* @__PURE__ */ _export_sfc(_sfc_main$R, [["__file", "D:/zmj/uniapp/TraceabilityAPP/pages/index/index.vue"]]);
+ const props$e = {
+ props: {
+ // 绑定的值
+ modelValue: {
+ type: [String, Number],
+ default: props$i.input.value
+ },
+ // number-数字输入键盘,app-vue下可以输入浮点数,app-nvue和小程序平台下只能输入整数
+ // idcard-身份证输入键盘,微信、支付宝、百度、QQ小程序
+ // digit-带小数点的数字键盘,App的nvue页面、微信、支付宝、百度、头条、QQ小程序
+ // text-文本输入键盘
+ type: {
+ type: String,
+ default: props$i.input.type
+ },
+ // 如果 textarea 是在一个 position:fixed 的区域,需要显示指定属性 fixed 为 true,
+ // 兼容性:微信小程序、百度小程序、字节跳动小程序、QQ小程序
+ fixed: {
+ type: Boolean,
+ default: props$i.input.fixed
+ },
+ // 是否禁用输入框
+ disabled: {
+ type: Boolean,
+ default: props$i.input.disabled
+ },
+ // 禁用状态时的背景色
+ disabledColor: {
+ type: String,
+ default: props$i.input.disabledColor
+ },
+ // 是否显示清除控件
+ clearable: {
+ type: Boolean,
+ default: props$i.input.clearable
+ },
+ // 是否密码类型
+ password: {
+ type: Boolean,
+ default: props$i.input.password
+ },
+ // 最大输入长度,设置为 -1 的时候不限制最大长度
+ maxlength: {
+ type: [String, Number],
+ default: props$i.input.maxlength
+ },
+ // 输入框为空时的占位符
+ placeholder: {
+ type: String,
+ default: props$i.input.placeholder
+ },
+ // 指定placeholder的样式类,注意页面或组件的style中写了scoped时,需要在类名前写/deep/
+ placeholderClass: {
+ type: String,
+ default: props$i.input.placeholderClass
+ },
+ // 指定placeholder的样式
+ placeholderStyle: {
+ type: [String, Object],
+ default: props$i.input.placeholderStyle
+ },
+ // 是否显示输入字数统计,只在 type ="text"或type ="textarea"时有效
+ showWordLimit: {
+ type: Boolean,
+ default: props$i.input.showWordLimit
+ },
+ // 设置右下角按钮的文字,有效值:send|search|next|go|done,兼容性详见uni-app文档
+ // https://uniapp.dcloud.io/component/input
+ // https://uniapp.dcloud.io/component/textarea
+ confirmType: {
+ type: String,
+ default: props$i.input.confirmType
+ },
+ // 点击键盘右下角按钮时是否保持键盘不收起,H5无效
+ confirmHold: {
+ type: Boolean,
+ default: props$i.input.confirmHold
+ },
+ // focus时,点击页面的时候不收起键盘,微信小程序有效
+ holdKeyboard: {
+ type: Boolean,
+ default: props$i.input.holdKeyboard
+ },
+ // 自动获取焦点
+ // 在 H5 平台能否聚焦以及软键盘是否跟随弹出,取决于当前浏览器本身的实现。nvue 页面不支持,需使用组件的 focus()、blur() 方法控制焦点
+ focus: {
+ type: Boolean,
+ default: props$i.input.focus
+ },
+ // 键盘收起时,是否自动失去焦点,目前仅App3.0.0+有效
+ autoBlur: {
+ type: Boolean,
+ default: props$i.input.autoBlur
+ },
+ // 是否去掉 iOS 下的默认内边距,仅微信小程序,且type=textarea时有效
+ disableDefaultPadding: {
+ type: Boolean,
+ default: props$i.input.disableDefaultPadding
+ },
+ // 指定focus时光标的位置
+ cursor: {
+ type: [String, Number],
+ default: props$i.input.cursor
+ },
+ // 输入框聚焦时底部与键盘的距离
+ cursorSpacing: {
+ type: [String, Number],
+ default: props$i.input.cursorSpacing
+ },
+ // 光标起始位置,自动聚集时有效,需与selection-end搭配使用
+ selectionStart: {
+ type: [String, Number],
+ default: props$i.input.selectionStart
+ },
+ // 光标结束位置,自动聚集时有效,需与selection-start搭配使用
+ selectionEnd: {
+ type: [String, Number],
+ default: props$i.input.selectionEnd
+ },
+ // 键盘弹起时,是否自动上推页面
+ adjustPosition: {
+ type: Boolean,
+ default: props$i.input.adjustPosition
+ },
+ // 输入框内容对齐方式,可选值为:left|center|right
+ inputAlign: {
+ type: String,
+ default: props$i.input.inputAlign
+ },
+ // 输入框字体的大小
+ fontSize: {
+ type: [String, Number],
+ default: props$i.input.fontSize
+ },
+ // 输入框字体颜色
+ color: {
+ type: String,
+ default: props$i.input.color
+ },
+ // 输入框前置图标
+ prefixIcon: {
+ type: String,
+ default: props$i.input.prefixIcon
+ },
+ // 前置图标样式,对象或字符串
+ prefixIconStyle: {
+ type: [String, Object],
+ default: props$i.input.prefixIconStyle
+ },
+ // 输入框后置图标
+ suffixIcon: {
+ type: String,
+ default: props$i.input.suffixIcon
+ },
+ // 后置图标样式,对象或字符串
+ suffixIconStyle: {
+ type: [String, Object],
+ default: props$i.input.suffixIconStyle
+ },
+ // 边框类型,surround-四周边框,bottom-底部边框,none-无边框
+ border: {
+ type: String,
+ default: props$i.input.border
+ },
+ // 是否只读,与disabled不同之处在于disabled会置灰组件,而readonly则不会
+ readonly: {
+ type: Boolean,
+ default: props$i.input.readonly
+ },
+ // 输入框形状,circle-圆形,square-方形
+ shape: {
+ type: String,
+ default: props$i.input.shape
+ },
+ // 用于处理或者过滤输入框内容的方法
+ formatter: {
+ type: [Function, null],
+ default: props$i.input.formatter
+ },
+ // 是否忽略组件内对文本合成系统事件的处理
+ ignoreCompositionEvent: {
+ type: Boolean,
+ default: true
+ }
+ }
+ };
+ const _sfc_main$Q = {
+ name: "u-input",
+ mixins: [mpMixin, mixin, props$e],
+ data() {
+ return {
+ // 输入框的值
+ innerValue: "",
+ // 是否处于获得焦点状态
+ focused: false,
+ // value是否第一次变化,在watch中,由于加入immediate属性,会在第一次触发,此时不应该认为value发生了变化
+ firstChange: true,
+ // value绑定值的变化是由内部还是外部引起的
+ changeFromInner: false,
+ // 过滤处理方法
+ innerFormatter: (value) => value
+ };
+ },
+ watch: {
+ modelValue: {
+ immediate: true,
+ handler(newVal, oldVal) {
+ this.innerValue = newVal;
+ this.firstChange = false;
+ this.changeFromInner = false;
+ }
+ }
+ },
+ computed: {
+ // 是否显示清除控件
+ isShowClear() {
+ const { clearable, readonly, focused, innerValue } = this;
+ return !!clearable && !readonly && !!focused && innerValue !== "";
+ },
+ // 组件的类名
+ inputClass() {
+ let classes = [], { border, disabled, shape } = this;
+ border === "surround" && (classes = classes.concat(["u-border", "u-input--radius"]));
+ classes.push(`u-input--${shape}`);
+ border === "bottom" && (classes = classes.concat([
+ "u-border-bottom",
+ "u-input--no-radius"
+ ]));
+ return classes.join(" ");
+ },
+ // 组件的样式
+ wrapperStyle() {
+ const style = {};
+ if (this.disabled) {
+ style.backgroundColor = this.disabledColor;
+ }
+ if (this.border === "none") {
+ style.padding = "0";
+ } else {
+ style.paddingTop = "6px";
+ style.paddingBottom = "6px";
+ style.paddingLeft = "9px";
+ style.paddingRight = "9px";
+ }
+ return uni.$u.deepMerge(style, uni.$u.addStyle(this.customStyle));
+ },
+ // 输入框的样式
+ inputStyle() {
+ const style = {
+ color: this.color,
+ fontSize: uni.$u.addUnit(this.fontSize),
+ textAlign: this.inputAlign
+ };
+ return style;
+ }
+ },
+ emits: ["update:modelValue", "focus", "blur", "change", "confirm", "clear", "keyboardheightchange"],
+ methods: {
+ // 在微信小程序中,不支持将函数当做props参数,故只能通过ref形式调用
+ setFormatter(e) {
+ this.innerFormatter = e;
+ },
+ // 当键盘输入时,触发input事件
+ onInput(e) {
+ let { value = "" } = e.detail || {};
+ const formatter = this.formatter || this.innerFormatter;
+ const formatValue = formatter(value);
+ this.innerValue = value;
+ this.$nextTick(() => {
+ this.innerValue = formatValue;
+ this.valueChange();
+ });
+ },
+ // 输入框失去焦点时触发
+ onBlur(event) {
+ this.$emit("blur", event.detail.value);
+ uni.$u.sleep(50).then(() => {
+ this.focused = false;
+ });
+ uni.$u.formValidate(this, "blur");
+ },
+ // 输入框聚焦时触发
+ onFocus(event) {
+ this.focused = true;
+ this.$emit("focus");
+ },
+ // 点击完成按钮时触发
+ onConfirm(event) {
+ this.$emit("confirm", this.innerValue);
+ },
+ // 键盘高度发生变化的时候触发此事件
+ // 兼容性:微信小程序2.7.0+、App 3.1.0+
+ onkeyboardheightchange(event) {
+ this.$emit("keyboardheightchange", event);
+ },
+ // 内容发生变化,进行处理
+ valueChange() {
+ const value = this.innerValue;
+ this.$nextTick(() => {
+ this.$emit("update:modelValue", value);
+ this.changeFromInner = true;
+ this.$emit("change", value);
+ uni.$u.formValidate(this, "change");
+ });
+ },
+ // 点击清除控件
+ onClear() {
+ this.innerValue = "";
+ this.$nextTick(() => {
+ this.valueChange();
+ this.$emit("clear");
+ });
+ },
+ /**
+ * 在安卓nvue上,事件无法冒泡
+ * 在某些时间,我们希望监听u-from-item的点击事件,此时会导致点击u-form-item内的u-input后
+ * 无法触发u-form-item的点击事件,这里通过手动调用u-form-item的方法进行触发
+ */
+ clickHandler() {
+ }
+ }
+ };
+ function _sfc_render$r(_ctx, _cache, $props, $setup, $data, $options) {
+ const _component_u_icon = resolveEasycom(vue.resolveDynamicComponent("u-icon"), __easycom_0$7);
+ return vue.openBlock(), vue.createElementBlock(
+ "view",
+ {
+ class: vue.normalizeClass(["u-input", $options.inputClass]),
+ style: vue.normalizeStyle([$options.wrapperStyle])
+ },
+ [
+ vue.createElementVNode("view", { class: "u-input__content" }, [
+ _ctx.prefixIcon || _ctx.$slots.prefix ? (vue.openBlock(), vue.createElementBlock("view", {
+ key: 0,
+ class: "u-input__content__prefix-icon"
+ }, [
+ vue.renderSlot(_ctx.$slots, "prefix", {}, () => [
+ vue.createVNode(_component_u_icon, {
+ name: _ctx.prefixIcon,
+ size: "18",
+ customStyle: _ctx.prefixIconStyle
+ }, null, 8, ["name", "customStyle"])
+ ], true)
+ ])) : vue.createCommentVNode("v-if", true),
+ vue.createElementVNode("view", {
+ class: "u-input__content__field-wrapper",
+ onClick: _cache[5] || (_cache[5] = (...args) => $options.clickHandler && $options.clickHandler(...args))
+ }, [
+ vue.createCommentVNode(" 根据uni-app的input组件文档,H5和APP中只要声明了password参数(无论true还是false),type均失效,此时\n 为了防止type=number时,又存在password属性,type无效,此时需要设置password为undefined\n "),
+ vue.createElementVNode("input", {
+ class: "u-input__content__field-wrapper__field",
+ style: vue.normalizeStyle([$options.inputStyle]),
+ type: _ctx.type,
+ focus: _ctx.focus,
+ cursor: _ctx.cursor,
+ value: $data.innerValue,
+ "auto-blur": _ctx.autoBlur,
+ disabled: _ctx.disabled || _ctx.readonly,
+ maxlength: _ctx.maxlength,
+ placeholder: _ctx.placeholder,
+ "placeholder-style": _ctx.placeholderStyle,
+ "placeholder-class": _ctx.placeholderClass,
+ "confirm-type": _ctx.confirmType,
+ "confirm-hold": _ctx.confirmHold,
+ "hold-keyboard": _ctx.holdKeyboard,
+ "cursor-spacing": _ctx.cursorSpacing,
+ "adjust-position": _ctx.adjustPosition,
+ "selection-end": _ctx.selectionEnd,
+ "selection-start": _ctx.selectionStart,
+ password: _ctx.password || _ctx.type === "password" || void 0,
+ ignoreCompositionEvent: _ctx.ignoreCompositionEvent,
+ onInput: _cache[0] || (_cache[0] = (...args) => $options.onInput && $options.onInput(...args)),
+ onBlur: _cache[1] || (_cache[1] = (...args) => $options.onBlur && $options.onBlur(...args)),
+ onFocus: _cache[2] || (_cache[2] = (...args) => $options.onFocus && $options.onFocus(...args)),
+ onConfirm: _cache[3] || (_cache[3] = (...args) => $options.onConfirm && $options.onConfirm(...args)),
+ onKeyboardheightchange: _cache[4] || (_cache[4] = (...args) => $options.onkeyboardheightchange && $options.onkeyboardheightchange(...args))
+ }, null, 44, ["type", "focus", "cursor", "value", "auto-blur", "disabled", "maxlength", "placeholder", "placeholder-style", "placeholder-class", "confirm-type", "confirm-hold", "hold-keyboard", "cursor-spacing", "adjust-position", "selection-end", "selection-start", "password", "ignoreCompositionEvent"])
+ ]),
+ $options.isShowClear ? (vue.openBlock(), vue.createElementBlock("view", {
+ key: 1,
+ class: "u-input__content__clear",
+ onClick: _cache[6] || (_cache[6] = (...args) => $options.onClear && $options.onClear(...args))
+ }, [
+ vue.createVNode(_component_u_icon, {
+ name: "close",
+ size: "11",
+ color: "#ffffff",
+ customStyle: "line-height: 12px"
+ })
+ ])) : vue.createCommentVNode("v-if", true),
+ _ctx.suffixIcon || _ctx.$slots.suffix ? (vue.openBlock(), vue.createElementBlock("view", {
+ key: 2,
+ class: "u-input__content__subfix-icon"
+ }, [
+ vue.renderSlot(_ctx.$slots, "suffix", {}, () => [
+ vue.createVNode(_component_u_icon, {
+ name: _ctx.suffixIcon,
+ size: "18",
+ customStyle: _ctx.suffixIconStyle
+ }, null, 8, ["name", "customStyle"])
+ ], true)
+ ])) : vue.createCommentVNode("v-if", true)
+ ])
+ ],
+ 6
+ /* CLASS, STYLE */
+ );
+ }
+ const __easycom_1$6 = /* @__PURE__ */ _export_sfc(_sfc_main$Q, [["render", _sfc_render$r], ["__scopeId", "data-v-5904192e"], ["__file", "D:/zmj/uniapp/TraceabilityAPP/node_modules/uview-plus/components/u-input/u-input.vue"]]);
+ const props$d = {
+ props: {
+ // 是否显示组件
+ show: {
+ type: Boolean,
+ default: props$i.loadingIcon.show
+ },
+ // 颜色
+ color: {
+ type: String,
+ default: props$i.loadingIcon.color
+ },
+ // 提示文字颜色
+ textColor: {
+ type: String,
+ default: props$i.loadingIcon.textColor
+ },
+ // 文字和图标是否垂直排列
+ vertical: {
+ type: Boolean,
+ default: props$i.loadingIcon.vertical
+ },
+ // 模式选择,circle-圆形,spinner-花朵形,semicircle-半圆形
+ mode: {
+ type: String,
+ default: props$i.loadingIcon.mode
+ },
+ // 图标大小,单位默认px
+ size: {
+ type: [String, Number],
+ default: props$i.loadingIcon.size
+ },
+ // 文字大小
+ textSize: {
+ type: [String, Number],
+ default: props$i.loadingIcon.textSize
+ },
+ // 文字内容
+ text: {
+ type: [String, Number],
+ default: props$i.loadingIcon.text
+ },
+ // 动画模式
+ timingFunction: {
+ type: String,
+ default: props$i.loadingIcon.timingFunction
+ },
+ // 动画执行周期时间
+ duration: {
+ type: [String, Number],
+ default: props$i.loadingIcon.duration
+ },
+ // mode=circle时的暗边颜色
+ inactiveColor: {
+ type: String,
+ default: props$i.loadingIcon.inactiveColor
+ }
+ }
+ };
+ const _sfc_main$P = {
+ name: "u-loading-icon",
+ mixins: [mpMixin, mixin, props$d],
+ data() {
+ return {
+ // Array.form可以通过一个伪数组对象创建指定长度的数组
+ // https://developer.mozilla.org/zh-CN/docs/Web/JavaScript/Reference/Global_Objects/Array/from
+ array12: Array.from({
+ length: 12
+ }),
+ // 这里需要设置默认值为360,否则在安卓nvue上,会延迟一个duration周期后才执行
+ // 在iOS nvue上,则会一开始默认执行两个周期的动画
+ aniAngel: 360,
+ // 动画旋转角度
+ webviewHide: false,
+ // 监听webview的状态,如果隐藏了页面,则停止动画,以免性能消耗
+ loading: false
+ // 是否运行中,针对nvue使用
+ };
+ },
+ computed: {
+ // 当为circle类型时,给其另外三边设置一个更轻一些的颜色
+ // 之所以需要这么做的原因是,比如父组件传了color为红色,那么需要另外的三个边为浅红色
+ // 而不能是固定的某一个其他颜色(因为这个固定的颜色可能浅蓝,导致效果没有那么细腻良好)
+ otherBorderColor() {
+ const lightColor = uni.$u.colorGradient(this.color, "#ffffff", 100)[80];
+ if (this.mode === "circle") {
+ return this.inactiveColor ? this.inactiveColor : lightColor;
+ } else {
+ return "transparent";
+ }
+ }
+ },
+ watch: {
+ show(n2) {
+ }
+ },
+ mounted() {
+ this.init();
+ },
+ methods: {
+ init() {
+ setTimeout(() => {
+ this.show && this.addEventListenerToWebview();
+ }, 20);
+ },
+ // 监听webview的显示与隐藏
+ addEventListenerToWebview() {
+ const pages2 = getCurrentPages();
+ const page2 = pages2[pages2.length - 1];
+ const currentWebview = page2.$getAppWebview();
+ currentWebview.addEventListener("hide", () => {
+ this.webviewHide = true;
+ });
+ currentWebview.addEventListener("show", () => {
+ this.webviewHide = false;
+ });
+ }
+ }
+ };
+ function _sfc_render$q(_ctx, _cache, $props, $setup, $data, $options) {
+ return _ctx.show ? (vue.openBlock(), vue.createElementBlock(
+ "view",
+ {
+ key: 0,
+ class: vue.normalizeClass(["u-loading-icon", [_ctx.vertical && "u-loading-icon--vertical"]]),
+ style: vue.normalizeStyle([_ctx.$u.addStyle(_ctx.customStyle)])
+ },
+ [
+ !$data.webviewHide ? (vue.openBlock(), vue.createElementBlock(
+ "view",
+ {
+ key: 0,
+ class: vue.normalizeClass(["u-loading-icon__spinner", [`u-loading-icon__spinner--${_ctx.mode}`]]),
+ ref: "ani",
+ style: vue.normalizeStyle({
+ color: _ctx.color,
+ width: _ctx.$u.addUnit(_ctx.size),
+ height: _ctx.$u.addUnit(_ctx.size),
+ borderTopColor: _ctx.color,
+ borderBottomColor: $options.otherBorderColor,
+ borderLeftColor: $options.otherBorderColor,
+ borderRightColor: $options.otherBorderColor,
+ "animation-duration": `${_ctx.duration}ms`,
+ "animation-timing-function": _ctx.mode === "semicircle" || _ctx.mode === "circle" ? _ctx.timingFunction : ""
+ })
+ },
+ [
+ _ctx.mode === "spinner" ? (vue.openBlock(true), vue.createElementBlock(
+ vue.Fragment,
+ { key: 0 },
+ vue.renderList($data.array12, (item, index2) => {
+ return vue.openBlock(), vue.createElementBlock("view", {
+ key: index2,
+ class: "u-loading-icon__dot"
+ });
+ }),
+ 128
+ /* KEYED_FRAGMENT */
+ )) : vue.createCommentVNode("v-if", true)
+ ],
+ 6
+ /* CLASS, STYLE */
+ )) : vue.createCommentVNode("v-if", true),
+ _ctx.text ? (vue.openBlock(), vue.createElementBlock(
+ "text",
+ {
+ key: 1,
+ class: "u-loading-icon__text",
+ style: vue.normalizeStyle({
+ fontSize: _ctx.$u.addUnit(_ctx.textSize),
+ color: _ctx.textColor
+ })
+ },
+ vue.toDisplayString(_ctx.text),
+ 5
+ /* TEXT, STYLE */
+ )) : vue.createCommentVNode("v-if", true)
+ ],
+ 6
+ /* CLASS, STYLE */
+ )) : vue.createCommentVNode("v-if", true);
+ }
+ const __easycom_1$5 = /* @__PURE__ */ _export_sfc(_sfc_main$P, [["render", _sfc_render$q], ["__scopeId", "data-v-00752c6d"], ["__file", "D:/zmj/uniapp/TraceabilityAPP/node_modules/uview-plus/components/u-loading-icon/u-loading-icon.vue"]]);
+ const props$c = {
+ props: {
+ // 是否细边框
+ hairline: {
+ type: Boolean,
+ default: props$i.button.hairline
+ },
+ // 按钮的预置样式,info,primary,error,warning,success
+ type: {
+ type: String,
+ default: props$i.button.type
+ },
+ // 按钮尺寸,large,normal,small,mini
+ size: {
+ type: String,
+ default: props$i.button.size
+ },
+ // 按钮形状,circle(两边为半圆),square(带圆角)
+ shape: {
+ type: String,
+ default: props$i.button.shape
+ },
+ // 按钮是否镂空
+ plain: {
+ type: Boolean,
+ default: props$i.button.plain
+ },
+ // 是否禁止状态
+ disabled: {
+ type: Boolean,
+ default: props$i.button.disabled
+ },
+ // 是否加载中
+ loading: {
+ type: Boolean,
+ default: props$i.button.loading
+ },
+ // 加载中提示文字
+ loadingText: {
+ type: [String, Number],
+ default: props$i.button.loadingText
+ },
+ // 加载状态图标类型
+ loadingMode: {
+ type: String,
+ default: props$i.button.loadingMode
+ },
+ // 加载图标大小
+ loadingSize: {
+ type: [String, Number],
+ default: props$i.button.loadingSize
+ },
+ // 开放能力,具体请看uniapp稳定关于button组件部分说明
+ // https://uniapp.dcloud.io/component/button
+ openType: {
+ type: String,
+ default: props$i.button.openType
+ },
+ // 用于