on 01-02-2012 8:15 AM
Hi,
When I include a Phase with different tasks and the tasks with Role assignment in to a project, the task-role assignment is not gettting copied.
But when I use a Project template with the same Phase-task-Role task assignments, every thing is getting copied. But for Include phase the task-role assignments are not getting copied.
Can anybody help me how to achieve this functionality?
Thanks and regards,
Jashua
Hi Jashua,
Indeed, the standard include function do not cover the role-task assignments.
To achieve this, one option would be to implement BADI dpr_attributes, method set_defaults_upon_copying, and re-create the role-task assignments from the template data in that step.
Regards,
Matthias
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Matthias,
Thank you very much for your reply.
Here I have a question. Because the method ''SET_DEFAULTS_UPON_COPYING' of the class 'CL_DPR_TASK' is being called in the both cases Create project from template and include a phase in to an existing project. So, if I implement the BAdI method I think it would effect both the times. wouldn't it create the role task assignments twice at the time of project creation.
Also please give me some more details about creating the role-task assignments in this BAdI.
Thanks and regards,
Jashua
Edited by: Jashua Andra on Jan 4, 2012 12:42 PM
Hi,
You're right, the BADI is called in both cases.
What you can do is first to check if the task has any role assignments with method from class cl_dpr_task: lr_task->mr_participant_links->get_all( ).
If populated ==> it means you are creating the task from template, nothing to do.
If empty ==> you can implement your logic to rebuild the role assignment.
To create a role assignment, you can use method: lr_task->mr_participant_links->add
Matthias
Hi Matthias,
We have the same problem and we cannot understand how to copy from the template the role-assignment with the Include function.
It seems to us the method ''SET_DEFAULTS_UPON_COPYING" can only set a default role and it is not possible to copy the role coming from the source task. I have input parameters that are not useful to get the role assignment from template.
Can you suggest us anything?
Thank you.
Laura
User | Count |
---|---|
11 | |
6 | |
1 | |
1 | |
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.