``` else if (customerEDI == 'T') { so2...
# suitescript
d
Copy code
else if (customerEDI == 'T') {
          so2Invoice.setFieldValue('customform', 172);
          if (customerEntity = '2766' || '273084') so2Invoice.setFieldValue('custbodyintegrationstatus', 7);
          else so2Invoice.setFieldValue('custbodyintegrationstatus', 1);
        }
I am a noob, can someone point out to me how to make this set status to 7 is the entity is either of these 2 internal IDs? this apparently does not work and tags every entity as 7
j
if (customerEntity = '2766' || '273084')
You only have one equals sign so this is an assignment expression. Also
'2766' || '273084'
does not do what you think it does. Without getting overly in depth your code is doing this:
Copy code
customerEntity = '2766';
if (customerEntity)
What you probably want is this
if (customerEntity === '2766' || customerEntity === '273084')