Discussions
Unassociate dormant bins
Hey Guys and girls, I'm looking to know if a helpful member will give me some advice on an issue that I've been working at for a few days now;
My idea is simple and I'm sure it would benefit other NetSuite users also.
Here is the draft userEvent script that I've been working on.:o
<span style="font-size:'"2"'">//This user event script renders bins available if there are no items left onhand in their respective bin. function userEventAfterSubmit(ItemFulfillment) { try { var fulfillment = nlapiGetNewRecord(); if (type == 'create') { var items = new Array(); var qtys = new Object(); for ( var int = 1; int &lt;= fulfillment.getLineItemCount('item'); int++) { var qoh = fulfillment.getLineItemValue('item','quantityonhand', int); if (qoh &gt; 0) { return; } else { fulfillment.SetCurrentLineItemValue('item', 'usebins', false); } } } } catch (e) { nlapiLogExecution('ERROR',e.getCode(),e.getDetails()); } } </span>