Where can i find the all fields names of purchase ...
# suitescript
m
Where can i find the all fields names of purchase orders for example these are the fields.
Copy code
Purchase_Order.setFieldValue('transdate', transdate);
    Purchase_Order.setFieldValue('inpt_customform1', Form);
    Purchase_Order.setFieldValue('vendor', Vendor);
    Purchase_Order.setFieldValue('inpt_currency7', Currency);
    Purchase_Order.setFieldValue('inpt_item', Item);
    Purchase_Order.setFieldText('quantity_formattedValue', '1');
    Purchase_Order.setFieldText('rate_formattedValue', '1');
    Purchase_Order.setFieldText('amount_formattedValue', '1');
    Purchase_Order.setFieldText('inpt_taxcode', 'VAT_MX:UNDEF_MX');
    Purchase_Order.setFieldText('grossamt_formattedValue', '1');
    Purchase_Order.setFieldText('tax1amt_formattedValue', '0');
    Purchase_Order.setFieldText('expectedreceiptdate', '24/6/2015');

            //var Purchase_Orderid =  1;//nlapiSubmitRecord( Purchase_Order , true, true);                   
            var submitRecord = nlapiSubmitRecord(Purchase_Order);//,true);
b
my personal guess is that most of those fields are useless
load an existing transaction that the script ran on
m
OK, but how do i know the required fields to create purchase order and vendor bill
b
any field that doesnt have a field (or the matching value set) was someone writing garbage code
to create a purchase order or vendor bill, learn how to create one in the ui
any fields you set in the ui are fields you need to set in script
m
If i load a single record using record object do you tink it has the same field name
b
yes, its why i told you the first approach