My Stuff
Comments
-
Use empty string ('') to blank out a dropdown
-
It is not possible. The Invoice must be correctly created via nlapiTransformRecord() for the createdfrom link to be set. It is the only way.
-
NS is riddled with spots where script don't trigger. In this case I have a vague memory that maybe the after submit triggers, but not the before submit? Best thing to do is place a script with an nlapiLogExecution deployed on beforeLoad, beforeSubmit and afterSubmit and trigger a WO through the SO. You will then know which…
-
Why do you need a checkbox at all? Just have the WS pick up any order where Committed is greater than 0.
-
If you are client side, then you can use native javascript methods to pull URL, i.e. window.location
-
Hi Jay, In my experience, this is one (of many) hidden references. As far as I know, you'll need to call the search to get that info.
-
Well... you CREATE the Transfer Order, right. And then you do var itemCount= transferOrder.getLineItemCount('item'); How can a freshly created Transfer Order have any line itrems?? It doesn't, so that loop gets skipped and then you try to submit a TO without any lines, which NS won't let you do.
-
If it weren't for Discounts, this would be easy. The discounts kill you. The only way is to use scripting to open up the SO and then cycle through all the lines. For every line, though, you then need to check if the next line(s) relate to it and affect it, like a discount line. You also need to ignore subtotals and stuff…
-
Is this running in the After Submit trigger perchance?
-
If you have both a form-level client script and a record-level client script, you could have conflicts between the two. Basically any situation where you have more than 1 client-side script attached to a record type, you can have conflicts.
-
If you are doing an After Submit opoeration you need to load and submit the record object if you plan on setting anything. In any case, best practice is indeed to do this type of operation in beforeSubmit.
-
Like a User Note? I think that would be a sub-record, you'd need to nlapiCreateRecord() that thing and attach it to the Customer.
-
They certainly are, no issue there.
-
A User Event script would be simpler and more logic in this case
-
Yes client-side scripts will have problems if you use similar named functions as well as any similar-named "global" variables. Always ensure your client-side global-visibility components (functions and any global variables) are uniquely named.
-
Try moving your code to Post Sourcing of 'item'. e.g. function postSourcing_SO_CloseProcess_Main(type, name, linenum){ var returnValue = true; if (name == 'item'){ var mrvalue = nlapiGetLineItemValue('item', 'custcol_mr_value',linenum) alert(mrvalue); } return returnValue; }
-
What do you mean "don't accept"? Worse case if you provide an invalid field name the command will just return a blank value. So long as you actually have departments enabled on the line, then record.getLineItemValue('item', 'department', linenum) will work.
-
Please refer to this SuiteAnswer article illustrating how to use Search Filter Expressions in scripting: https://netsuite.custhelp.com/app/answers/detail/a_id/30270
-
Yeah it's not unusual for beforeSubmit scripts not to perform sourcing. You can go fetch the average price yourself, or, you can switch the script to afterSubmit, starting the code with nlapiLoadRecord(nlapiGetRecordType(), nlapiGetRecordId(), {recordmode:"dynamic"}). Loaded in dynamic mode, it will probably source better.…
-
I would NOT do a client-side. That will offer the worst possible performance. Unless you absolutely need users to see the results before saving, go with After Submit.
-
Yes, this is a known issue within Javascript (and many other languages in fact). You can do some Google research, but he's a basic article I found explaning very briefly the problem: http://floating-point-gui.de/basic/
-
No. You need to have a credit card decline on the SO. This seems fairly unlikely to be viable, so I'd probably look into some sort of alternative, such as a custom checkbox that says "Credit Card Hold From Import" combined with using the SO's normal Pending Approval functionality. You could use a script to securely tie the…
-
Client side scripting does not normally trigger on view mode... That being said, without checking the documentation, nlapiGetContext().getExecutionContext() should still work. If not, grab the URL params and look if you have &e=T. If you do, you're in edit mode.
-
Are you talking about the Credit Card hold?
-
Nope, still broken picture
-
Well the simplest way would probably be to configure your reader to stop doing an "enter" key after it scans. If you can't do that for some reason, you can try putting a client-side script on the suitelet with OnSave return false until the user ticks in a box somewhere or something, indicating he's done with the page.
-
Client scripts work with the Permissions and restrictions of the user executing them. This is by design. You will need to redesign your solution so that it is not executed by a Client script. You should be able to translate your logic to have a Suitelet do it, for example.
-
I don't see any reason why it wouldn't work, I have done this many times. Is there maybe a problem getting a value inside myVar?
-
*Cocks eyebrow*. That shouldn't happen. Can you post your code? I am curious..
-
Well, I don't think so, not like NetSuite does it, BUT, nothing is stopping you from creating an interco SO in general. All it takes is an interco Customer on it to make it an interco. I'd have to do some poking around, but I think maybe the only downside would be that it wouldn't hook in very well with standard interco…