Clarity Service Management

Expand all | Collapse all

Validation before save

Jump to Best Answer
  • 1.  Validation before save

    Posted 05-04-2019 09:34 PM

    Hi ,

    I want to have some validation checks before save the change order.

    If zischgexist is "NO" and change type is other than standard , validation should not allow the change order to save.

    It should give some error message.


    Where should i write this logic?

    Can anyone help me on this?




  • 2.  Re: Validation before save

    Posted 05-06-2019 12:46 PM

    In your form (htmpl) file, define a function named preSaveTrigger2. Your JavaScript should return True if the conditions are met and False if they are not met.

  • 3.  Re: Validation before save
    Best Answer

    Posted 05-06-2019 01:53 PM



    Something similar to what is discussed on the below URL should help:



    See also:



    This is all in line with what Lindsay_Estabrooks has mentioned.



    Kind Regards,


  • 4.  Re: Validation before save

    Posted 05-10-2019 01:26 PM

    I have tried the approach suggested in the below url and it worked


    Thanks Brian_Mathato

  • 5.  Re: Validation before save

    Posted 05-06-2019 03:08 PM

    It might not be neccessary yet, but in my oppinion, the only "correct" place to add application logic is at the object layer.
    Only then all interfaces will have the same logic, standard GUI, xFlow , SOAP and REST API and  fragment scripts.
    That means, you need to declare a majic trigger and define/write some spell code.
    You might find many examples in the communities.