From 73b8563cc8914e7dd261fc8cae6454f085573a4c Mon Sep 17 00:00:00 2001 From: nttdata-rtorsoli Date: Tue, 12 Dec 2023 10:38:08 +0100 Subject: [PATCH] PIN-4292 Recovered previous scenario --- src/main/resources/interface-specification.yml | 2 -- .../catalogmanagement/api/impl/EServiceApiServiceImpl.scala | 5 +---- .../pagopa/interop/catalogmanagement/api/impl/package.scala | 2 +- 3 files changed, 2 insertions(+), 7 deletions(-) diff --git a/src/main/resources/interface-specification.yml b/src/main/resources/interface-specification.yml index b36b186..486d419 100644 --- a/src/main/resources/interface-specification.yml +++ b/src/main/resources/interface-specification.yml @@ -1262,8 +1262,6 @@ components: properties: prettyName: type: string - checksum: # Temporarily required for feature PIN-4267, to be removed - type: string CreateEServiceDescriptorDocumentSeed: required: - documentId diff --git a/src/main/scala/it/pagopa/interop/catalogmanagement/api/impl/EServiceApiServiceImpl.scala b/src/main/scala/it/pagopa/interop/catalogmanagement/api/impl/EServiceApiServiceImpl.scala index 5208dd6..8d66d1a 100644 --- a/src/main/scala/it/pagopa/interop/catalogmanagement/api/impl/EServiceApiServiceImpl.scala +++ b/src/main/scala/it/pagopa/interop/catalogmanagement/api/impl/EServiceApiServiceImpl.scala @@ -473,10 +473,7 @@ class EServiceApiServiceImpl( eService <- retrieveCatalogItem(eServiceId) descriptor <- getDescriptor(eService, descriptorId).toFuture document <- extractDocument(eService, descriptorId, documentId).toFuture - updatedDocument = document.copy( - prettyName = updateEServiceDescriptorDocumentSeed.prettyName, - checksum = updateEServiceDescriptorDocumentSeed.checksum.getOrElse(document.checksum) - ) + updatedDocument = document.copy(prettyName = updateEServiceDescriptorDocumentSeed.prettyName) result <- askWithResult( eServiceId, ref => diff --git a/src/main/scala/it/pagopa/interop/catalogmanagement/api/impl/package.scala b/src/main/scala/it/pagopa/interop/catalogmanagement/api/impl/package.scala index f9f1a18..e0ee246 100644 --- a/src/main/scala/it/pagopa/interop/catalogmanagement/api/impl/package.scala +++ b/src/main/scala/it/pagopa/interop/catalogmanagement/api/impl/package.scala @@ -30,7 +30,7 @@ package object impl extends SprayJsonSupport with DefaultJsonProtocol { implicit val problemErrorFormat: RootJsonFormat[ProblemError] = jsonFormat2(ProblemError) implicit val problemFormat: RootJsonFormat[Problem] = jsonFormat6(Problem) implicit val updateEserviceDescriptorDocumentSeed: RootJsonFormat[UpdateEServiceDescriptorDocumentSeed] = - jsonFormat2(UpdateEServiceDescriptorDocumentSeed) + jsonFormat1(UpdateEServiceDescriptorDocumentSeed) implicit val createEserviceDescriptorDocumentSeed: RootJsonFormat[CreateEServiceDescriptorDocumentSeed] = jsonFormat8(CreateEServiceDescriptorDocumentSeed)