Melissa
01/08/2024, 7:40 PMcontext.type
as copy, but of course when you save, the type in the beforeSubmit changes from copy to create, which makes sense, but I need to know in a beforeLoad when a new transaction is coming from a copy or is actually newly create. Thank you!Anthony OConnor
01/08/2024, 7:50 PMcreatedfrom
? if that references another sales order then that would mean its a copy?Melissa
01/08/2024, 8:04 PMAnthony OConnor
01/08/2024, 8:17 PMMelissa
01/08/2024, 8:22 PMcreatedfrom
or the context.type
indicating a wayAnthony OConnor
01/08/2024, 8:24 PMMelissa
01/08/2024, 8:26 PMhttps://media.giphy.com/media/4Q05SFwqzqP9tTAIup/giphy-downsized.gif▾
Melissa
01/08/2024, 8:27 PMerictgrubaugh
01/08/2024, 9:18 PMCOPY
during beforeLoad
and set a hidden field value to something that your beforeSubmit
could pick up. It might be Yet Another Custom Field, but adding an "Is a Copy" checkbox that gets set during beforeLoad
of a COPY action should be detectable by a subsequent beforeSubmit
erictgrubaugh
01/08/2024, 9:20 PMbeforeLoad
, but I think this is worth a try.Anthony OConnor
01/08/2024, 9:26 PMerictgrubaugh
01/08/2024, 9:27 PMerictgrubaugh
01/08/2024, 9:27 PMerictgrubaugh
01/08/2024, 9:27 PMerictgrubaugh
01/08/2024, 9:28 PMAnthony OConnor
01/08/2024, 9:28 PMMelissa
01/08/2024, 9:28 PMNElliott
01/09/2024, 8:29 AMTimothy Wong
01/09/2024, 3:39 PMMelissa
01/09/2024, 3:45 PMClay Roper
01/18/2024, 11:31 PMAnthony OConnor
01/18/2024, 11:43 PMerictgrubaugh
01/19/2024, 2:58 AMNElliott
01/19/2024, 11:24 AMlet objSession = runtime.getCurrentSession();
to store data but you need to have a unique key since the data is visible across multiple instances of a UE script.
I have done this and used the recordid as the key on edit, but of course on create, before submit you don't have that so... back to the custom field, potentially added beforeLoad.Clay Roper
01/19/2024, 3:25 PM