Hello :wave: I have an attach file script (see be...
# suitescript
t
Hello 👋 I have an attach file script (see below) that works totally in Sandbox. But when we push it in production it doesn't work. Has anyone experience something like this before?
function attachFileToRecord(_fileId_, _recordType_, _recordId_) {
try {
_record_.attach({
record: {
type: 'file',
id: _fileId_
},
to: {
type: _recordType_,
id: _recordId_
}
});
} catch (e) {
_log_.debug({title: 'attachFileToRecord', details: e});
}
}
d
Do you get any error?
t
No unfortunately I dont have
I added logs before the try catch to check the parameters and all parameters looks good
d
maybe its about premissions
t
I even have a FULL permission on 1 of the records that I've been attaching the file on.