CodeExplorer setDocumentMediaFileId example
$documentStruct =
$this->documentGenerator->
generate( $documentType->
getTechnicalName(),
[$document->
getOrderId() =>
$operation],
$context )->
getSuccess()->
first();
if ($documentStruct === null
) { return null;
} $documentMediaId =
$documentStruct->
getMediaId();
$document->
setDocumentMediaFileId($documentMediaId);
return $documentMediaId;
}}