Update Contact’s Role via SuiteScript

Hi folkz,

How do we update the the contact’s role via SuiteScript? I tried the one below and its just throwing unexpected error.

Update Contact's Role via SuiteScript

record.attach({
    record: {
        type: record.Type.CONTACT,
        id:9309
    },
    to: {
        type: record.Type.CUSTOMER,
        id:9275
    },
    attributes: {
        role:3
    }
});
Beginner Asked on May 15, 2022 in SuiteScript.
Add Comment
1 Answer(s)

its working now

 

require([‘N’], N => {
N.record.attach({
record: {
type: N.record.Type.CONTACT,
id: 3226
},
to: {
type: N.record.Type.CUSTOMER,
id: 3225
},
attributes: {
role: -10
}
});
})

Beginner Answered on May 15, 2022.

You saved me so much time. Thank you!!

on May 23, 2022.
Add Comment

Your Answer

By posting your answer, you agree to the privacy policy and terms of service.
  • This site made possible by our sponsors:   Tipalti   Celigo   Limebox   Become a Sponsor   Become a Sponsor