From e22a94604d6090d88801ec52c39f4eab500e80e1 Mon Sep 17 00:00:00 2001 From: Jakob Odersky Date: Mon, 24 Jul 2017 16:24:12 -0700 Subject: Implement ReP rest services --- .../pdsuidomain/formats/json/document/ApiProviderType.scala | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) (limited to 'src/main/scala/xyz/driver/pdsuidomain/formats/json/document/ApiProviderType.scala') diff --git a/src/main/scala/xyz/driver/pdsuidomain/formats/json/document/ApiProviderType.scala b/src/main/scala/xyz/driver/pdsuidomain/formats/json/document/ApiProviderType.scala index eb0ac46..c0eddad 100644 --- a/src/main/scala/xyz/driver/pdsuidomain/formats/json/document/ApiProviderType.scala +++ b/src/main/scala/xyz/driver/pdsuidomain/formats/json/document/ApiProviderType.scala @@ -2,9 +2,17 @@ package xyz.driver.pdsuidomain.formats.json.document import play.api.libs.functional.syntax._ import play.api.libs.json.{Format, JsPath} +import xyz.driver.pdsuicommon.domain.LongId import xyz.driver.pdsuidomain.entities.ProviderType -final case class ApiProviderType(id: Long, name: String) +final case class ApiProviderType(id: Long, name: String) { + + def toDomain = ProviderType( + id = LongId(this.id), + name = this.name + ) + +} object ApiProviderType { -- cgit v1.2.3