Hi All, Do any one knows property events that are available in ARAS and when they are triggered ? eg. OnEditFinish,onedit and etc Property is on Item and i need to write method which will trigger whenever it's property is updated. Please help

Property events

Parents
  • Hello,

    The Property events inside of Innovator are client-only events that trigger whenever a user edits the property through a field on a form or through a cell in a grid. I've found the best way to determine when exactly these events are triggered is to throw a debugger; statement into the JavaScript method you attach and open the browser developer tools (typically launched by pressing F12). You can then edit a property using either of the options listed above to see exactly when the property is triggered.

    Just based on your description, my guess is that the OnEditFinish event is going to be best suited for your use case. However, could you elaborate a bit more on exactly what you'd like this method to do?


    Chris

    Christopher Gillis

    Aras Labs Software Engineer

  • Thanks Chris for the reply.

    I have a 3 Fields on form corresponding to 3 properties.

    data type of property 1 is "Item"

    data type of property 2 is Foreign which is pointing to some property of Property 1

    Data type of property 3 federated

    I need to populate property 2 value on property 3. I was trying with field event of property 2 (on change) to populate value of property 2 on property 3. But since it is foreign , it is disabled. Field events doesn't work. 

    Same thing i tried with property 1, but that is search dialog where field event doesn't serve the purpose.

    Now, trying with Property events, where only onsearchdialog is getting triggred on property 1. 

    I hope this gives clarification.

    Any suggestion chris.

    Thanks in advance

  • Hello,

    I'm not sure I fully understand this use case. Typically, foreign and federated properties are disabled entirely since the data is pulled from another source. These properties are never "edited" because they don't really hold the value themselves. Because of this, you won't be able to launch any edit events from these properties.

    If you're trying to do some kind of validation of the data for your foreign and federated properties, you will need to add your edit events onto the data source of these properties.

    Chris

  • I agree with you on foreign and federated property.

    In use case above, as foreign property is from Property 1 which is of datatype Item which supports field events and can be edited by selection through search dialog or simply entering text(keyed_name).

    Field events work good when text is entered but when value is changed by selecting a item through search dialog, field events not serving the purpose.

    The same i was trying with property event. Only onsearchdialog event - method is getting triggred. Other events like onedit,oneditfinish or oncellchange not getting triggred.

    Hope it gives clarification

  • Hi Arg,

    I would expect that the event would fire even if the value was being populated from a search dialog. I'll file this as an issue internally. For the time being, I'd recommend finding an alternative approach to accomplish the same functionality you're looking for.

    If you're trying to do some kind of validation of the data, it might be better to simply limit the items that a user can select from in the search dialog. You can look at this blog post for some examples of how to do this kind of filtering of a search dialog.

    It might also be better to handle this inside of an onBefore or onAfterUpdate server event. Using a server event will also help run the logic if the item ever gets edited from some other server method or from another application.

    Chris

  • Server events sounds good.

    Event is not getting triggered when populated through search dialog. 

    I was not trying to restrict value but get the value when user finishes the selection. I will try with server events.

    Thanks for help and please let me know if there is way out through Field/Property events as well

  • Hi Chris,

    I achieved it through server events - OnBeforeUpdate,OnAfterAdd and OnAfterUpdate.

    Thanks for the suggestion.

Reply Children
No Data