Skip to main content
Answer

Hashing Orders

  • June 28, 2021
  • 2 replies
  • 50 views

jimsproul
Freshman I

Greetings All!

We are concerned about order verification on our integration with Acumatica. Because we can transactionalize updates on the Acumatica side we want to be sure all the data arrived.

Are you aware of any way we can generate a “hash total” of Inventory ID or something at the Header level that reflects all the associated line items.  

This would be similar to doing an MD5 hash for downloads.

Thanks in Advance

  • Jim Sproul, Polywood

Best answer by Gabriel Michaud

Hi Jim,

There’s nothing “built in”, but by using the customization platform an extension can be built that will calculate this hash in C# and store the value in a field. I’m thinking of the following approach:

  1. Add a new custom field at the header level on the page where the hash will be saved
  2. Create a graph extension on the page
  3. Override the Persist method to run the hash calculation logic on save
  4. Concatenate all the values to be used to calculate the hash into a string
  5. Send this string to MD5 or other hashing function. C# sample here
  6. Store the result into the field created in step 1.

2 replies

Gabriel Michaud
Captain II
Forum|alt.badge.img+11

Hi Jim,

There’s nothing “built in”, but by using the customization platform an extension can be built that will calculate this hash in C# and store the value in a field. I’m thinking of the following approach:

  1. Add a new custom field at the header level on the page where the hash will be saved
  2. Create a graph extension on the page
  3. Override the Persist method to run the hash calculation logic on save
  4. Concatenate all the values to be used to calculate the hash into a string
  5. Send this string to MD5 or other hashing function. C# sample here
  6. Store the result into the field created in step 1.

jimsproul
Freshman I
  • Author
  • Freshman I
  • July 2, 2021

This is great, Thanks!