1. Fabrik 3.8.1 has been released. It is mostly bug fixes and feature enhancements, but does include two new plugins (push notifications, and the sequence element). As usual we strongly recommend testing the new release on a sandbox if your application is mission critical, and always do an Akeeba backup before updating.
    Dismiss Notice

How to make an "attend events" form?

Discussion in 'Community' started by jalonsom, May 18, 2009.

  1. jalonsom

    jalonsom New Member

    Level: Community
    Been trying to sort this out, but I currently have no clue on how to do this.

    I want to make an "Attend Events" application.

    - Certain users should be able to create events. This looks like an easy form. No problem.
    - I want a way to display a table containing the events that the logged in user has not confirmed if he is going to attend or not, with a link to a form that allows him to respond yes/no.
    - Ideally that table would contain the radio button to answer yes/no (I don't know if this is possible, it sounds like mixing tables and forms...) with a single submit button for all events.
    - I also want a table with already responded events, so that the user can see and edit his own responses. (ideally the edit would be done in the table, but again I don't know if it's possible).

    I have tried several approaches, trying a different table to store the user's responses, but none worked. I'm really stuck.
    ?Can anyone give me a hint?

    Thanks a lot!
  2. cheesegrits

    cheesegrits Support Gopher Staff Member

    Level: Community
    I answered an almost identical question about building an events / attendees app earlier today, which may help. OK, found it ... it was in the 1.0 forums, but the same principle applies for 2.0:


    You need two tables - the events table (which stores the details about the event), and a user_events table, which has the per-user details about events they are attending.

    You can then pre-filter the user_events table so only the events you want show up, by using the 'subquery' type filter. Won't be exactly the same as the on on the other thread, but a similar principle.

    Is that how you have things set up now?

    -- hugh
  3. jalonsom

    jalonsom New Member

    Level: Community
    I had those tables set up, but didn't think of prefiltering, which now seems quite obvious... I was trying to make some kind of table join....


    Now I don't see how can I display a link in each table row so that the user can create a response for the correspondign event in the response table.

    Can I pass the event id to the response form through a parameter in the link? How?
    I could then just call the response form with that parameter.

    EDIT: I found this can be done as described here: http://fabrikar.com/forums/showthread.php?t=7972

    Is there another better way?

    Thanks again!!
  4. rob

    rob Administrator Staff Member

    Level: Community
    nope thats the best way to do it


Share This Page