diff options
author | Kseniya Tomskikh <ktomskih@datamonsters.co> | 2017-10-19 14:53:56 +0700 |
---|---|---|
committer | Kseniya Tomskikh <ktomskih@datamonsters.co> | 2017-10-20 12:56:12 +0700 |
commit | f3afdc358e52e2399bb4b089d26e3e3521570872 (patch) | |
tree | e15ff07004b72e3fa2a4b6c8bec9ed2808631c6d /src/main/scala/xyz/driver/pdsuidomain/fakes/entities/recordprocessing.scala | |
parent | 61d03bffcb6000268bb600d5336fb490056837f9 (diff) | |
download | rest-query-f3afdc358e52e2399bb4b089d26e3e3521570872.tar.gz rest-query-f3afdc358e52e2399bb4b089d26e3e3521570872.tar.bz2 rest-query-f3afdc358e52e2399bb4b089d26e3e3521570872.zip |
Review fixes
Diffstat (limited to 'src/main/scala/xyz/driver/pdsuidomain/fakes/entities/recordprocessing.scala')
-rw-r--r-- | src/main/scala/xyz/driver/pdsuidomain/fakes/entities/recordprocessing.scala | 40 |
1 files changed, 38 insertions, 2 deletions
diff --git a/src/main/scala/xyz/driver/pdsuidomain/fakes/entities/recordprocessing.scala b/src/main/scala/xyz/driver/pdsuidomain/fakes/entities/recordprocessing.scala index d2a648c..c0c3391 100644 --- a/src/main/scala/xyz/driver/pdsuidomain/fakes/entities/recordprocessing.scala +++ b/src/main/scala/xyz/driver/pdsuidomain/fakes/entities/recordprocessing.scala @@ -6,6 +6,7 @@ import xyz.driver.core.generators import xyz.driver.core.generators._ import xyz.driver.entities.labels.{Label, LabelCategory, LabelValue} import xyz.driver.pdsuicommon.domain.{LongId, TextJson, User} +import xyz.driver.pdsuidomain.ListResponse import xyz.driver.pdsuidomain.entities.ExtractedData.Meta import xyz.driver.pdsuidomain.entities._ import xyz.driver.pdsuidomain.fakes.entities.common._ @@ -186,12 +187,12 @@ object recordprocessing { ) } - def nextDocumentIssue(documentId: LongId[Document] = nextLongId): DocumentIssue = { + def nextDocumentIssue(): DocumentIssue = { val (startPage, endPage) = nextStartAndEndPagesOption DocumentIssue( id = nextLongId[DocumentIssue], userId = nextStringId[User], - documentId = documentId, + documentId = nextLongId[Document], startPage = startPage, endPage = endPage, lastUpdate = nextLocalDateTime, @@ -281,4 +282,39 @@ object recordprocessing { ) } + def nextMedicalRecordListResponse(): ListResponse[MedicalRecord] = { + val xs: Seq[MedicalRecord] = Seq.fill(3)(nextMedicalRecord()) + nextListResponse(xs) + } + + def nextMedicalRecordIssueListResponse(): ListResponse[MedicalRecordIssue] = { + val xs: Seq[MedicalRecordIssue] = Seq.fill(3)(nextMedicalRecordIssue()) + nextListResponse(xs) + } + + def nextMedicalRecordHistoryListResponse(): ListResponse[MedicalRecordHistory] = { + val xs: Seq[MedicalRecordHistory] = Seq.fill(3)(nextMedicalRecordHistory()) + nextListResponse(xs) + } + + def nextDocumentListResponse(): ListResponse[Document] = { + val xs: Seq[Document] = Seq.fill(3)(nextDocument()) + nextListResponse(xs) + } + + def nextDocumentIssueListResponse(): ListResponse[DocumentIssue] = { + val xs: Seq[DocumentIssue] = Seq.fill(3)(nextDocumentIssue()) + nextListResponse(xs) + } + + def nextDocumentHistoryListResponse(): ListResponse[DocumentHistory] = { + val xs: Seq[DocumentHistory] = Seq.fill(3)(nextDocumentHistory()) + nextListResponse(xs) + } + + def nextRichExtractedDataListResponse(): ListResponse[RichExtractedData] = { + val xs: Seq[RichExtractedData] = Seq.fill(3)(nextRichExtractedData()) + nextListResponse(xs) + } + } |