Dayo Posted April 10, 2012 Posted April 10, 2012 Ive made a small script to plan my projects all it is is basically one large list but the list can have unlimited "parents"/"children" even the "children" can have "children" etc etc there is no limit (other then your db. :p) I'll get print screens tomorrow and if people like it I'll release if for free as it only took me a hour or so to code :) If you would like me to explain it in a bit more detail just ask. test testtest testtest test testtest test test test [*]test [*]test [*]test [*]test [*]test test test test test Pretty much like that but Obv not the same CSS 1 Quote
wykydz Posted April 10, 2012 Posted April 10, 2012 looks interesting ,is there like a estimated time input and output or progress bar ? Quote
Dayo Posted April 10, 2012 Author Posted April 10, 2012 Sounds interesting I'll look into adding something like that :) Quote
wykydz Posted April 10, 2012 Posted April 10, 2012 ty i help run a radio station and this will help with the many task on hand to organized setups and project and many many other things Quote
ColdBlooded Posted April 11, 2012 Posted April 11, 2012 I would be interested in a tool of this sort. Would definitely make use of it. Many free popular project management tool on the net aren't good enough in my opinion. Keep us posted with the development of this. I'd be happy to contribute some work towards it also and use it sometime in the immediate future. Quote
Spudinski Posted April 11, 2012 Posted April 11, 2012 Good idea Dayo, would like to see how you do this. @CB: qdPM and the bug genie are both capable of this. In qdPM it's "Gantt Chart", and in TBG it's "Roadmap". Quote
Dayo Posted April 11, 2012 Author Posted April 11, 2012 I've just got to optimise it a little as ATM it searches for children for every <li> and if you have a few 100 like I'm gona have it will get slow so I'm going to only search for children if it has children so in the example above thee would only be 5 querys other then 20 Quote
rulerofzu Posted April 11, 2012 Posted April 11, 2012 Sounds cool I could use something like this. Ill take a freebie...charge CB though lol :P Quote
SilverStar Posted April 11, 2012 Posted April 11, 2012 So it's similar to Yahoo Treeview? http://developer.yahoo.com/yui/treeview/ Quote
Dayo Posted April 11, 2012 Author Posted April 11, 2012 I've never used/seen that but from the looks of it the concept seams farmiliar Quote
ColdBlooded Posted April 11, 2012 Posted April 11, 2012 Sounds cool I could use something like this. Ill take a freebie...charge CB though lol :P haha, no way. Dayo loves me too much to charge. I'm sure you do secretly too RoZ. Quote
Dave Posted April 11, 2012 Posted April 11, 2012 I love this idea to, might create my own version so I actually keep track on projects. Quote
Dayo Posted April 11, 2012 Author Posted April 11, 2012 Glad you like the idea :) Also just to let people know I've used the JQuery UI for the styling no reason other then I wanted to see what it looked like and to make it easier/more efficient adding data (I've codeded it so when you add a child it only re-loads the parent and not the whole tree. I'm going to change a few more things tonight add a few ideas given to me/some I've thought of so it will help you/me plan projects better Quote
Spudinski Posted April 11, 2012 Posted April 11, 2012 Glad you like the idea :) Also just to let people know I've used the JQuery UI for the styling no reason other then I wanted to see what it looked like and to make it easier/more efficient adding data (I've codeded it so when you add a child it only re-loads the parent and not the whole tree. I'm going to change a few more things tonight add a few ideas given to me/some I've thought of so it will help you/me plan projects better Just as an FYI, it would be cool to have links as methods. I.e.: var parent = { one: 'some value', 'do stuff': function() { // do stuff }, three: 1 } $.each(parent, function(k, v) { if (typeof(v) == 'function') { element = $('<span>' + k + '</span>') $(body).append(element) element.onclick(v) } elseif(typeof(v) == 'object') $(body).append(v) else $(body).append('<span id="' + k + '">' + v + '</span>') } Not tested, but would be pretty damn cool. Quote
Dayo Posted April 11, 2012 Author Posted April 11, 2012 atm the list is generated like this via php function child($parent) { $parent = abs(intval($parent)); $query = mysql_query("SELECT * FROM `child` WHERE `parent`=$parent"); $return = ''; while ($child = mysql_fetch_array($query)) { if ($child['children']) { $return = $return.'<li id="'.$child['id'].'">'.$child['text'].'<small style="display:none;"> <span class="add_link" cid="'.$child['id'].'" onclick="add()">[+]</span> <span class="remove_link" cid="'.$child['id'].'">[-]</span></small></li>'.child($child['id']); } else { $return = $return.'<li id="'.$child['id'].'">'.$child['text'].'<small style="display:none;"> <span class="add_link" cid="'.$child['id'].'" onclick="add()">[+]</span> <span class="remove_link" cid="'.$child['id'].'">[-]</span></small></li>'; } } return '<ul class="'.$parent.'">'.$return.'</ul>'; } but ill look into doing it as you said Quote
Spudinski Posted April 11, 2012 Posted April 11, 2012 atm the list is generated like this via php function child($parent) { $parent = abs(intval($parent)); $query = mysql_query("SELECT * FROM `child` WHERE `parent`=$parent"); $return = ''; while ($child = mysql_fetch_array($query)) { if ($child['children']) { $return = $return.'<li id="'.$child['id'].'">'.$child['text'].'<small style="display:none;"> <span class="add_link" cid="'.$child['id'].'" onclick="add()">[+]</span> <span class="remove_link" cid="'.$child['id'].'">[-]</span></small></li>'.child($child['id']); } else { $return = $return.'<li id="'.$child['id'].'">'.$child['text'].'<small style="display:none;"> <span class="add_link" cid="'.$child['id'].'" onclick="add()">[+]</span> <span class="remove_link" cid="'.$child['id'].'">[-]</span></small></li>'; } } return '<ul class="'.$parent.'">'.$return.'</ul>'; } but ill look into doing it as you said You could pass an associative array as JSON to the page, and render it. It would appear as a list item, but eval() or a external Javascript event hook can always be added after the initial population. Quote
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.