Class ApplicationsRestController

java.lang.Object
es.kukenan.smartfi.microservice.backoffice.controller.ApplicationsRestController

@RestController public class ApplicationsRestController extends Object
Applications Rest API controller.
  • Field Summary

    Fields
    Modifier and Type
    Field
    Description
    static final String
    Advance application update list of id state path.
    static final String
    New Credit/Advance Application path.
    static final String
    Authority (role) required in order to be able to invoke greeting API.
    static final String
    Authority (role) required in order to be able to invoke change application status.
    static final String
    Base path for backoffice Rest API.
    static final String
    Change Application status path.
    static final String
    New Credit/Advance Application path.
    static final String
    Application detail path.
    static final String
    Application detail path.
    static final String
    Application generate contract path.
    static final String
    Application upload payment proof path.
    static final String
    Application upload signed contract path.
    static final String
    Application path.
    static final String
    Credit application update list of id state path.
    private es.kukenan.smartfi.common.service.jwt.JwtServiceImpl
    JWT service for create a bearer to call products.
    private es.kukenan.smartfi.common.context.RequestContextManager
    Request context manager.
    private UserService
    Users service.
  • Constructor Summary

    Constructors
    Constructor
    Description
     
  • Method Summary

    Modifier and Type
    Method
    Description
    org.springframework.http.ResponseEntity<es.kukenan.smartfi.dto.ResponseDTO<List<es.kukenan.smartfi.microservice.backoffice.dtos.core.contract.Contract>>>
    changeAdvanceToPaymentReturn(es.kukenan.smartfi.microservice.backoffice.dtos.core.contract.UpdateListOfContractsRequestDto updateListOfContractsRequestDto, es.kukenan.smartfi.common.security.WalletAuthentication authentication)
    Change a list of application identifier from APPROVED_PAYMENT_PENDING_NAME (advance) to PAYED (advance).
    org.springframework.http.ResponseEntity<es.kukenan.smartfi.dto.ResponseDTO<List<es.kukenan.smartfi.microservice.backoffice.dtos.core.contract.Contract>>>
    changeCreditsToActive(es.kukenan.smartfi.microservice.backoffice.dtos.core.contract.UpdateListOfContractsRequestDto updateListOfContractsRequestDto, es.kukenan.smartfi.common.security.WalletAuthentication authentication)
    Change a list of application identifier from PAYMENT_PENDING (credit) to ACTIVE (credit).
    org.springframework.http.ResponseEntity<es.kukenan.smartfi.dto.ResponseDTO<es.kukenan.smartfi.microservice.backoffice.dtos.core.contract.CountInfoDto>>
    countApplications(es.kukenan.smartfi.common.security.WalletAuthentication authentication)
    Application count.
    void
    downloadContractDocument(es.kukenan.smartfi.common.security.WalletAuthentication authentication, String contractDocumentId, javax.servlet.http.HttpServletResponse response)
    Download document.
    void
    downloadGeneratedContractDocument(es.kukenan.smartfi.common.security.WalletAuthentication authentication, String applicationId, javax.servlet.http.HttpServletResponse response)
    Download generated contract pdf document.
    org.springframework.http.ResponseEntity<Object>
    findAllApplications(Integer pageNumber, Integer pageSize, String sortedBy, es.kukenan.smartfi.microservice.backoffice.dtos.core.contract.GetApplicationsRequestDto getApplicationsRequestDto, es.kukenan.smartfi.common.security.WalletAuthentication authentication)
    Application list endpoint.
    org.springframework.http.ResponseEntity<es.kukenan.smartfi.dto.ResponseDTO<es.kukenan.smartfi.microservice.backoffice.dtos.core.contract.Contract>>
    findApplicationDetail(String applicationId, es.kukenan.smartfi.common.security.WalletAuthentication authentication)
    Application detail endpoint.
    org.springframework.http.ResponseEntity<es.kukenan.smartfi.dto.ResponseDTO<es.kukenan.smartfi.microservice.backoffice.dtos.core.contract.Contract>>
    saveApplication(es.kukenan.smartfi.common.security.WalletAuthentication authentication, es.kukenan.smartfi.microservice.backoffice.dtos.backoffice.NewUserAndApplicationRequestDto newApplicationRequestDto, String userIp, String userAgent)
    Create new Application.
    org.springframework.http.ResponseEntity<es.kukenan.smartfi.dto.ResponseDTO<es.kukenan.smartfi.microservice.backoffice.dtos.core.contract.Contract>>
    updateContractDocumentStatus(es.kukenan.smartfi.common.security.WalletAuthentication authentication, String contractDocumentId, es.kukenan.smartfi.microservice.backoffice.dtos.core.contract.UpdateContractDocumentRequestDto updateContractDocumentRequestDto)
    Change application document status.
    org.springframework.http.ResponseEntity<es.kukenan.smartfi.dto.ResponseDTO<es.kukenan.smartfi.microservice.backoffice.dtos.core.contract.Contract>>
    updateContractStatus(es.kukenan.smartfi.common.security.WalletAuthentication authentication, String contractId, es.kukenan.smartfi.microservice.backoffice.dtos.core.contract.ContractStatusRequestDto contractStatusRequestDto)
    Change application status.
    org.springframework.http.ResponseEntity<es.kukenan.smartfi.dto.ResponseDTO<es.kukenan.smartfi.microservice.backoffice.dtos.core.contract.Contract>>
    uploadContractDocument(es.kukenan.smartfi.common.security.WalletAuthentication authentication, String contractDocumentId, org.springframework.web.multipart.MultipartFile file)
    Save specific contract document file.
    org.springframework.http.ResponseEntity<es.kukenan.smartfi.dto.ResponseDTO<es.kukenan.smartfi.microservice.backoffice.dtos.core.contract.Contract>>
    uploadFiles(es.kukenan.smartfi.common.security.WalletAuthentication authentication, String userId, String contractId, List<org.springframework.web.multipart.MultipartFile> files)
    Upload files.
    org.springframework.http.ResponseEntity<es.kukenan.smartfi.dto.ResponseDTO<es.kukenan.smartfi.microservice.backoffice.dtos.core.contract.Contract>>
    uploadPaymentProofFile(String applicationId, org.springframework.web.multipart.MultipartFile file, es.kukenan.smartfi.common.security.WalletAuthentication authentication)
    Change application from PAYMENT_PENDING (credit) or APPROVED_PAYMENT_PENDING_NAME (advance) to PAYED (advance) or ACTIVE (credit).
    org.springframework.http.ResponseEntity<es.kukenan.smartfi.dto.ResponseDTO<es.kukenan.smartfi.microservice.backoffice.dtos.core.contract.Contract>>
    uploadSignedContractFile(String applicationId, org.springframework.web.multipart.MultipartFile file, es.kukenan.smartfi.common.security.WalletAuthentication authentication)
    Change application from PENDING_SIGNATURE (credit) or APPROVED (advance) to PAYMENT_PENDING (credit) and APPROVED_PAYMENT_PENDING (advance).

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Field Details

    • API_BASE_PATH

      public static final String API_BASE_PATH
      Base path for backoffice Rest API.
      See Also:
    • APPLICATIONS_PATH

      public static final String APPLICATIONS_PATH
      Application path.
      See Also:
    • APPLICATION_DETAIL_PATH

      public static final String APPLICATION_DETAIL_PATH
      Application detail path.
      See Also:
    • API_APPLICATION_PATH

      public static final String API_APPLICATION_PATH
      New Credit/Advance Application path.
      See Also:
    • API_UPLOAD_FILES_APPLICATION_PATH

      public static final String API_UPLOAD_FILES_APPLICATION_PATH
      New Credit/Advance Application path.
      See Also:
    • API_CHANGE_APPLICATION_STATUS_PATH

      public static final String API_CHANGE_APPLICATION_STATUS_PATH
      Change Application status path.
      See Also:
    • APPLICATION_CHANGE_DOCUMENT_STATUS_PATH

      public static final String APPLICATION_CHANGE_DOCUMENT_STATUS_PATH
      Application detail path.
      See Also:
    • APPLICATION_UPLOAD_SIGNED_CONTRACT_PATH

      public static final String APPLICATION_UPLOAD_SIGNED_CONTRACT_PATH
      Application upload signed contract path.
      See Also:
    • APPLICATION_UPLOAD_PAYMENT_PROOF_PATH

      public static final String APPLICATION_UPLOAD_PAYMENT_PROOF_PATH
      Application upload payment proof path.
      See Also:
    • APPLICATION_GENERATE_CONTRACT_PATH

      public static final String APPLICATION_GENERATE_CONTRACT_PATH
      Application generate contract path.
      See Also:
    • ADVANCE_APPLICATION_LIST_SET_PAYED

      public static final String ADVANCE_APPLICATION_LIST_SET_PAYED
      Advance application update list of id state path.
      See Also:
    • CREDIT_APPLICATION_LIST_SET_PAYED

      public static final String CREDIT_APPLICATION_LIST_SET_PAYED
      Credit application update list of id state path.
      See Also:
    • jwtService

      @Autowired private es.kukenan.smartfi.common.service.jwt.JwtServiceImpl jwtService
      JWT service for create a bearer to call products.
    • userService

      @Autowired private UserService userService
      Users service.
    • requestContextManager

      @Autowired private es.kukenan.smartfi.common.context.RequestContextManager requestContextManager
      Request context manager.
    • API_AUTHORITIES

      public static final String API_AUTHORITIES
      Authority (role) required in order to be able to invoke greeting API.
      See Also:
    • API_BACKOFFICE_AUTHORITIES

      public static final String API_BACKOFFICE_AUTHORITIES
      Authority (role) required in order to be able to invoke change application status.
      See Also:
  • Constructor Details

    • ApplicationsRestController

      public ApplicationsRestController()
  • Method Details

    • countApplications

      @PreAuthorize("(hasRole(\'ROLE_ACCESS_ADMIN\') and hasRole(\'ROLE_LEVEL_BACKOFFICE_ADMIN\')) or (hasRole(\'ROLE_ACCESS_MODERATOR\') and hasRole(\'ROLE_LEVEL_USER_MODERATOR\')) or (hasRole(\'ROLE_ACCESS_CONSULTANT\') and hasRole(\'ROLE_LEVEL_USER_CONSULTANT\')) or (hasRole(\'ROLE_ACCESS_COMPANY\') and hasRole(\'ROLE_LEVEL_USER_COMPANY\'))") @GetMapping(produces="application/json", path="/api/v1/backoffice/applications") public org.springframework.http.ResponseEntity<es.kukenan.smartfi.dto.ResponseDTO<es.kukenan.smartfi.microservice.backoffice.dtos.core.contract.CountInfoDto>> countApplications(es.kukenan.smartfi.common.security.WalletAuthentication authentication)
      Application count.
      Parameters:
      authentication - user credentials.
      Returns:
      user list.
    • findAllApplications

      @PreAuthorize("(hasRole(\'ROLE_ACCESS_ADMIN\') and hasRole(\'ROLE_LEVEL_BACKOFFICE_ADMIN\')) or (hasRole(\'ROLE_ACCESS_MODERATOR\') and hasRole(\'ROLE_LEVEL_USER_MODERATOR\')) or (hasRole(\'ROLE_ACCESS_CONSULTANT\') and hasRole(\'ROLE_LEVEL_USER_CONSULTANT\')) or (hasRole(\'ROLE_ACCESS_COMPANY\') and hasRole(\'ROLE_LEVEL_USER_COMPANY\'))") @PostMapping(produces="application/json", consumes="application/json", path="/api/v1/backoffice/applications") public org.springframework.http.ResponseEntity<Object> findAllApplications(@RequestParam(name="pageNumber",required=false,defaultValue="0") Integer pageNumber, @RequestParam(name="pageSize",required=false,defaultValue="20") Integer pageSize, @RequestParam(name="sortedBy",required=false,defaultValue="") String sortedBy, @RequestBody es.kukenan.smartfi.microservice.backoffice.dtos.core.contract.GetApplicationsRequestDto getApplicationsRequestDto, es.kukenan.smartfi.common.security.WalletAuthentication authentication)
      Application list endpoint.
      Parameters:
      pageNumber - the page to search
      pageSize - max number of rows per page
      sortedBy - field to sort
      getApplicationsRequestDto - fields to filter
      authentication - user credentials.
      Returns:
      user list.
    • findApplicationDetail

      @PreAuthorize("(hasRole(\'ROLE_ACCESS_ADMIN\') and hasRole(\'ROLE_LEVEL_BACKOFFICE_ADMIN\')) or (hasRole(\'ROLE_ACCESS_MODERATOR\') and hasRole(\'ROLE_LEVEL_USER_MODERATOR\')) or (hasRole(\'ROLE_ACCESS_CONSULTANT\') and hasRole(\'ROLE_LEVEL_USER_CONSULTANT\')) or (hasRole(\'ROLE_ACCESS_COMPANY\') and hasRole(\'ROLE_LEVEL_USER_COMPANY\'))") @GetMapping(produces="application/json", path="/api/v1/backoffice/applications/{applicationId}") public org.springframework.http.ResponseEntity<es.kukenan.smartfi.dto.ResponseDTO<es.kukenan.smartfi.microservice.backoffice.dtos.core.contract.Contract>> findApplicationDetail(@PathVariable(name="applicationId") String applicationId, es.kukenan.smartfi.common.security.WalletAuthentication authentication)
      Application detail endpoint.
      Parameters:
      applicationId - application identifier.
      authentication - user credentials.
      Returns:
      user list.
    • saveApplication

      @PreAuthorize("(hasRole(\'ROLE_ACCESS_ADMIN\') and hasRole(\'ROLE_LEVEL_BACKOFFICE_ADMIN\')) or (hasRole(\'ROLE_ACCESS_MODERATOR\') and hasRole(\'ROLE_LEVEL_USER_MODERATOR\')) or (hasRole(\'ROLE_ACCESS_CONSULTANT\') and hasRole(\'ROLE_LEVEL_USER_CONSULTANT\')) or (hasRole(\'ROLE_ACCESS_COMPANY\') and hasRole(\'ROLE_LEVEL_USER_COMPANY\'))") @PostMapping(path="/api/v1/backoffice/application", consumes="application/json", produces="application/json") public org.springframework.http.ResponseEntity<es.kukenan.smartfi.dto.ResponseDTO<es.kukenan.smartfi.microservice.backoffice.dtos.core.contract.Contract>> saveApplication(es.kukenan.smartfi.common.security.WalletAuthentication authentication, @RequestBody es.kukenan.smartfi.microservice.backoffice.dtos.backoffice.NewUserAndApplicationRequestDto newApplicationRequestDto, @RequestHeader(name="X-SKYLINE-USER-IP",defaultValue="N/A") String userIp, @RequestHeader(name="X-USER-AGENT",defaultValue="N/A") String userAgent)
      Create new Application.
      Parameters:
      authentication - user credentials.
      newApplicationRequestDto - application data.
      userIp - user real ip
      userAgent - user-agent header
      Returns:
      the created contract.
    • uploadFiles

      @PreAuthorize("(hasRole(\'ROLE_ACCESS_ADMIN\') and hasRole(\'ROLE_LEVEL_BACKOFFICE_ADMIN\')) or (hasRole(\'ROLE_ACCESS_MODERATOR\') and hasRole(\'ROLE_LEVEL_USER_MODERATOR\')) or (hasRole(\'ROLE_ACCESS_CONSULTANT\') and hasRole(\'ROLE_LEVEL_USER_CONSULTANT\')) or (hasRole(\'ROLE_ACCESS_COMPANY\') and hasRole(\'ROLE_LEVEL_USER_COMPANY\'))") @PostMapping(path="/api/v1/backoffice/application/{userId}/{contractId}/upload-files", consumes="multipart/form-data", produces="application/json") public org.springframework.http.ResponseEntity<es.kukenan.smartfi.dto.ResponseDTO<es.kukenan.smartfi.microservice.backoffice.dtos.core.contract.Contract>> uploadFiles(es.kukenan.smartfi.common.security.WalletAuthentication authentication, @PathVariable(name="userId") String userId, @PathVariable(name="contractId") String contractId, @RequestPart("file") List<org.springframework.web.multipart.MultipartFile> files)
      Upload files.
      Parameters:
      authentication - user credentials.
      userId - user identifier.
      contractId - application identifier.
      files - list of files received.
      Returns:
      upload files response.
    • updateContractStatus

      @PreAuthorize("(hasRole(\'ROLE_ACCESS_ADMIN\') and hasRole(\'ROLE_LEVEL_BACKOFFICE_ADMIN\')) or (hasRole(\'ROLE_ACCESS_MODERATOR\') and hasRole(\'ROLE_LEVEL_USER_MODERATOR\'))") @PutMapping(path="/api/v1/backoffice/applications/{applicationId}/status", consumes="application/json", produces="application/json") public org.springframework.http.ResponseEntity<es.kukenan.smartfi.dto.ResponseDTO<es.kukenan.smartfi.microservice.backoffice.dtos.core.contract.Contract>> updateContractStatus(es.kukenan.smartfi.common.security.WalletAuthentication authentication, @PathVariable(name="applicationId") String contractId, @RequestBody es.kukenan.smartfi.microservice.backoffice.dtos.core.contract.ContractStatusRequestDto contractStatusRequestDto)
      Change application status.
      Parameters:
      authentication - user credentials.
      contractId - contract id.
      contractStatusRequestDto - list of files received.
      Returns:
      ok.
    • updateContractDocumentStatus

      @PreAuthorize("(hasRole(\'ROLE_ACCESS_ADMIN\') and hasRole(\'ROLE_LEVEL_BACKOFFICE_ADMIN\')) or (hasRole(\'ROLE_ACCESS_MODERATOR\') and hasRole(\'ROLE_LEVEL_USER_MODERATOR\'))") @PutMapping(path="/api/v1/backoffice/applications/documents/{contractDocumentId}", consumes="application/json", produces="application/json") public org.springframework.http.ResponseEntity<es.kukenan.smartfi.dto.ResponseDTO<es.kukenan.smartfi.microservice.backoffice.dtos.core.contract.Contract>> updateContractDocumentStatus(es.kukenan.smartfi.common.security.WalletAuthentication authentication, @PathVariable(name="contractDocumentId") String contractDocumentId, @RequestBody es.kukenan.smartfi.microservice.backoffice.dtos.core.contract.UpdateContractDocumentRequestDto updateContractDocumentRequestDto)
      Change application document status.
      Parameters:
      authentication - user credentials.
      contractDocumentId - contract document id.
      updateContractDocumentRequestDto - update application document data.
      Returns:
      ok.
    • downloadContractDocument

      @PreAuthorize("(hasRole(\'ROLE_ACCESS_ADMIN\') and hasRole(\'ROLE_LEVEL_BACKOFFICE_ADMIN\')) or (hasRole(\'ROLE_ACCESS_MODERATOR\') and hasRole(\'ROLE_LEVEL_USER_MODERATOR\'))") @GetMapping(path="/api/v1/backoffice/applications/documents/{contractDocumentId}", produces="application/octet-stream") public void downloadContractDocument(es.kukenan.smartfi.common.security.WalletAuthentication authentication, @PathVariable(name="contractDocumentId") String contractDocumentId, javax.servlet.http.HttpServletResponse response) throws IOException
      Download document.
      Parameters:
      authentication - user credentials.
      contractDocumentId - contract document id.
      response - response.
      Throws:
      IOException - file to write response.
    • uploadContractDocument

      @PreAuthorize("(hasRole(\'ROLE_ACCESS_ADMIN\') and hasRole(\'ROLE_LEVEL_BACKOFFICE_ADMIN\')) or (hasRole(\'ROLE_ACCESS_MODERATOR\') and hasRole(\'ROLE_LEVEL_USER_MODERATOR\'))") @PostMapping(path="/api/v1/backoffice/applications/documents/{contractDocumentId}", consumes="multipart/form-data") public org.springframework.http.ResponseEntity<es.kukenan.smartfi.dto.ResponseDTO<es.kukenan.smartfi.microservice.backoffice.dtos.core.contract.Contract>> uploadContractDocument(es.kukenan.smartfi.common.security.WalletAuthentication authentication, @PathVariable(name="contractDocumentId") String contractDocumentId, @RequestPart("file") org.springframework.web.multipart.MultipartFile file)
      Save specific contract document file.
      Parameters:
      authentication - user credentials.
      contractDocumentId - contract document id.
      file - file received.
      Returns:
      contract updated.
    • uploadSignedContractFile

      @PreAuthorize("(hasRole(\'ROLE_ACCESS_ADMIN\') and hasRole(\'ROLE_LEVEL_BACKOFFICE_ADMIN\')) or (hasRole(\'ROLE_ACCESS_MODERATOR\') and hasRole(\'ROLE_LEVEL_USER_MODERATOR\'))") @PutMapping(path="/api/v1/backoffice/application/sign-contract/{applicationId}", produces="application/json") public org.springframework.http.ResponseEntity<es.kukenan.smartfi.dto.ResponseDTO<es.kukenan.smartfi.microservice.backoffice.dtos.core.contract.Contract>> uploadSignedContractFile(@PathVariable(name="applicationId") String applicationId, @RequestPart("file") org.springframework.web.multipart.MultipartFile file, es.kukenan.smartfi.common.security.WalletAuthentication authentication)
      Change application from PENDING_SIGNATURE (credit) or APPROVED (advance) to PAYMENT_PENDING (credit) and APPROVED_PAYMENT_PENDING (advance).
      Parameters:
      applicationId - application identifier.
      file - file received.
      authentication - user credentials.
      Returns:
      user list.
    • uploadPaymentProofFile

      @PreAuthorize("(hasRole(\'ROLE_ACCESS_ADMIN\') and hasRole(\'ROLE_LEVEL_BACKOFFICE_ADMIN\')) or (hasRole(\'ROLE_ACCESS_MODERATOR\') and hasRole(\'ROLE_LEVEL_USER_MODERATOR\'))") @PutMapping(path="/api/v1/backoffice/application/payment-proof/{applicationId}", produces="application/json") public org.springframework.http.ResponseEntity<es.kukenan.smartfi.dto.ResponseDTO<es.kukenan.smartfi.microservice.backoffice.dtos.core.contract.Contract>> uploadPaymentProofFile(@PathVariable(name="applicationId") String applicationId, @RequestPart("file") org.springframework.web.multipart.MultipartFile file, es.kukenan.smartfi.common.security.WalletAuthentication authentication)
      Change application from PAYMENT_PENDING (credit) or APPROVED_PAYMENT_PENDING_NAME (advance) to PAYED (advance) or ACTIVE (credit).
      Parameters:
      applicationId - application identifier.
      file - file received.
      authentication - user credentials.
      Returns:
      user list.
    • downloadGeneratedContractDocument

      @PreAuthorize("(hasRole(\'ROLE_ACCESS_ADMIN\') and hasRole(\'ROLE_LEVEL_BACKOFFICE_ADMIN\')) or (hasRole(\'ROLE_ACCESS_MODERATOR\') and hasRole(\'ROLE_LEVEL_USER_MODERATOR\'))") @GetMapping(path="/api/v1/backoffice/application/generate-contract/{applicationId}", produces="application/octet-stream") public void downloadGeneratedContractDocument(es.kukenan.smartfi.common.security.WalletAuthentication authentication, @PathVariable(name="applicationId") String applicationId, javax.servlet.http.HttpServletResponse response) throws IOException
      Download generated contract pdf document.
      Parameters:
      authentication - user credentials.
      applicationId - application identifier.
      response - response.
      Throws:
      IOException - file to write response.
    • changeAdvanceToPaymentReturn

      @PreAuthorize("(hasRole(\'ROLE_ACCESS_ADMIN\') and hasRole(\'ROLE_LEVEL_BACKOFFICE_ADMIN\')) or (hasRole(\'ROLE_ACCESS_MODERATOR\') and hasRole(\'ROLE_LEVEL_USER_MODERATOR\'))") @PutMapping(path="/api/v1/backoffice/application/advance/set-payment-return", produces="application/json") public org.springframework.http.ResponseEntity<es.kukenan.smartfi.dto.ResponseDTO<List<es.kukenan.smartfi.microservice.backoffice.dtos.core.contract.Contract>>> changeAdvanceToPaymentReturn(@RequestBody es.kukenan.smartfi.microservice.backoffice.dtos.core.contract.UpdateListOfContractsRequestDto updateListOfContractsRequestDto, es.kukenan.smartfi.common.security.WalletAuthentication authentication)
      Change a list of application identifier from APPROVED_PAYMENT_PENDING_NAME (advance) to PAYED (advance).
      Parameters:
      updateListOfContractsRequestDto - contract id list.
      authentication - user credentials.
      Returns:
      ok.
    • changeCreditsToActive

      @PreAuthorize("(hasRole(\'ROLE_ACCESS_ADMIN\') and hasRole(\'ROLE_LEVEL_BACKOFFICE_ADMIN\')) or (hasRole(\'ROLE_ACCESS_MODERATOR\') and hasRole(\'ROLE_LEVEL_USER_MODERATOR\'))") @PutMapping(path="/api/v1/backoffice/application/credit/set-active", produces="application/json") public org.springframework.http.ResponseEntity<es.kukenan.smartfi.dto.ResponseDTO<List<es.kukenan.smartfi.microservice.backoffice.dtos.core.contract.Contract>>> changeCreditsToActive(@RequestBody es.kukenan.smartfi.microservice.backoffice.dtos.core.contract.UpdateListOfContractsRequestDto updateListOfContractsRequestDto, es.kukenan.smartfi.common.security.WalletAuthentication authentication)
      Change a list of application identifier from PAYMENT_PENDING (credit) to ACTIVE (credit).
      Parameters:
      updateListOfContractsRequestDto - contract id list.
      authentication - user credentials.
      Returns:
      user list.