DicomModalitiesInDatabase Issue

74 views
Skip to first unread message

Santhosh

unread,
May 22, 2020, 2:15:10 AM5/22/20
to Orthanc Users
Hi

I have enabled DicomModalitiesInDatabase to true  after enabling mysql plugin
But it is not clear in which table of the mysql database the modality details will be stored.
Even after restarting the server no changes happening in my database tables.

Can someone guide me how to add modalities in the database? to which table the details to be added?

Thanks in advance

Regards

Santhosh

James Manners

unread,
May 22, 2020, 2:21:17 AM5/22/20
to Santhosh, Orthanc Users
Hi Santosh,

Rather than direct database access, which should be avoided, you can use the REST api to manage remote modalities. You can find an example here. https://book.orthanc-server.com/users/rest.html?highlight=modalities#id2

James

Binary Logo
James Manners • Director
Suite 3, Level 2, 10 Queens Road, Melbourne, Victoria 3004, Australia

On 22 May 2020, at 4:15 pm, Santhosh <vetzon...@gmail.com> wrote:


--
You received this message because you are subscribed to the Google Groups "Orthanc Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to orthanc-user...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/orthanc-users/be8b54f4-3df1-47f7-a881-de8df2db1916%40googlegroups.com.
Message has been deleted
Message has been deleted

Santhosh

unread,
May 22, 2020, 8:30:33 AM5/22/20
to Orthanc Users
Thank you James for the reply

I have done as per the example , but nothing happening in database
I have used a php curl request to add modality
when i call it , nothing return and nothing happening
can you please tell me which database is get updated, so that I can ensure that the request being updated
my code is as below




$handle = curl_init();

$username="username";
$password="password";
$postData ='{"AET" : "ORTHANCC", "Host": "127.0.0.1", "Port": 2002}';

curl_setopt($handle, CURLOPT_URL, $url);
curl_setopt($handle, CURLOPT_RETURNTRANSFER, true);
curl_setopt($handle, CURLOPT_USERPWD, "$username:$password");
curl_setopt($handle, CURLOPT_HTTPAUTH, CURLAUTH_BASIC);

curl_setopt($handle, CURLOPT_CUSTOMREQUEST, "PUT");

curl_setopt($handle, CURLOPT_POSTFIELDS, $postData);   
$output = curl_exec($handle);
curl_close($handle);
$json = json_decode($output , true);
print_r($json);


Thanks

Santosh

James Manners

unread,
May 22, 2020, 8:44:59 AM5/22/20
to Santhosh, Orthanc Users
Hi Santosh,

You can use a get request to /modalities to return all know modulators. This will tell you if your request worked. 

James

Binary Logo
James Manners • Director
Suite 3, Level 2, 10 Queens Road, Melbourne, Victoria 3004, Australia

On 22 May 2020, at 10:30 pm, Santhosh <vetzon...@gmail.com> wrote:


--
You received this message because you are subscribed to the Google Groups "Orthanc Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to orthanc-user...@googlegroups.com.
Reply all
Reply to author
Forward
0 new messages