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