|
@@ -250,6 +250,16 @@ export default {
|
|
|
return
|
|
|
}
|
|
|
}
|
|
|
+ if(parseFloat(this.redForm.lat)>180||parseFloat(this.redForm.lat)<-180)
|
|
|
+ {
|
|
|
+ this.$message("请输入正确范围的经度")
|
|
|
+ return
|
|
|
+ }
|
|
|
+ if(parseFloat(this.redForm.lon)>90||parseFloat(this.redForm.lon)<-90)
|
|
|
+ {
|
|
|
+ this.$message("请输入正确范围的纬度")
|
|
|
+ return
|
|
|
+ }
|
|
|
this.redList.push({
|
|
|
order: this.redList.length+1,
|
|
|
name: this.redForm.name,
|
|
@@ -323,6 +333,16 @@ export default {
|
|
|
return
|
|
|
}
|
|
|
}
|
|
|
+ if(parseFloat(this.blueForm.lat)>180||parseFloat(this.blueForm.lat)<-180)
|
|
|
+ {
|
|
|
+ this.$message("请输入正确范围的经度")
|
|
|
+ return
|
|
|
+ }
|
|
|
+ if(parseFloat(this.blueForm.lon)>90||parseFloat(this.blueForm.lon)<-90)
|
|
|
+ {
|
|
|
+ this.$message("请输入正确范围的纬度")
|
|
|
+ return
|
|
|
+ }
|
|
|
this.blueList.push({
|
|
|
order: this.blueList.length+1,
|
|
|
name: this.blueForm.name,
|
|
@@ -347,6 +367,10 @@ export default {
|
|
|
|
|
|
},
|
|
|
addRed(){
|
|
|
+ if(!this.save){
|
|
|
+ this.$message("请先导入想定文件!")
|
|
|
+ return
|
|
|
+ }
|
|
|
this.redForm = {
|
|
|
name: '',
|
|
|
method: '',
|
|
@@ -357,6 +381,10 @@ export default {
|
|
|
this.redVisible = true
|
|
|
},
|
|
|
addBlue(){
|
|
|
+ if(!this.save){
|
|
|
+ this.$message("请先导入想定文件!")
|
|
|
+ return
|
|
|
+ }
|
|
|
this.blueForm = {
|
|
|
name: '',
|
|
|
lat: '',
|