AW: Step agents - superior of superior.

Michael Kemmler Michael.Kemmler at HVBSystems.com
Thu Aug 22 02:21:58 EDT 2002


Hi all,
 
if you have a Organisation Plan in HR, build a new step like this example.
With the SWX_GET_MANAGER - function you get the next higher superior (A12)
in the Org. Plan. We use it to sent at the next step a email
(sendtaskdescription) to
the superior.
 
Regards,
Michael Kemmler
 
-
begin_method ermittle_email_von_fk changing container.
data:
      adressstring like soxna-fullname,
      adresstype like soxna-type,
      personnelnumber like p0001-pernr.
 
* intern Data
data: count type n,
      ac_container like swcont occurs 0 with header line,
      adressstrings like soxna-fullname occurs 0 with header line.
 
  swc_get_element container 'PersonnelNumber' personnelnumber.
 
adresstype = 'G'.
 
ac_container-element = 'OBJID'.
ac_container-tab_index = '000001'.
ac_container-elemlength = '008'.
ac_container-type = 'N'.
ac_container-value = personnelnumber.
append ac_container.
ac_container-element = 'OTYPE'.
ac_container-tab_index = '000001'.
ac_container-elemlength = '002'.
ac_container-type = 'C'.
ac_container-value = 'P '.
append ac_container.
 
call function 'SWX_GET_MANAGER'
     tables
          actor_tab    = adressstrings
          ac_container = ac_container
     exceptions
          nobody_found.
 
if sy-subrc <> 0.
    endif.
 
loop at adressstrings.
  if adressstrings(2) = 'P '.
    delete adressstrings.
  endif.
endloop.
 
describe table adressstrings lines count.
 
if count ne 1 and count ne 2.
  clear adressstrings. refresh adressstrings.
  select single yy_dd_emailadr from yyp_dd_email into adressstring
                      where yy_dd_postfach eq 'REKLAMATIONEN'.
endif.
 
read table adressstrings index 1 into adressstring .
 
if adressstring cs '@'.
    adresstype = 'U'.
endif.
 
swc_set_element container 'Adressstring' adressstrings.
swc_set_element container 'AdressType' adresstype.
end_method.
 
 
 
 
 
 
 
> -----Urspr|ngliche Nachricht-----
> Von:  Ernest Liczki [SMTP:eliczki at deloitteCE.com]
> Gesendet am:  Donnerstag, 22. August 2002 07:54
> An:   SAP-WUG at MITVMA.MIT.EDU
> Betreff:      Re: Step agents - superior of superior.
>
> Hi all,
>
> I need something very similar, but for the purchase requisition release
> WF.
>
> The scenario is:
>
> 1. The first level approval (release code 01) is done by the user A (more
> users possible from the organization - solved by the user exit -
> enhancement
> M06B0001).
>
> 2. The second level has to be done by his superior B.
>
> 3. And so on, the next level by the superior of the previous superior -
> user
> C.
>
> The problem is that the WS00000038 (Workflow for requisition release) is
> started every time as a new instance with new release code and therefore
> the
> (_WI_ACTUAL_AGENT) could not be used for the next level determination.
>
> I believe that the best solution is to find the previous agent from the PR
> release history.
> Did anybody of you try to find that last user released the PR, is there
> any
> suitable function module for that or rather I have to start my own ABAP
> coding ?
>
> Thank you very for your help.
>
> Best regards,
>
> Ernest
>
> -----Original Message-----
>> From: Shaelene Hooper [mailto:Shaelene.Hooper at intelligroup.co.nz]
> Sent: Wednesday, August 21, 2002 7:34 PM
> To: SAP-WUG at MITVMA.MIT.EDU
> Subject: Re: Step agents - superior of superior.
>
>
> Hi Abby
>
> You could bind the actual agent (_WI_ACTUAL_AGENT) of the step 1 dialog
> workitem back into the workflow container.  To do this, you would need to
> create a workflow container element of data type
> WFSYST-ACT_AGENT.   You would then bind this workflow container element
> into
> the agent assignment of your next task.
>
> Regards
> Shaelene
>
>         -----Original Message-----
>         From: Abby Dywan [mailto:abby.dywan at us.pwcglobal.com]
>         Sent: Wed 08/21/2002 11:57 AM
>         To: SAP-WUG at MITVMA.MIT.EDU
>         Cc:
>         Subject: Step agents - superior of superior.
>
>
>
>         Hi all -
>
>         I am trying to figure out how to get the superior of a superior to
> be an
>         agent of a step.  My workflow goes something like this.
>
>         Step 1 - Assigned agent - superior of workflow initiator
>
>         Step 2 - Assigned agent - superior of superior.
>
>         Step 3 - Assigned agent - superior of superior of superior.
>
>         Unfortunately, I can't use positions to do this because the
> initiator will
>         be at all different levels.  I'm trying to figure out how to read
> the
>         superior from Step 1 into the workflow container to use to
> determine
> the
>         superior in the Step 2.  Does anyone have any suggestions as to
> how
> I can
>         do this?
>
>         Any help would be appreciated - I've been playing with standard
> roles
>         trying to do this but I'm wondering if it will require a custom
> role...
>
>         Thanks so much!
>         Abby  Dywan
>         PwC Consulting
>         404 808 3974
>         _________________________________________________________________
>         The information transmitted is intended only for the person or
> entity to
>         which it is addressed and may contain confidential and/or
> privileged
>         material.  Any review, retransmission, dissemination or other use
> of, or
>         taking of any action in reliance upon, this information by persons
> or
>         entities other than the intended recipient is prohibited.   If you
> received
>         this in error, please contact the sender and delete the material
> from any
>         computer.
>
>
>
>
>
> -------------------
> Privileged/confidential information may be contained in this message. This
> communication is confidential and intended solely for the addressee(s).
> Unauthorized distribution, modification or disclosure of the contents may
> be
> unlawful. If you receive this in error, please notify the sender and
> delete
> it from your system.  If you are not the addressee indicated in this
> message
> (or responsible for delivery of the message to such person), you may not
> copy or deliver this message to anyone. Please advise immediately if you
> or
> your employer does not consent to Internet e-mail for messages of this
> kind.
> Opinions, conclusions and other information in this message that do not
> relate to the official business of Deloitte & Touche shall be understood
> as
> neither given nor endorsed by it.  Views expressed herein do not
> necessarily
> reflect those of Deloitte & Touche.
 


More information about the SAP-WUG mailing list