let me ask this question: I have a case on local drive that needs to be sent to a remote modality(not Orthanc).
#upload dicoms to local Orthanc
$ProgressPreference = 'SilentlyContinue'
Get-ChildItem -Path (join-path $process "STAGE") -Recurse -Exclude "DICOMDIR" | where { ! $_.PSIsContainer } | Foreach-Object {
}
$studyid=$reply.ParentStudy
#send SEND results to modality
$body = @{
Level = @('Study')
Resources = @($studyid)
Synchronous = $false
StorageCommitment = $false
} | ConvertTo-Json -Depth 3
#send studyid to remote modality
try{
$id = Invoke-RestMethod -Uri $Uri -Method Post -Body $body -ContentType 'application/json'
}
catch{
Write-Host "Something went wrong sending study"
}
#monitor job every 5 seconds
if ($id.ID -ne $null) {
do {
$check = Invoke-RestMethod -Uri $Uri -Method Get
Start-Sleep -s 5
}
while($check.State -ne "Success")
}
Write-Host "Case sent to remote modality - COMPLETE"
#delete SEND results from Orthanc
try{
}
catch{
Write-Host "Something went wrong deleting local study"
}
Does it make any difference for the remote modality? (other than taking longer with the second approach) Will the remote modality see that data is coming from the same AE title?