Mercurial > hg > orthanc
comparison OrthancServer/ServerIndex.cpp @ 434:ccf3a0a43dac
EnumerationDictionary
author | Sebastien Jodogne <s.jodogne@gmail.com> |
---|---|
date | Wed, 15 May 2013 14:54:58 +0200 |
parents | aa50783f9550 |
children | d51186bf7602 |
comparison
equal
deleted
inserted
replaced
433:aa50783f9550 | 434:ccf3a0a43dac |
---|---|
209 ResourceType type = listener_->GetRemainingType(); | 209 ResourceType type = listener_->GetRemainingType(); |
210 const std::string& uuid = listener_->GetRemainingPublicId(); | 210 const std::string& uuid = listener_->GetRemainingPublicId(); |
211 | 211 |
212 target["RemainingAncestor"] = Json::Value(Json::objectValue); | 212 target["RemainingAncestor"] = Json::Value(Json::objectValue); |
213 target["RemainingAncestor"]["Path"] = GetBasePath(type, uuid); | 213 target["RemainingAncestor"]["Path"] = GetBasePath(type, uuid); |
214 target["RemainingAncestor"]["Type"] = ToString(type); | 214 target["RemainingAncestor"]["Type"] = EnumerationToString(type); |
215 target["RemainingAncestor"]["ID"] = uuid; | 215 target["RemainingAncestor"]["ID"] = uuid; |
216 } | 216 } |
217 else | 217 else |
218 { | 218 { |
219 target["RemainingAncestor"] = Json::nullValue; | 219 target["RemainingAncestor"] = Json::nullValue; |
703 break; | 703 break; |
704 | 704 |
705 case ResourceType_Series: | 705 case ResourceType_Series: |
706 { | 706 { |
707 result["Type"] = "Series"; | 707 result["Type"] = "Series"; |
708 result["Status"] = ToString(GetSeriesStatus(id)); | 708 result["Status"] = EnumerationToString(GetSeriesStatus(id)); |
709 | 709 |
710 int i; | 710 int i; |
711 if (db_->GetMetadataAsInteger(i, id, MetadataType_Series_ExpectedNumberOfInstances)) | 711 if (db_->GetMetadataAsInteger(i, id, MetadataType_Series_ExpectedNumberOfInstances)) |
712 result["ExpectedNumberOfInstances"] = i; | 712 result["ExpectedNumberOfInstances"] = i; |
713 else | 713 else |