1

On my site I have two content types:

  • event – with node flag “Attend” and Entity Reference field
  • band

And flags:

  • “Attend” – node flag - with Entity Reference field
  • “Accept” – flagging flag – connected to “Attend” flag

Each user can create unlimited number of Bands (he is manager of each Band) and create unlimited number of Events.
On Event creation form I add Entity Reference field with list of user Bands. This way band which he choose will become an Event organizer.
And now: other Users can click on flag “Attend” in Event node. On next step they need to choose witch of their bands will participate in this event (entity reference field)

Quick example:
“User 1” create “Band A”, “Band B” and “Band C”
“User 2” – “Band D”
Events and attendance:
“Band D” is the organizer of the “Event A”. “Band A”, “Band B”, “Band C” want to attend.
“Band A” create “Event B”. Attend: “Band D”,
“Band D” create “Event C”. Attend: “Band B”, “Band C”

In views I create a private page with table of events of each user. I add all necessary relationships to show Events of each user with list of bands which use “Attend”. Please imagine it as a table:

Band A – 1 event:

  • Event B
    • Band D – “Accept flag”(flag link)

Band D – 2 events:

  • Event A:
    • Band A - “Accept flag”
    • Band B - “Accept flag”
    • Band C - “Accept flag”
  • Event C:
    • Band B - “Accept flag”
    • Band C - “Accept flag”

User (author) creator of the event using flagging flag can decide which band he Accept for event.

Problem:
When Band D click “Accept” for Band B under Event A the status also change in Event C.
Do you think it is possible to separate this?
I hope I have described all process clear enough.
Thank you!

  • yes it will be using rule set – Adi Oct 5 '15 at 13:47
  • hmm.. Can you please explain? – user3615934 Oct 5 '15 at 13:55
  • @user3615934 Please clean up the formatting in your post. You can see the proper syntax by clicking the Help link. – Fabian Iwand Oct 5 '15 at 19:14
  • Done. Sorry @ciss I am new here. – user3615934 Oct 5 '15 at 20:32
0

Using Drupal rules module you can set up the right triggering conditions. It is possible to use rules to alter the data in fields arbitrarily, however your question is a little confusing because bands are also described as users, so you would need to make use of user related fields in the rules configuration. Take a look at the large rules documentation section and this intro to the rules module to get an idea. Flag module is compatible with rules.

  • To be more precise: "Band" and "Event" are separate node types. User is just an author of many bands nodes. So he is flagging "Attend" on behalf of one of his bands. – user3615934 Oct 6 '15 at 7:24
  • This way flag is used on node-node relation. The problem is that Flagging Flag have problem joining Band with Event. @hongpong thank you for your advise. You think the Rules are the only solution? Maybe I need to try to get a Content ID in relationships and then add it to Flag relation? – user3615934 Oct 6 '15 at 7:38

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.