else { if (request.getMethod() == 'POST') { // SUBMIT nlapiLogExecution('DEBUG', 'test'); // create inventory transfer var xfer = nlapiCreateRecord('inventorytransfer'); nlapiLogExecution('DEBUG', 'debug'); xfer.setFieldValue("subsidiary", 3); //xfer.setFieldValue("account", SAMPLE_ACCOUNT); xfer.setFieldValue("memo", "Sample Inventory Transfer"); xfer.setFieldValue("location", 1); xfer.setFieldValue("transferlocation", 2); xfer.setLineItemValue("inventory", "item",1, itemId); id = nlapiSubmitRecord(xfer); nlapiLogExecution('DEBUG', 'xfer', id); nlapiLogExecution('DEBUG', 'test2'); } }