These are chat archives for symfony2admingenerator/GeneratorBundle

20th
Mar 2015
ioleo
@ioleo
Mar 20 2015 11:11
configured activity webhooks for github & travis (Panel to the Right ----------------------------------------------------------> )
ioleo
@ioleo
Mar 20 2015 12:53
damn no idea why my web debug toolbar errors always :/
keep getting 500 error and toolbar is not loaded :/
Lionel
@Lionel09
Mar 20 2015 15:23
hi there, happy to see that @loostro is back to work with admingenerator! ;)
ioleo
@ioleo
Mar 20 2015 15:23
hi :)
Lionel
@Lionel09
Mar 20 2015 15:24
i'm just looking at this v2 for a new project, but ideally i would need some nested set list capabilities
ioleo
@ioleo
Mar 20 2015 15:24
Which ORM you work with?
Lionel
@Lionel09
Mar 20 2015 15:24
this time, it will be doctrine!
ioleo
@ioleo
Mar 20 2015 15:25
Alright
So the demo contains a nested list already
but it is very limited
Lionel
@Lionel09
Mar 20 2015 15:25
yes, i've take a look at it
ioleo
@ioleo
Mar 20 2015 15:25
it simply makes indentation bigger on first column...
Lionel
@Lionel09
Mar 20 2015 15:25
yes...
i've read a lot of discussion about nested list on the admingenertor github
ioleo
@ioleo
Mar 20 2015 15:26
There was a discussion about this, w8 a sec, let me find that issue..
Lionel
@Lionel09
Mar 20 2015 15:26
Yes, I have read all this stuff
ioleo
@ioleo
Mar 20 2015 15:27
OK well, since none of us use currently the "nested list", we did not push these changes forward.
Lionel
@Lionel09
Mar 20 2015 15:27
and just create a new one to "summarize" what you plan to do
is it a "work in progress" in somewhere?
ioleo
@ioleo
Mar 20 2015 15:30
No, the work has not been started, we were only discussing it.
Lately I've found a nice JS library, and I think it might be a good idea to use it.
Lionel
@Lionel09
Mar 20 2015 15:31
which one?
it has all the features we need - all client-side - (advanced filtering, pagination, sorting, child rows, row groups, custom parsers, etc)
it also supports loading data via AJAX
so we could either:
(a) display ALL rows on nested list ---> and make tablesorter "sort/filter/paginate" it (these happen on client-side)
(b) display tablesorter, which loads data via AJAX --> so each "sort/filter/paginate" action triggers an AJAX request and actual sorting/filtering/pagination happens on server-side
Lionel
@Lionel09
Mar 20 2015 15:35
yes, but it remains me your main problematic / choice to do: "move node" capabilites VS "filter/paginate" capabilities
ioleo
@ioleo
Mar 20 2015 15:36
if we go (b) then that case is simple:
1) AJAX tell server to "move" node
2) AJAX request "refreshed" data
3) display new table
or even (1) could (on success) respond with new data (to minimize the number of ajax calls)
to move node to another page we could do something like this:
[ THIS IS THE FILTERED/PAGINATED TABLE ]
[ below is a "shelf" where we can "move" any row ]
when we update (due to sorting/filtering/ changeing page / whatever) the table --> the "shelf" remains unchanged
then user can "drag" the row from the shelf, to any row in the table, to trigger "move" action
this way, moveing an item to another page/filtering criteria is just additional 2 clicks
ioleo
@ioleo
Mar 20 2015 15:41

Standard move:
1) drag row
2) move over another row
3) drop it - triggers AJAX call to save changes

Advanced move:
1) drag row
2) move over "shelf"
3) drop it
4) change filters / sorting / page
5) drag row from the shelf
6) move it over another row
7) drop it - triggers AJAX call to save changes

(and in both cases, if "move" is successfull, the AJAX request will return new "data" for tablesorter, if it's failed, we can display some message in red "Sorry could not move" or something like that)
what do you think?
Lionel
@Lionel09
Mar 20 2015 15:45
It's original, but it could take the advantages of the filter + ordering in the same page
btw, it could also be a loss of time in case of "small" tree
because you have always to put your moving node in the "shelf"
do you?
ioleo
@ioleo
Mar 20 2015 15:47
Well, I was thinking to implement both ways.
So if you have a small tree, and all items are visible on the same page.
Lionel
@Lionel09
Mar 20 2015 15:47
ok, sorry i've missed that point!
ioleo
@ioleo
Mar 20 2015 15:47
Then you simply move node A to node B (Standard move scenario)
But if you "can't see" the target node in current view, you have to put your node A in a placeholder "shelf", then change the criteria to "see" target node, then move node A from the shelf to target node.
Lionel
@Lionel09
Mar 20 2015 15:49
if you have a filtered list, and you move a node, what's happen?
because you can have strange results for unexperimented users in case like that
or perhaps i have missed another thing?
ioleo
@ioleo
Mar 20 2015 15:50
if you have a list like
Grandparent 1
   Parent 11
      Child A
      Child B
Grandparent 2
  Parent 21
      Child C
Lionel
@Lionel09
Mar 20 2015 15:51
perhaps we could have a "standard move" only if no filter has been set
ioleo
@ioleo
Mar 20 2015 15:51
nvm above
well, why not?
if you're on filtered list by name "Child"
Lionel
@Lionel09
Mar 20 2015 15:52
from your example, if you havve a filter for only "childs"
yes
ioleo
@ioleo
Mar 20 2015 15:52
hmm wait
let me make another example data
> John Senior Fernandez
>> John Junior Fernandez
>>> Katie Fernandez
>> Ivy Fernandez
>>> Mike Fernandez
> Dave Smith
>> Kate Smith
>> Will Smith
if you filter by Fernandez you only see the first 5 items
Lionel
@Lionel09
Mar 20 2015 15:55
yes you're right
ioleo
@ioleo
Mar 20 2015 15:55
now, if you want to move "Katie Ferndandez" below "Ivy Fernandez"
you can simply use standard way (drag & drop)
no problem
Lionel
@Lionel09
Mar 20 2015 15:55
yes
ioleo
@ioleo
Mar 20 2015 15:56
if you want to move "Katie Ferndandez" below "Will Smith"
you have to use Advanced way -> move Katie to "shelf"
then change filter to Smith
then move Katie from shelf to "Will Smith"
Lionel
@Lionel09
Mar 20 2015 15:57
but in previous example, if you move child C between child 1 and child B, i suppose some people could "forget" that a filter is working behind
ioleo
@ioleo
Mar 20 2015 15:58
We could make a check on server side.
if MOVED node is in the results
if true -> simply update the table
if false -> update the table and display a message "The (NODE_NAME) has been succesfully moved, but it does not meet current filtering criteria. Change the criteria to see it"
Lionel
@Lionel09
Mar 20 2015 16:00
:+1:
ioleo
@ioleo
Mar 20 2015 16:01
so in our case, if we have "Katie Fernandez" on the shelf, and we filter by "Smith" -> after moveing Katie below will Smith -> we would display that message (becouse Katie Fernandez would be not present in results, she does not meet "Smith" criteria)
Lionel
@Lionel09
Mar 20 2015 16:02
yes, i understand, it's great to have all the list + node capabilities on the same page
ioleo
@ioleo
Mar 20 2015 16:03
I will probably not be able to work on this in the next 2 weeks. My "todo" list is already full.
Lionel
@Lionel09
Mar 20 2015 16:03
the generator must also have a "add child" action with all the "left/right/etc." working behind
ok
it seems you have to post your new implementation ideas to the old nested set list discussion on github to have opinions from others "core team generator members"?
ioleo
@ioleo
Mar 20 2015 16:04
i do not think it's necessary to start working
i mean, we've already discussed this, and today's idea will solve all problems that were issued in an elegant way
Lionel
@Lionel09
Mar 20 2015 16:06
ok
ioleo
@ioleo
Mar 20 2015 16:06
we could start a branch and work on this, and invite others to discuss in the same time
if you want you can start working on this yourself :) everyone is invited to help :)
Lionel
@Lionel09
Mar 20 2015 16:07
ok, my team manager has not make his choice for the "admin" on this new project, but if we go with admingenerator, perhaps we could work on
;)
BTW, thanks for your ideas & support!
ioleo
@ioleo
Mar 20 2015 16:07
i want to release stable v2 admingen (with adminlte theme) till May 1
im not sure its possible if only I work on this :P coz i have some other duties :) but ill be active here on gitter chat and on github next month
so if you have any questions, ideas or PRs i can help :)