filter dbjoin checkbox

p.s. since the Torneo element has been switched to Save its value to db the ajax filter is not triggered correctly on first load: you can still see some locations where this value is missing, and the ajax filter "works better" :) - I am adding some names in the notes section of my sites - frontend
 
Hi Hugh, sorry for the delay: I made some tests but it is still not working for me.
Storing Torneo in db just saves the value of the element, but it's not what I need to save: this element is meant to be only a filter for the dropdown element.
The issue is that it does save the multiple selection, but "only the first time" - meaning that it saves everytime, but everytime it is like is the first one.

It doesn't reload it (or if does, it doesn't show as "selected" the already made selection) if you edit the field again and the Torneo element is saved in the DB.
The same thing happen if you:
1)filter the dropdown by value 1,
2)select one entry,
3)filter the dropdown by value 2,
4)filter the dropdown by value 1,
at this point the selection made at step 2 is "not selected"

Maybe I should save after I make my selection (step 2 of the previous list) but if I then want to select some more entries, I miss the previously selected entries.

Am I doing something wrong? Is it not supposed to work like that?
Thanks

I think it's just not going to work how you want it to. When you change the selection on the "torneo" element (say) from '1' to '2', the join gets re-filtered, with '2' in the WHERE clause. So any values which were previously selected which no longer match that WHERE clause are no longer available - that's how WHERE filtering works. You are filtering the available selections (valid values the join can have). When you change that filter, you invalidate any previous selections which are no longer available.

-- hugh
 
Ah, allright I was being too much optimistic :)
So I need to find another way, which seems to be the checkbox layout, however I still have many entries there which may be confusing:
is there any way to make groups of checkboxes (like list group by) or another approach to let my users keep track easily of what they have selected?

thank you
 
Not that I can think of, no. Although I'm still rather confused about exactly what you are trying to achieve.

-- hugh
 
I'm still rather confused about exactly what you are trying to achieve.
I will try to make an example, unfortunately English is not my mother language:

Imagine that you as a user (and so the other users) have a "profile page" where you can select many events where you'd like to go.
These events are many (let's say 400, and you may select 1 or all of them).
The events are stored in a table.

Right now I am using dbjoin element in the "profile page" to select those events.
However, I only have 20 events now and it is already difficult to "find" and select them. Imagine how unfriendly would the dbjoin element be with 400 entries :)

I am thinking to remove the dbjoin element and create a table to handle the records (try to do what the _repeat table does, by hand) would this work? Using a list I would be able to filter it, group it and so on...

Thank you, I hope made myself understandable
 
We are in need of some funding.
More details.

Thank you.

Members online

Back
Top