Open item on Edit mode

Hi all.

I want to open an item on edit mode from Form button.
I'm using Aras12OP.
Lock the item in button click event, but opened tear-off form is not edit mode.
What should I do?

Regards

  • Hi,

    what query do you use to open the item? Maybe something like this?

    // get item
    ....
    myItem = myItem.apply();
    myItem.lockItem();
    // if (check if lock was successfull)...
    aras.uiShowItemEx(myItem.node,"tab view");
    return myItem;

  • Hi Mahrez,

    Both you and Angela have the right idea of locking the item before opening the form. In past versions of Aras Innovator, this would result in the item form being opened in edit mode. However, with the new updates to 12.0, we've removed the concept of locking the item from the client logic. Instead of locking, users can now Claim the item which prevents other users from editing it just like Lock did in older versions, but unlike Lock Claiming doesn't enable edit mode itself. 

    You can check the Gist linked below to find some sample code that worked for me. I've added some additional comments in the Gist that explain in detail what the code does and how I found what functions to call.

    https://gist.github.com/cgillis-aras/f47b4fa01d89919001998ab11ce03d96

    I hope this helps!


    Chris

    Christopher Gillis

    Aras Labs Software Engineer