56 lines
1.5 KiB
PHP
56 lines
1.5 KiB
PHP
<?php
|
|
|
|
namespace App\Services\Pacs;
|
|
|
|
use League\Url\Url;
|
|
|
|
final class PacsUrlGen
|
|
{
|
|
public static function stoneViewer(string $study_uid): string
|
|
{
|
|
$url = Url::createFromUrl(config('pacs.viewer.stone.endpoint'));
|
|
$url->setPath('/stone-webviewer/index.html');
|
|
$url->setQuery(['study' => $study_uid]);
|
|
|
|
return (string) $url;
|
|
}
|
|
|
|
public static function ohifViewer(string $study_uid): string
|
|
{
|
|
$url = Url::createFromUrl(config('pacs.viewer.ohif.endpoint'));
|
|
$url->setPath('/ohif/viewer');
|
|
$url->setQuery(['StudyInstanceUIDs' => $study_uid]);
|
|
|
|
return (string) $url;
|
|
}
|
|
|
|
public static function ohifViewerMpr(string $study_uid): string
|
|
{
|
|
$url = Url::createFromUrl(config('pacs.viewer.ohif.endpoint'));
|
|
$url->setPath('/ohif/viewer');
|
|
$url->setQuery([
|
|
'hangingprotocolId' => 'mprAnd3DVolumeViewport',
|
|
'StudyInstanceUIDs' => $study_uid,
|
|
]);
|
|
|
|
return (string) $url;
|
|
}
|
|
|
|
public static function ohifSegmentation(string $study_uid): string
|
|
{
|
|
$url = Url::createFromUrl(config('pacs.viewer.ohif.endpoint'));
|
|
$url->setPath('/ohif/segmentation');
|
|
$url->setQuery(['StudyInstanceUIDs' => $study_uid]);
|
|
|
|
return (string) $url;
|
|
}
|
|
|
|
public static function archive(string $study_uid): string
|
|
{
|
|
$url = Url::createFromUrl(config('pacs.api.endpoint'));
|
|
$url->setPath('/studies/'.$study_uid.'/archive');
|
|
|
|
return (string) $url;
|
|
}
|
|
}
|