0

I am coding in C#, using the SuiteTalk Web Services to create Item Fulfillment records from existing sales orders. I am not sure how to configure the inventory detail, when serial numbers are specified on items.

I successfully generate the item fulfillment and can update NetSuite when items are not serialized. When items are serialized, I get the following error:

"Please configure the inventory detail in line 1 of the item list."

I run through each line item and check whether it is fulfilled, after which I add it to my new item fulfillment list as follows:

List<ItemFulfillmentItem> ifitems = new List<ItemFulfillmentItem>();

ItemFulfillmentItem ffItem = new ItemFulfillmentItem();
ffItem.item = ifitemlist.item[b].item;
ffItem.orderLineSpecified = true;
ffItem.orderLine = ifitemlist.item[b].orderLine;

ffItem.quantity = msg.despatchItems[i].qtyDespatched;
ffItem.quantitySpecified = true;
ifitems.Add(ffItem);

ItemFulfillmentItemList ifitemlistToFulfill = new ItemFulfillmentItemList();
ifitemlistToFulfill.item = ifitems.ToArray();
newItemFulfill.itemList = ifitemlistToFulfill;

WriteResponse writeRes = _service.add(newItemFulfill);

Any help would be appreciated.

Yared
  • 2,206
  • 1
  • 21
  • 30
Charl
  • 812
  • 1
  • 8
  • 22

2 Answers2

1
  1. You need to add and inventory detail subrecord for each line item
  2. Then you will have to set the serialnumber* and **qty

You cannot add a comma-separated list as you must specify the qty

I am not familiar with the C# api, only the JS and Java api which all have the same workflow (inventory detail subrecord)

Coldstar
  • 1,324
  • 1
  • 12
  • 32
  • I ended up creating an inventory assignment for each serial number used per order line number and setting the quantity for that serial number on the Inventory Assignment. I also set the quantity of the line item to the total of all serialized items. The serialNumbers field also had to be used by adding all serial numbers in a comma separated list. This works by updating NetSuite as expected. – Charl Mar 08 '18 at 09:11
0

On the item fulfillment item, there is a text field called serialNumbers. Add them by way of a comma separated list.

Suite Resources
  • 1,164
  • 8
  • 11
  • I have tried this, but I still get the same error. There is an "inventoryDetail" field, but this doesn't seem to be what i'm looking for. – Charl Nov 09 '17 at 13:28