Commit 82d255b4 authored by 纪泽龙's avatar 纪泽龙

地图模式图片上传bug

parent 5ed83297
......@@ -151,6 +151,7 @@ export default {
return {
form: {
deviceType: "3",
iconUrl:"",
},
type: DEVICE_TYPE.FLOWMETER,
dialogVisible: false,
......
......@@ -3,6 +3,7 @@
:title="myTitle"
:visible.sync="dialogVisible"
:before-close="handleClose"
ref="dialog"
>
<el-row>
<el-form
......@@ -146,7 +147,7 @@
<el-button :loading="okLoading" type="primary" @click="ok"
> </el-button
>
<el-button @click="dialogVisible = false"> </el-button>
<el-button @click="handleCloseBtn"> </el-button>
</span>
</el-dialog>
</template>
......@@ -271,14 +272,19 @@ export default {
if (res.code == 200) {
this.dialogVisible = false;
data.pipeId = data.pipeId ? data.pipeId : res.data;
this.lineOkCallBack.call(this.gaodeMap, this.target, data,()=>{
const arr= this.gaodeMap.polyLines.map(item=>{
return item.getExtData().lineData
})
console.log("arr===================",arr)
this.gaodeMap.view.pipeClassify(arr)
this.gaodeMap.view.pipeList();
this.lineOkCallBack.call(
this.gaodeMap,
this.target,
data,
() => {
const arr = this.gaodeMap.polyLines.map((item) => {
return item.getExtData().lineData;
});
console.log("arr===================", arr);
this.gaodeMap.view.pipeClassify(arr);
this.gaodeMap.view.pipeList();
}
);
if (!this.editForm.pipeId) {
this.gaodeMap.newLineObj = null;
this.gaodeMap.createNewLine();
......@@ -321,7 +327,9 @@ export default {
options.lineData = { ...this.editForm };
this.target.setExtData(options);
// 把值带出去
if (done) {
done();
}
// this.$confirm("确认关闭?")
// .then((_) => {
......@@ -329,6 +337,10 @@ export default {
// })
// .catch((_) => {});
},
handleCloseBtn() {
this.handleClose();
this.dialogVisible = false;
},
// 图片上传成功
fileFinshed(e) {
this.editForm.iconUrl = e.url;
......
......@@ -151,6 +151,8 @@ export default {
return {
form: {
deviceType: "4",
iconUrl:"",
},
type: DEVICE_TYPE.PRESSUREGAGE,
dialogVisible: false,
......
......@@ -151,6 +151,8 @@ export default {
return {
form: {
deviceType: "1",
iconUrl:"",
},
type: DEVICE_TYPE.REGEULATORBOX,
dialogVisible: false,
......
......@@ -150,6 +150,7 @@ export default {
return {
form: {
deviceType: "2",
iconUrl:"",
},
type: DEVICE_TYPE.VALUEWELL,
dialogVisible: false,
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment