|
|
| Author |
Message |
johnrembo Cacti User
Joined: 24 Apr 2006 Posts: 198
|
Posted: Tue Feb 12, 2008 9:00 am Post subject: graph tree |
|
|
hello,
author of cacti's graph tree architecture must be a genius or an idiot(don't take it personaly), but not in between
what is the easiest way of getting whole graph tree list into simple php array with local_graph_id's at the deepest level?
thank you |
|
| Back to top |
|
 |
TheWitness Developer
Joined: 14 May 2002 Posts: 9697 Location: MI, USA
|
Posted: Tue Feb 12, 2008 8:50 pm Post subject: |
|
|
I'ts a piece of work, and created before my time. Look into, hmm, let me check, lib/html_tree.php for the function "create_dhtml_tree". That will contain the nugget. However, output is structured for the tree product. I will be 100% ripping it out in the next release of Cacti.
If you would like to collaborate on that development, it will likely start the last two weeks of March.
TheWitness |
|
| Back to top |
|
 |
Howie Cacti Guru User
Joined: 16 Sep 2004 Posts: 2167 Location: United Kingdom
|
Posted: Wed Feb 13, 2008 3:35 am Post subject: |
|
|
| TheWitness wrote: | I'ts a piece of work, and created before my time. Look into, hmm, let me check, lib/html_tree.php for the function "create_dhtml_tree". That will contain the nugget. However, output is structured for the tree product. I will be 100% ripping it out in the next release of Cacti.
If you would like to collaborate on that development, it will likely start the last two weeks of March.
TheWitness |
Please add in some support for external tree item rendering too (plugin types)... I've started writing this twice now, only to have Cacti development overtake me. The basics were really simple (stop using implicit type_ids, start using the already-existing tree types in a new db field), but getting into all the corners slowed me down enough that I lost the race.
johnrembo, if you just want local_graph_ids and you don't care about their position then the query is a pretty simple join between graph_tree and graph_tree_item... anything with a non-zero local_graph_id in graph_tree_item is a graph. Just pull em out. |
|
| Back to top |
|
 |
johnrembo Cacti User
Joined: 24 Apr 2006 Posts: 198
|
Posted: Wed Feb 13, 2008 3:47 am Post subject: |
|
|
| Howie wrote: | | TheWitness wrote: | I'ts a piece of work, and created before my time. Look into, hmm, let me check, lib/html_tree.php for the function "create_dhtml_tree". That will contain the nugget. However, output is structured for the tree product. I will be 100% ripping it out in the next release of Cacti.
If you would like to collaborate on that development, it will likely start the last two weeks of March.
TheWitness |
Please add in some support for external tree item rendering too (plugin types)... I've started writing this twice now, only to have Cacti development overtake me. The basics were really simple (stop using implicit type_ids, start using the already-existing tree types in a new db field), but getting into all the corners slowed me down enough that I lost the race.
johnrembo, if you just want local_graph_ids and you don't care about their position then the query is a pretty simple join between graph_tree and graph_tree_item... anything with a non-zero local_graph_id in graph_tree_item is a graph. Just pull em out. |
it took me a while to understand that logics ^^^
the biggest fun is playing with their position on the tree.
TheWitness, I just was in the hope that you have allready rewrote this part of code. Anyway, it's not a big problem. If i'll succed - i'll share my work.
ps: don't invent a bicycle: http://www.extjs.com |
|
| Back to top |
|
 |
TheWitness Developer
Joined: 14 May 2002 Posts: 9697 Location: MI, USA
|
Posted: Wed Feb 13, 2008 4:50 am Post subject: |
|
|
Yea, but it's so much fun. Bit of a challenge. I do like his approach. Very good API.
Larry |
|
| Back to top |
|
 |
Howie Cacti Guru User
Joined: 16 Sep 2004 Posts: 2167 Location: United Kingdom
|
Posted: Wed Feb 13, 2008 6:04 am Post subject: |
|
|
| The new weathermap editor will likely be done with extjs, if I ever find the time. |
|
| Back to top |
|
 |
|
Powered by phpBB © 2001, 2005 phpBB Group
|
|