1
0
-1

I am working on a project where client's system passes their application ID into Avoka platform as prefill data.

Is it possible we use that application ID as our Tracking Number?

I understand that we already have a Tracking Number Service which will generate the Tracking Number,

can we somehow get access to HTTPrequest object so I can extract the application ID and use that as our application's Tracking Number?

 The reason being the client wishes to build a application tracker on their system. When they create a new application, they want to pass that ID to us, if we do not have such ID, we will create a new application. If we do have that ID on our system, then they want us to retrieve the application based on that ID.

  1. Malcolm Edgar

    Transact also supports externally provided "Transaction Reference Numbers" which are recorded against the transaction. These are useful for associating externally significant numbers against a transaction such as a "Case Identifier", these values can be pre-filled from XML input data or via Groovy Script.

    regards Malcolm

  2. Larry Bunton

    HI Mike,

    While you can get the tracking number from an external source via a  you should consider.

    1. Lag time. The time to call another system and get back the tracking code will be added to the time to render the form.
    2. Tracking codes should not be simple increment and therefore easily guessable.
    3. Tracking numbers need to be UNIQUE otherwise exceptions will be thrown.
      Case numbers usually cover a number of transactions and hence are not unique.  

    Note: The way you have suggested doing it via prefill may not not have an issue with Lag.

    I would suggest using the external Transaction Reference Numbers as per Malcolm's comment.

    cheers

    Larry

CommentAdd your comment...

1 answer

  1.  
    2
    1
    0

    Hi Mike

    If you create a fluent tracking number service, you will have the access to http servlet request and you can extract and return it:

     

    import com.avoka.core.groovy.GroovyLogger as logger
    import com.avoka.tm.svc.*
    import com.avoka.tm.vo.*
    import javax.servlet.http.*
    class FluentTrackingNumberService {
        /*
         * Perform a transaction tracking number (tracking code) generation
         *
         * return: a globally unique tracking number value, values longer than 100 characters will be trimmed
         */
        String invoke(SvcDef svcDef, Form form, HttpServletRequest request, User user) {
              return request.getParameter('my-tracking-number')
        }
    }

     

    Regards
    Rado

     

      CommentAdd your comment...