hi guys , i need your help i create a course A with lesson and add members to it , now i create another course B and lesson ( is still not published ) and i want the same members in course A to be in course B when the course B is published ( by rule ) , i hope that you understood what i mean. Kobi
Have you tried grouping those 2 courses in a class?
It may work out of the box, if not only very small changes should be required.
If you have a class with 2 courses, there are rules that automatically add the users to all the courses in the class. So the subscription part is already implemented.
If one of the courses is unpublished, the users will be members of it but will not be able to access it because it is unpublished.
You could simple add a date field to the courses. And based on that date have a cron that published/unpublishes the courses based on that date.
Or could add the course to the class at that point, and the rules to add the users would be automatically triggered.
When creating/editing a rule, you have events (when is the rule triggered), conditions (conditions for the rule to apply) and actions (actually do something).
You can mix and match the events and conditions.
Also if you find that there are specific triggers, conditions or action that are not exposed in the interface, you can easily add your own.
If you search for drupal rules create custom trigger||condition||action you will find a lot of simple tutorials on how to do this.
In reply to Hi kobi, by James Aparicio
For that you can create a new
For that you can create a new rule triggered by on node before saving.
You can check if the node-unchanged is unpublished and the node is published. Then just look over all the active members and trigger an email action.