From 338deda86b1496870cd843e0bff835de897c3fb2 Mon Sep 17 00:00:00 2001
From: liuyg <376836862@qq.com>
Date: Thu, 06 May 2021 17:20:48 +0800
Subject: [PATCH] Merge branch 'master' of http://192.168.0.105:10010/r/jfpt-Vue
---
src/views/system/cs.vue | 18 +++++++++++++-----
1 files changed, 13 insertions(+), 5 deletions(-)
diff --git a/src/views/system/cs.vue b/src/views/system/cs.vue
index 69f60b4..15c292f 100644
--- a/src/views/system/cs.vue
+++ b/src/views/system/cs.vue
@@ -177,6 +177,7 @@
datas: [], //cc
loadings: true, //等待
querys: {}, //搜索
+ isEdit:false,
pages: {
pageSize: 10,
currentPage: 1,
@@ -727,11 +728,13 @@
// form是表单或者表格绑定的数据集,v-model='form'
handler(val) {
if (val) {
- getDetail(this.form.id).then((res) => {
- this.form = res.data.data;
- });
- this.form.wd = val.latitude;
- this.form.jd = val.longitude;
+ if(that.isEdit){
+ getDetail(this.form.id).then((res) => {
+ this.form = res.data.data;
+ this.form.wd = val.latitude;
+ this.form.jd = val.longitude;
+ });
+ }
//地址截取,从县/区开始截取,并且取从县区第一个出现的位置开始
var address = val.formattedAddress.toString();
if (address.search("县") != -1) {
@@ -902,6 +905,7 @@
},
beforeOpen(done, type) {
if (["edit"].includes(type)) {
+ that.isEdit=true;
getDetail(this.form.id).then((res) => {
if (this.form.type == "1") {
const data = res.data.data;
@@ -994,6 +998,10 @@
}
});
}
+
+ if (["edit"].includes(type)) {
+ that.isEdit=false;
+ }
done();
},
searchReset() {
--
Gitblit v1.9.3