Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- def SupplierGetRoute = path("supplier" / IntNumber) { (supId) =>
- get {
- respondWithMediaType(`application/json`) {
- onComplete((modules.suppliersDAA ? GetSupplierById(supId)).mapTo[Future[Seq[Supplier]]]) {
- case Success(s) => complete(s)
- case Failure(ex) => complete(InternalServerError, s"An error occurred: ${ex.getMessage}")
- }
- }
- }}
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement