From eba5a57c3f1228b00c27985bdd78ce07ccc68df6 Mon Sep 17 00:00:00 2001
From: guoshilong <123456>
Date: Sat, 15 Oct 2022 11:44:03 +0800
Subject: [PATCH] 限制输入字符数;修改农场详情显示
---
src/views/wel/farming.vue | 1 +
src/views/wel/index.vue | 26 +-------------------------
src/views/farm/farmInfoDetail.vue | 24 +++++++++++++++++++-----
src/views/wel/land.vue | 1 +
src/views/land/landAdd.vue | 1 +
src/views/farm/farm.vue | 3 +++
src/views/land/land.vue | 1 +
src/views/machining/machining.vue | 1 +
src/views/mapPattern/index.vue | 1 -
9 files changed, 28 insertions(+), 31 deletions(-)
diff --git a/src/views/farm/farm.vue b/src/views/farm/farm.vue
index 2b07512..2703ced 100644
--- a/src/views/farm/farm.vue
+++ b/src/views/farm/farm.vue
@@ -97,6 +97,7 @@
search: true,
prop: "farmName",
labelWidth: 145,
+ maxlength:40,
rules: [{
required: true,
message: "请输入农场名称",
@@ -194,6 +195,7 @@
label: "口号",
prop: "slogan",
labelWidth: 145,
+ maxlength:90,
rules: [{
required: true,
message: "请输入农场口号",
@@ -217,6 +219,7 @@
type: "textarea",
span: 24,
labelWidth: 145,
+ maxlength:200,
rules: [{
required: true,
message: "请输入农场介绍",
diff --git a/src/views/farm/farmInfoDetail.vue b/src/views/farm/farmInfoDetail.vue
index b6f32e7..8eb4a2a 100644
--- a/src/views/farm/farmInfoDetail.vue
+++ b/src/views/farm/farmInfoDetail.vue
@@ -67,6 +67,7 @@
},
},
{
+ disabled:true,
label: "农场名称",
prop: "farmName",
span: 12,
@@ -80,6 +81,7 @@
// ],
},
{
+ disabled:true,
label: '省份',
prop: 'province',
type: 'select',
@@ -100,6 +102,7 @@
// }],
},
{
+ disabled:true,
label: '地市',
prop: 'city',
type: 'select',
@@ -114,6 +117,7 @@
dicUrl: '/api/blade-system/region/select?code={{province}}',
},
{
+ disabled:true,
label: '区县',
prop: 'district',
type: 'select',
@@ -127,6 +131,7 @@
dicUrl: '/api/blade-system/region/select?code={{city}}',
},
{
+ disabled:true,
label: "农场地址",
prop: "farmAddress",
span: 12,
@@ -141,6 +146,7 @@
// ],
},
{
+ disabled:true,
label: "农场面积",
prop: "farmArea",
span: 12,
@@ -162,6 +168,7 @@
prop: "group2",
column: [
{
+ disabled:true,
label: "口号",
prop: "slogan",
span: 12,
@@ -175,17 +182,15 @@
// ],
},
{
+ disabled: true,
label: "360全景地址",
prop: "panoramic",
labelWidth: 145,
hide: true,
- // rules: [{
- // required: false,
- // message: "请输入地址",
- // trigger: "blur"
- // }]
+ placeholder:" "
},
{
+ disabled:true,
label: "介绍",
type: "textarea",
prop: "introduce",
@@ -200,6 +205,7 @@
// ],
},
{
+ disabled:true,
label: "农场环境图片",
prop: "picture",
type: "upload",
@@ -338,6 +344,14 @@
top: 10px;
}
+.el-input.is-disabled ::v-deep .el-input__inner {
+ color: #606266;
+}
+
+.el-textarea.is-disabled ::v-deep .el-textarea__inner{
+ color: #606266;
+}
+
// .el-collapse-item {
// padding-top: 15px !important;
// }
diff --git a/src/views/land/land.vue b/src/views/land/land.vue
index a60e34f..5a799c3 100644
--- a/src/views/land/land.vue
+++ b/src/views/land/land.vue
@@ -91,6 +91,7 @@
label: "地块名称",
search: true,
prop: "landName",
+ maxlength:30,
rules: [{
required: true,
message: "请输入地块名称",
diff --git a/src/views/land/landAdd.vue b/src/views/land/landAdd.vue
index 7f4b94a..bac2e5a 100644
--- a/src/views/land/landAdd.vue
+++ b/src/views/land/landAdd.vue
@@ -49,6 +49,7 @@
{
label: "地块名称",
prop: "landName",
+ maxlength:30,
rules: [
{
required: true,
diff --git a/src/views/machining/machining.vue b/src/views/machining/machining.vue
index 059da60..087f4c0 100644
--- a/src/views/machining/machining.vue
+++ b/src/views/machining/machining.vue
@@ -182,6 +182,7 @@
prop: "remarks",
span: 24,
type: "textarea",
+ maxlength:200,
},
]
},
diff --git a/src/views/mapPattern/index.vue b/src/views/mapPattern/index.vue
index 7350218..71c43e8 100644
--- a/src/views/mapPattern/index.vue
+++ b/src/views/mapPattern/index.vue
@@ -290,7 +290,6 @@
arr.forEach(it => {
brr.push(it.split(' '))
})
-
this.$refs.plotMap.addPlotPolygon(brr, item)
}
})
diff --git a/src/views/wel/farming.vue b/src/views/wel/farming.vue
index a591268..e40c1d5 100644
--- a/src/views/wel/farming.vue
+++ b/src/views/wel/farming.vue
@@ -218,6 +218,7 @@
label: "备注",
prop: "remarks",
type: "textarea",
+ maxlength:200,
span: 24,
labelWidth: 110,
rules: [
diff --git a/src/views/wel/index.vue b/src/views/wel/index.vue
index 6a05abb..fac1af1 100644
--- a/src/views/wel/index.vue
+++ b/src/views/wel/index.vue
@@ -254,7 +254,7 @@
...mapGetters(["userInfo","$farmId"]),
},
created () {
-
+
this.$EventBus.$on('getFarmObj', (farmObj)=>{
// this.$nextTick(() => {
// this.$EventBus.$emit("setFarmId", farmObj.id);
@@ -414,30 +414,6 @@
this.$refs.over.initData(data,this.farm.id)
})
},
- //结束种植
- // over (id) {
- // var that = this
- // this.$confirm("确定结束当前种植的农产品?", {
- // confirmButtonText: "确定",
- // cancelButtonText: "取消",
- // type: "warning",
- // })
- // .then(() => {
- // const data = {
- // id: id,
- // status: 2,
- // }
- // return update(data)
- // })
- // .then(() => {
- // that.onLoad()
- // this.$message({
- // type: "success",
- // message: "操作成功!",
- // })
- // })
- // },
- //圈地
land () {
this.landVisible = true
this.$nextTick(() => {
diff --git a/src/views/wel/land.vue b/src/views/wel/land.vue
index 9af8b14..982de98 100644
--- a/src/views/wel/land.vue
+++ b/src/views/wel/land.vue
@@ -50,6 +50,7 @@
{
label: "地块名称",
prop: "landName",
+ maxlength:30,
rules: [
{
required: true,
--
Gitblit v1.9.3