u/Born_Tap_3787

GENERATE OUTBOUND DELIVERY BY OTHER TRANSACTIONS

GENERATE OUTBOUND DELIVERY BY OTHER TRANSACTIONS

Hello everyone.

Would like some few suggestions regarding this situation:

Goal: Build a button on custom transaction A (specifically purschase order, but could be by other type like import bill or item receival) to generate transaction B (outbound delivery specifically), and priority is to copying the itens from A.

One of the many test i tried:

1 - Record.transform

https://preview.redd.it/pqib4nkcyp0h1.png?width=586&format=png&auto=webp&s=5db09ec77ba55a8762d7c36a7d3e1910e880af15

2 - record.create + manual line copy

Creating the destination record and copying lines works fine until I hit inventorydetail. The source items have inventorystatus ("NOVO" / ID 1) and serial numbers. Setting these on the destination always fails:

  • INVALID_FLD_VALUE: Invalid 1 for inventorystatus
  • Invalid inventorystatus reference key NOVO

Without inventorydetail, lines won't commit: USER_ERROR: Configure inventory details / Please enter value(s) for: Inventory Status, Serial Number.

3 - User Event on the source Import Bill transaction

Even a minimal beforeLoad that just calls form.addButton() crashes the page entirely with the generic "An unexpected error has occurred" screen. No logs in Unhandled Errors or Execution History. Deactivating the deployment immediately fixes the page. Other native and bundle User Events on the same Custom Transaction work normally.

Questions

  1. Is there a documented way to register a custom transformation between two Custom Transactions, or is Oracle's list truly fixed?
  2. Why would a minimal User Event with just addButton crash a Brazil Localization Custom Transaction?
  3. Has anyone successfully copied inventorydetail (with inventorystatus + serial numbers) between two transactions via SuiteScript?
  4. Would Workflow's "Add Button" + "Create Record" actions work better than User Event + Suitelet here?

Any pointers appreciated. Thanks!

reddit.com
u/Born_Tap_3787 — 2 days ago