]> dev.renevier.net Git - syj.git/blobdiff - public/js/syj.js
fixes: not possible to upload path after it has been droped from a file
[syj.git] / public / js / syj.js
index 8012d996bf203ef74661924aa22d4ea91e644d8e..9d7f974793222537f14a502d7b9cd75cd75013e8 100644 (file)
@@ -404,7 +404,20 @@ var SYJView = {
                     }
                     this.viewLayer.addFeatures([vector]);
                     this.map.zoomToExtent(this.viewLayer.getDataExtent());
-                    this.editMode();
+
+                    if ($("edit-btn")) {
+                        $("edit-btn").click();
+                    } else if ($("create-btn")) {
+                        $("create-btn").click();
+                    }
+
+                    if (this.editControl.handler.realPoints.length < 2) {
+                        SyjSaveUI.disable();
+                    } else {
+                        SyjSaveUI.enable();
+                    }
+
+
                     if (vector.data && vector.data.name) {
                         $("geom_title").value = vector.data.name;
                     }