Workflow to add Teams for all attendees users of Meetings

Collapse
X
 
  • Time
  • Show
Clear All
new posts

  • LukasShultz
    replied
    Originally posted by item
    Hello,

    //getMettingId
    $meetingId = entity\attribute('id');
    //getRelatedUsers
    $userIds=record\findRelatedMany('Meeting', $meetingId, 'users', 50);
    $i = 0;
    //loop on all userIds
    while($i < array\length($userIds),
    //getUserId
    $userId = array\at($userIds, $i);

    after.. i don't know
    Hi item,
    I try like that:
    //$iduzyt = usersIds;
    //description = record\attribute('User', $iduzyt, 'teamsIds');
    //getMettingId
    $meetingId = entity\attribute('id');
    $userIds=record\findRelatedMany('Meeting', $meetingId, 'users', 50);
    $i = 0;
    while($i < array\length($userIds),
    $userId = array\at($userIds, $i);
    $idMyTeam = record\attribute('User', $userId, 'teamsIds');
    entity\addLinkMultipleId('teams', $idMyTeam);
    );

    But it doesn't work :/

    Leave a comment:


  • LukasShultz
    replied
    Originally posted by Katia
    Hi Lukas,
    I guess you used wrong values that's why it isn't working.
    You can use Workflow Actions > Update Related Record. Then Link: Users > Teams and in value choose the team which you need.
    After this all the users added to the Attendees will be added to the Team you indicated.
    Hi Katia,
    I think I wrote not too clearly. I would like the Team to which the user belongs to be added to the Teams in the Meeting. Like on screen.

    Leave a comment:


  • item
    replied
    Hello,

    //getMettingId
    $meetingId = entity\attribute('id');
    //getRelatedUsers
    $userIds=record\findRelatedMany('Meeting', $meetingId, 'users', 50);
    $i = 0;
    //loop on all userIds
    while($i < array\length($userIds),
    //getUserId
    $userId = array\at($userIds, $i);

    after.. i don't know

    Leave a comment:


  • Katia
    replied
    Hi Lukas,
    I guess you used wrong values that's why it isn't working.
    You can use Workflow Actions > Update Related Record. Then Link: Users > Teams and in value choose the team which you need.
    After this all the users added to the Attendees will be added to the Team you indicated.

    Leave a comment:


  • LukasShultz
    replied
    Somone have any idea where I made mistake?

    Leave a comment:


  • LukasShultz
    replied
    alter thanks for your interest in the topic.
    I would like the user who was added to the meeting as an 'attended user' to be able to see the entire content of this meeting with permissions read: team

    Leave a comment:


  • alter
    replied
    Hi, I'm not sure what exactly you are trying to achieve. Do you want users to see it in shared calender, or you want automatically add users to Attendees from the team you would set on meeting? Thank you.

    Leave a comment:


  • Workflow to add Teams for all attendees users of Meetings

    Hello,
    I have selected permission for meetings: read: teams.
    I would like to user could see meetings if they are in attendees users of meetings.

    I create workflow that add teams all attendees user of Meetings but it doesn't work. Could someone help?
    PHP Code:
    $idMyUsers = list(UsersIds);
    
    ifThen(
    $idMyUsers,
    (
    $idMyTeam = record\attribute('User', $idMyUsers, 'teamsIds');
    
    ifThen(
    $idMyTeam,
    (
    entity\addLinkMultipleId(
    'teams',
    $idMyTeam
    );
    )
    );
    )
    ); 
    
Working...