Hello! I've updated weathermap editor script for initiating node moving by dragging. So, it become easier to redraw even huge map. All is needed is to start dragging node and point the place where it should be located.
==PATCH==
--- editor.js.old 2010-03-04 15:45:19.000000000 +0500
+++ editor.js 2011-09-29 17:20:32.185311639 +0600
@@ -81,5 +81,22 @@
}
+function drag_handler(event) {
+ var alt, objectname, objecttype, objectid;
+ // if we're not in a mode yet...
+ if (document.frmMain.action.value == '') {
+ alt = jQuery(this).attr("id");
+
+ objectname = alt.slice(5, alt.length);
+ objectid = objectname.slice(0, objectname.length - 2);
+ objectname = NodeIDs[objectid];
+
+ document.getElementById('param').value = objectname;
+ show_node(objectname);
+ move_node();
+ }
+
+ return false;
+}
function attach_click_events()
@@ -90,4 +107,5 @@
jQuery("area[id^=TIMES]").attr("href","#").click(position_timestamp);
jQuery("area[id^=LEGEN]").attr("href","#").click(position_legend);
+ jQuery("area[id^=NODE:]").attr("href","#").bind('dragstart', drag_handler);
if(fromplug===1)
Weathermap editor with easy node move
Moderators: Developers, Moderators
- Howie
- Cacti Guru User
- Posts: 5508
- Joined: Thu Sep 16, 2004 5:53 am
- Location: United Kingdom
- Contact:
Re: Weathermap editor with easy node move
Cool... I'll give it a try!
One day I'll get this thing finished:
http://www.network-weathermap.com/files/editor-test.m4v
One day I'll get this thing finished:
http://www.network-weathermap.com/files/editor-test.m4v
Weathermap 0.98a is out! & QuickTree 1.0. Superlinks is over there now (and built-in to Cacti 1.x).
Some Other Cacti tweaks, including strip-graphs, icons and snmp/netflow stuff.
(Let me know if you have UK DevOps or Network Ops opportunities, too!)
Some Other Cacti tweaks, including strip-graphs, icons and snmp/netflow stuff.
(Let me know if you have UK DevOps or Network Ops opportunities, too!)
Re: Weathermap editor with easy node move
Is what you did possible, Howie?.
- Howie
- Cacti Guru User
- Posts: 5508
- Joined: Thu Sep 16, 2004 5:53 am
- Location: United Kingdom
- Contact:
Re: Weathermap editor with easy node move
That's a working demo from 2008. The code doesn't work right now, but yes...Atreides wrote:Is what you did possible, Howie?.
Weathermap 0.98a is out! & QuickTree 1.0. Superlinks is over there now (and built-in to Cacti 1.x).
Some Other Cacti tweaks, including strip-graphs, icons and snmp/netflow stuff.
(Let me know if you have UK DevOps or Network Ops opportunities, too!)
Some Other Cacti tweaks, including strip-graphs, icons and snmp/netflow stuff.
(Let me know if you have UK DevOps or Network Ops opportunities, too!)
Re: Weathermap editor with easy node move
i'm unable to patch.
Can you provide the command please ?
Can you provide the command please ?
Re: Weathermap editor with easy node move
Hello,
Anyone have a working drag & drop for weathermap ? I tried this patch, also few tips I've found on this forum, but no joy. Moving tons of nodes every 5 min to align beautifull is starting to kill me .
Anyone have a working drag & drop for weathermap ? I tried this patch, also few tips I've found on this forum, but no joy. Moving tons of nodes every 5 min to align beautifull is starting to kill me .
- Howie
- Cacti Guru User
- Posts: 5508
- Joined: Thu Sep 16, 2004 5:53 am
- Location: United Kingdom
- Contact:
Re: Weathermap editor with easy node move
I use relative positioning and cut&paste for this, personally.Atreides wrote:Hello,
Anyone have a working drag & drop for weathermap ? I tried this patch, also few tips I've found on this forum, but no joy. Moving tons of nodes every 5 min to align beautifull is starting to kill me .
Weathermap 0.98a is out! & QuickTree 1.0. Superlinks is over there now (and built-in to Cacti 1.x).
Some Other Cacti tweaks, including strip-graphs, icons and snmp/netflow stuff.
(Let me know if you have UK DevOps or Network Ops opportunities, too!)
Some Other Cacti tweaks, including strip-graphs, icons and snmp/netflow stuff.
(Let me know if you have UK DevOps or Network Ops opportunities, too!)
Who is online
Users browsing this forum: No registered users and 0 guests