on 11-19-2015 12:49 PM
Hello,
I have a task A (CL_DPR_TASK_O), where some roles are assigned and I have to copy all of the assigned roles to Task B (also C_DPR_TASK_O)
I already found out, that the roles are in task A->MR_PARTICIPANT_LINKS->GET_PARTICIPANTS( ) but I have no idea how to copy them to Task B.
Hopefully someone can help me...
Hi Rene,
If you want to copy the roles of TASK A to TASK B and if both the tasks are already created then you have to write your own enhancement.
If you want to copy TASK A (already existing) and create TASK B with resource assignments then you can include your logic in the BADI DPR_ATTRIBUTES method SET_DEFAULTS_UPON_COPYING.
Once you have the Role GUIDS from TASK A then assign them to TASK B using
cl_dpr_participant -> mr_entity_links->add.
Pass the new task reference to the importing parameter ir_entity.
If you plan on using the BADI approach make sure you have validations for the origin type as this method will be called even during creation of the Project with template and will result in short dump.
Best Regards,
Priyatham
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
13 | |
7 | |
3 | |
2 | |
1 | |
1 | |
1 | |
1 | |
1 | |
1 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.