From c52075e3b953413246c4af5c0e76e481294c59c2 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?=E5=B0=8F=E4=B9=85=E5=93=A5?= <787952492@qq.com>
Date: Thu, 16 Jun 2022 16:01:34 +0800
Subject: [PATCH] =?UTF-8?q?=E9=A1=B5=E9=9D=A2=E4=BC=98=E5=8C=96?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
src/views/farm/task/index.vue | 13 ++++++++++---
src/views/farm/taskCate/index.vue | 10 +++++++---
2 files changed, 17 insertions(+), 6 deletions(-)
diff --git a/src/views/farm/task/index.vue b/src/views/farm/task/index.vue
index d68775f..9bcf474 100644
--- a/src/views/farm/task/index.vue
+++ b/src/views/farm/task/index.vue
@@ -108,7 +108,7 @@
-
+
{{ parseTime(scope.row.createTime) }}
@@ -156,7 +156,7 @@
-
+
{{ item.name }}
@@ -284,6 +284,7 @@ export default {
selectResourceList: [],
projectList: [],
cropList: [],
+ selectCropList:[], //新增修改 作物
resourceTypeList: [],
resourceNumberList: [],
@@ -628,7 +629,8 @@ export default {
changeProject(row) {
this.form.areas = null;
this.assemArea();
- let projectArea = this.projectList.filter(project => project.id == row)[0].areas;
+ let project = this.projectList.filter(project => project.id == row)[0];
+ let projectArea = project.areas;
let filterArr = [];
this.assemAreaList.forEach(t => {
projectArea.forEach(a => {
@@ -638,6 +640,11 @@ export default {
})
})
this.assemAreaList = filterArr;
+
+ //根据项目 自动展示作物
+ this.form.cropId = null;
+ this.selectCropList = this.cropList.filter(crop => crop.id == project.cropId);
+
}
}
};
diff --git a/src/views/farm/taskCate/index.vue b/src/views/farm/taskCate/index.vue
index a909686..5febf92 100644
--- a/src/views/farm/taskCate/index.vue
+++ b/src/views/farm/taskCate/index.vue
@@ -35,6 +35,7 @@
:tree-props="{children: 'children', hasChildren: 'hasChildren'}">
+
{{ parseTime(scope.row.createTime) }}
@@ -71,6 +72,9 @@
+
+
+