I'm currently using sgrid on a site I built for my classrooms (I'm a teacher by day... drupaller by night). I have close to 800 students in about 30 classes, and I'm attempting to use sgrid as a seating chart. I've structured the site as follows:
- Each student is a node of content type 'student'
- Each student is taxonomy tagged with their teacher's name
- I have a view which uses an argument from the URL (teacher name) to display the students tagged with that teacher's name in a sgrid view.
- Each student is only in 1 class (only tagged with 1 teacher name, and should only need 1 sgrid rank value)
- This all works beautifully!
I can arrange one class and save the order. However, if I load another class, rearrange, and save, the first class's order is lost.
I noticed (by adding the sgrid rank to my view) that when I save the order of the first class, each student is given a rank from 0-30 (or however many students there are in that view). When I go to a different set of students, rearrange, and save, this new set of students is ranked 0-30 and the original set of nodes all lose their rank (revert to rank of 0).
So, my question/request is:
Is there a different way we can assign ranking so that different sets of nodes (or multiple views) can be ranked separately? Right now it seems that every 'save' replaced the table's values with a number range of 0 to whatever.
Can the sgrid table be made to contain different nids with the same rank value? Or, (more complicated) can sgrid assign available ranges of unused numbers not starting with 0 and replacing current values for rank?
Thought this might be useful functionality for this module's future expanded use. Thank you for such a great module.
Comments
Comment #1
Countzero commentedYour demand is very interesting, and gives me some very good ideas to make the module suitable for uses I didn't think of when I created it.
Your use case is indeed very relevant for the kind of functionality sgrid proposes.
The problem is : sgrid ranking is Diplay based, assuming a display stays stable and always returns the same dataset. As of now, the module would need a serious amount work to integrate its sort criteria with other kinds of sorts and filters.
I don't have much time these days to work on this, but I will surely investigate to see what's possible, so I leave this issue open and will try to work on it when I can free some time.
Comment #2
michaeldhart commentedAaah, I see. I forgot about that column in the table. That makes sense. Thank you for taking my use into consideration; I do think it might be a typical use in some cases.
There isn't a way to change the view_display data based on arguments, is there? Something like adding an arg to the machine name setting in views? I guess that would be a views change. Or, another column in the table for storing the arg information? That way it would be display/argument based?
I'm not a super developer... just sharing my ideas. I'll keep trying some things and look forward to hearing what you come up with.
Comment #3
Countzero commentedYes, I think the solution would involve a column storing the argument. But then, it would need another column if the view has one more argument, so I'm not sure yet if it's the way to go.
With the end of the year, many clients wake up and give me work, so I really can't investigating for the time being. I can only say I'll look into it sooner or later.
Comment #4
Countzero commentedFYI, Draggable Views now has a Grid display style, so you may try it and see if you get what you want.
Feedback would be interesting to see if continuing support on Sgrid is still relevant.
Comment #5
Countzero commentedComment #6
michaeldhart commentedI found the patch, unfortunately it is for the 7.x-2.x.dev branch and my site is still in D6... I won't be able to upgrade it until this summer at the earliest. I will keep my eyes open for a D6 patch?
Comment #7
Countzero commentedWell, the problems are :
- The users of the D6 version of the module are fewer as time passes.
- I don't have more time now than when you opened the issue.
- Any time I could manage to free would probably be invested in the D7 version, provided it isn't replaced by the new Draggable Views.
So, as of now, a major overhaul of the module permiting the functionnality you desire is at best very unlikely . I'm sorry.
Comment #8
michaeldhart commentedNo problem, I can understand that. I'll work on getting my site up to D7 and try Draggable Views grid. Thanks for your work!
Comment #9
Countzero commentedCleaning the queue.