添加关照、全局等高线、修改图层问题

This commit is contained in:
2025-07-17 18:54:05 +08:00
parent c781d38c0c
commit b274b62671
4594 changed files with 791769 additions and 4921 deletions

View File

@ -58,7 +58,7 @@ export default {
close() {
this.$changeComponentShow(".adddirectory", false);
},
submit() {
submit: _.debounce(function () {
this.$refs['ruleForm'].validate((valid) => {
if (valid) {
this.add();
@ -66,10 +66,10 @@ export default {
return false;
}
});
},
}, 500),
add() {
console.log(window.treeObj);
let p_id = getKeyOfSelectedNode(window.treeObj, "source_id");
let fnone = getSelectedNode(window.treeObj);
let option = {
source_name: this.form.source_name,
source_id: this.$md5(new Date().getTime() + "图层"),
@ -85,7 +85,19 @@ export default {
max_tree_index = item.tree_index;
}
});
node.tree_index = max_tree_index + 1;
if (fnone) {
if (fnone.children && fnone.children.length > 0) {
let max_tree_index = 0;
fnone.children.forEach(item => {
if (item.tree_index > max_tree_index) {
max_tree_index = item.tree_index;
}
});
node.tree_index = max_tree_index + 1;
}
} else {
node.tree_index = max_tree_index + 1;
}
// node.tree_index = tree_index;
addSource(node).then((res) => {
cusAddNodes(

View File

@ -14,12 +14,12 @@
</div>
<div class="name">
<span>经度</span>
<el-input type="number" size="small" class="public" @input="(val) => lngNum(val)" v-model="lng" :max="180"
<el-input size="small" class="public" @input="(val) => lngNum(val)" v-model="lng" :max="180"
:min="-180" />
</div>
<div class="name">
<span>纬度</span>
<el-input type="number" size="small" class="public" @input="(val) => latNum(val)" v-model="lat" :max="90"
<el-input size="small" class="public" @input="(val) => latNum(val)" v-model="lat" :max="90"
:min="-90" />
</div>
<div class="name">
@ -42,11 +42,11 @@
</div>
<div class="name">
<span>x</span>
<input type="number" class="public" v-model="x" />
<el-input size="small" class="public" v-model="x" />
</div>
<div class="name">
<span>y</span>
<input type="number" class="public" v-model="y" />
<el-input size="small" class="public" v-model="y" />
</div>
<div class="name">
<span>定位</span>