$(function () { pageContext.i18n.modTalk = 'moderation talk'; pageContext.i18n.replyToComment = 'Reply'; pageContext.i18n.modTalkEmpty = 'moderation talk is empty'; pageContext.url.getModTalk = "/comments/%25ID%25/listModTalk.json"; pageContext.url.possibleCommentRecipients = "/comments/%ID%/possibleRecipients.json"; pageContext.url.commentEdit = '/comments/%25ID%25/edit.html'; pageContext.url.commentView = '/comments/%ID%/view.html'; pageContext.i18n.commentVisibility = { 'full': 'Viewable by all users', 'op': 'Viewable by the original poster', 'mod': 'Viewable by moderators', 'opAndMod': 'Viewable by moderators and the original poster', 'other': 'Advanced visibility', 'dialogTitle': 'Comment visibility', 'selectGroups': 'Visible to groups', 'selectOther': 'Other recipients', 'selectOriginalPoster': 'Original poster', 'selectModerators': 'Moderators', 'selectAssignees': 'Asked to answer users' }; pageContext.i18n.commentMenuLabels = { 'comment-edit': 'comments.menu.edit', 'comment-delete': 'comments.menu.delete', 'comment-convert': 'comments.menu.convert' };pageContext.i18n.answer= { bestAnswer: 'Best Answer', controlBar : { accept: 'Accept', unaccept: 'Unaccept', acceptCommand: 'Accept this answer as correct', cancelAcceptedCommand: 'Remove this answers accepted status' } }; window.croles = { u: false, op: false, m: false, og: false, as: false, ag: false, dc: false, doc: false, eo: false, ea: false }; tools.init({ q: { e: false, ew: false, eo: false, r: false, ro: false, d: false, dow: false, fv: false, c: false, co: false, p: false, tm: false , ms: false, mos: false }, n: { f: false, vf: false, vfo: false, vr: true, vro: true, c: false, co: false, vu: false, vd: false, w: false, wo: false, l: false }, c: { e: false, eo: false, d: false, dow: false, ta: false, tao: false, l: false }, a: { e: false, ew: false, eo: false, d: false, dow: false, a: false, aoq: false, ao: false, tc: false, tco: false, p: false, tm: false }, pc: croles }, { tc: true, nsc: true }); commandUtils.initializeLabels(); }); Skip to Content
avatar image
Former Member

logResourceStatusChanged for specific date_time


Hi Experts,

on SAP ME 15.0 we are trying to update the resource status by calling the papi service: logResourceStatusChanged

<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:mep="mepapi:com:sap:me:production" xmlns:prod="http://www.sap.com/me/production">
   <soapenv:Header/>
   <soapenv:Body>
      <mep:logResourceStatusChanged>
         <!--Optional:-->
         <mep:Site>GPE</mep:Site>
         <!--Optional:-->
         <mep:Request>
            <!--1 or more repetitions:-->
            <prod:logResourceStatusChangedList>
               <prod:resourceRef>ResourceBO:GPE,MASCHINE1</prod:resourceRef>
               <prod:resourceStatusRef>StatusBO:GPE,1</prod:resourceStatusRef>
<!--StatusBO:GPE,5-->
               <!--Optional:-->
               <prod:dateTime>2014-08-08 13:51:01</prod:dateTime>

            </prod:logResourceStatusChangedList>
         </mep:Request>
      </mep:logResourceStatusChanged>
   </soapenv:Body>
</soapenv:Envelope>

Response:

<SOAP-ENV:Envelope xmlns:xs="http://www.w3.org/2001/XMLSchema" xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">

   <SOAP-ENV:Body>

      <ns3:logResourceStatusChangedResponse xmlns:ns4="mepapi:com:sap:me:reasoncode" xmlns:ns2="http://www.sap.com/me/production" xmlns:ns3="mepapi:com:sap:me:production">

         <ns3:Response>

            <ns2:responseList>

               <ns2:resourceTimeLogRef>ResourceTimeLogBO:GPE,ResourceBO:GPE,MASCHINE120140808.144229.564</ns2:resourceTimeLogRef>

            </ns2:responseList>

         </ns3:Response>

      </ns3:logResourceStatusChangedResponse>

   </SOAP-ENV:Body>

</SOAP-ENV:Envelope>

As you see, the response is positiv and I can see the change in the RESOURCE_TIME_LOG table as well. However the tag <prod:dateTime> doesn't seem to have any impact. I was assuming that <prod:dateTime> would eventually set the START_DATE_TIME, but that's not the case. The date is not even validated.

So my question is: What is <prod:dateTime> used for or can it be completely ignored?

thanks for your help.

cheers,

Georg

Add comment
10|10000 characters needed characters exceeded

  • Get RSS Feed

1 Answer

  • Best Answer
    Aug 08, 2014 at 06:14 PM

    Hello Georg,

    I check JavaDoc and it says that this is the date/time this event took place. If not given, uses the current time.
    So, I would expect it to be accepted. Could you try to set data in another format? For example:

    2014-08-08T14:21:20.000+02:00

    Br,

    Alex.

    Add comment
    10|10000 characters needed characters exceeded

    • Former Member

      Hi Alexander,

      you are absolutely right. It works the way you described if the date format matches your example.

      thanks a lot.

      Georg