My Stuff
Comments
-
Actually re-reading your solution it sounds like you did that in the NS GUI and not in the cart. Is that correct? Is the value in the shipping cost field durable? i.e. Does it survive repeated edits of the sales order? Did you set up the associated shipping method with a flat rate of $0? Given the recent spate of questions…
-
Cool! does the shipping cost display in the cart?
-
This works with all types of fields but doesn't work with any field you can't set in list edit. It would be nice if the function would throw an error when called with an invalid field but if you call it with an invalid field it just returns silently. What's worse there are cases where you can test the field in a console…
-
does this help? You can run it in Firebug and use various means to deconstruct Netsuite's objects. This may help you server side but quite often server side structures are different from client side. If you are constructing the filters in code is there any reason you can't log the parameters as you construct each filter?…
-
Hi, Is there a way to send an email using nlapiSendEmail (or suiteflow) and NOT have the email recorded on the employee record? Any ideas would be appreciated. Thanks, Brian use nlapiSendEmail(fromEmpId, actualEmailAddress, ....) rather than nlapiSendEmail(fromEmpId, toEmpId...) when you use just an email address for the…
-
have you traced the value you are trying to set such that you know for sure you aren't setting it blank?
-
The files are a bit much to paste here. The files are available at: [LIST] [*]Suitelet file [*]Dialog Template - this file is referenced by the script parameter with id custscript_site_import_template [*]Library File - this file should be added to your suitelets folder and included as a library file for the suitelet…
-
Hi there. There are (at least) two approaches to this. 1. Import your file directly into your custom records but mark them somehow to indicate they are dirty. Then provide a way for your user to apply your user options to the uploaded records using a suitelet that kicks off a scheduled script with the custom options. 2. Do…
-
If all of your parts are some type of text you can construct your own multipart body. HOWEVER NS may re-write your content type to render that pointless. (e.g. https://usergroup.netsuite.com/users/showthread.php?t=25339) I'd just google a sample multipart body and see if you can post that successfully.
-
BTW the company id can be obtained from your context: e.g. updateFulfillmentPackages(username, password, nlapiGetContext().getCompany(), ff.getId(), getTrackingCodes(shipment));
-
cust.setLineItemValue('addressbook', 'state', line, 23); or cust.setLineItemValue('addressbook', 'state', line, 'MN'); either would set the state to Minnesota the 23 is Netsuite's internal id for the state code (what will be sent from an external lead page)
-
Actually I remembered I had tried this some time ago. recording the request showed that NS rewrites the content type header so the receiver can't tell that this is a multipart body. the header gets sent as content-type: text/xml; charset=UTF-8 [CODE] function testPost(request, response){ var p = encodeBody({hello:'there',…
-
In dynamic mode did you set the country first? Otherwise I'd bet you are wiping out the state when you do set the country.
-
as far as I know you can't do this directly with scripting. when I get to that point in processing a fulfillment I make a web services call to fill in the packages list. This requires you set up a user account with web services access and either hard code the credential in the script or store them in the script parameters.…
-
Hi Steve, 1. I haven't tested this in Netsuite formulas but escaping quotes in PL/SQL expressions is done by repeating a quote. e.g. 'this is ''my'' string' would be interpreted as a string with single quotes around the word my. 2. If you can get the suitelet url built in a formula then I'd just do that and include the…
-
I considered a pure-SuiteLet solution and was drawn to it as I would have total control, however the significant downside is that I lose the highlighting, footer filter and (I think) interactive sorting. If it was a list that I could dictate sorting and dismiss any requests from whiny users I would probably go with a pure…
-
Hi Evan, Thanks for the hint. I didn't have a target attribute set on my portlet. When trying to puzzle this out the help I was looking at didn't list the target attribute. I've added one now and at least "_blank" behaves acceptably. It opens the result in a new tab that appears to be meant for pop-ups -- it has none of…
-
nlapiGetContext().getUser(); If you are trying to use this in a script deployed on the web please search the user group archives for past discussions about this function.
-
A suitescript search can only find 1000 records at a time. If there are more than 1000 records in your lot then running this only once will leave out some records. I see you are already basing your search on a saved search so here's what you can do. [LIST] [*]Add a numeric formula field to the saved search results…
-
Sorry Steve, Referrer has always been browser specific. You can get at it in the request on a suitelet coming from an external link but I've never seen one on an internally generated link (which is kind of weird -- maybe NS filters them?). In your situation the solutions I have employed include: [LIST] [*]train users to…
-
Brett, did you ever come up with a work around for this? Sorry no. Still have to create a custom record for state codes.
-
If you know (or can know) client side what the landing page should be then you can achieve your goal as follows: [LIST=1] [*]set up your original form using a custom html template. You can include any markup and code there including custom javascript [*]in a script on the original form set a cookie with something to…
-
I have a Contact Group that I want to search against in a scheduled script. I can build a search in the UI for groups, but in the SuiteScript Supported Records Groups and Contact Groups are not listed. How can I use search for a group in script? Can I? Corey, You can certainly use a static group as search criteria. e.g.:…
-
Thanks for the example. A couple of comments. Your code will always double include the last item in each set that isn't the final set. Just the greaterthan test is sufficient. try: var searchresults = nlapiSearchRecord('item', '99', new nlobjSearchFilter('internalidnumber', null, 'greaterthan', pageMax)); Also your sample…
-
Corey, The h is merely a cryptographic hash of some sort that serves to uniquely identify the resource. It has nothing to do with the customer's email address. Unless someone else has stumbled upon how to generate the hash or has smuggled the details out of netsuite you are out of luck. I think a customer and I put in an…
-
What I do is include anything that is a "custom" value in a tag @customvalue@ in the email template. Then the script that sends emails first merges the template and then it replaces any custom tags. I don't use the Netsuite syntax for custom tags since you can't use it in attributes when people are editing templates with…
-
Excellent! Thanks for sharing the solution (of course it would be nice if it was documented) FWIW you might find the following easier to read/maintain. No escaped single quotes.: filters[0].setFormula("DECODE({addressinternalid}, '"+ internalID +"', '1', '0')");
-
if you make the sc param the id of a category page that should work. Once the customer logs in they'll be redirected to the category page. You can make that look like an info item. If this is a password retrieval system I'm hoping the password you send out is short-lived. If not I urge you to re-think what you are doing.…
-
NS hasn't implemented formulas for nlobjSearchFilter yet. The best you can do right now would be to do a search that includes the customer who has the address and pick the address from the results: e.g.: var x = nlapiSearchRecord('customer', null, new nlobjSearchFilter('internalid', null, 'is', '938'), [new…
-
re the function: function intVal(v){ return parseInt(v,10) ||0;} and then intVal(nlapiGetLineItemValue('item', 'quantityavailable', i)); which is just a little cleaner but it makes a difference when you have a number of statements and is a good example of simple functions helping with DRY. (including the ,10 in parseInt is…