Class WarehousingConsignmentsController

    • Constructor Detail

      • WarehousingConsignmentsController

        public WarehousingConsignmentsController()
    • Method Detail

      • getConsignments

        @Secured({"ROLE_WAREHOUSEAGENTGROUP","ROLE_WAREHOUSEMANAGERGROUP","ROLE_WAREHOUSEADMINISTRATORGROUP"})
        @RequestMapping(method=GET)
        @ResponseBody
        public ConsignmentSearchPageWsDto getConsignments​(@RequestParam(required=false,defaultValue="DEFAULT")
                                                          java.lang.String fields,
                                                          @RequestParam(required=false,defaultValue="0")
                                                          int currentPage,
                                                          @RequestParam(required=false,defaultValue="10")
                                                          int pageSize,
                                                          @RequestParam(required=false,defaultValue="asc")
                                                          java.lang.String sort)
        Request to get all ConsignmentModel in the system
        Parameters:
        fields - defaulted to DEFAULT but can be FULL or BASIC
        currentPage - number of the current page
        pageSize - number of items in a page
        sort - sorting the results ascending or descending
        Returns:
        list of ConsignmentModel
      • getConsignmentForCode

        @Secured({"ROLE_WAREHOUSEAGENTGROUP","ROLE_WAREHOUSEMANAGERGROUP","ROLE_WAREHOUSEADMINISTRATORGROUP"})
        @RequestMapping(value="/{code}",
                        method=GET)
        @ResponseBody
        public ConsignmentWsDTO getConsignmentForCode​(@PathVariable
                                                      java.lang.String code,
                                                      @RequestParam(required=false,defaultValue="DEFAULT")
                                                      java.lang.String fields)
        Request to get ConsignmentModel for the given code
        Parameters:
        fields - defaulted to DEFAULT but can be FULL or BASIC
        code - code to get the required consignment
        Returns:
        ConsignmentModel details for the given code
      • getSourcingLocationsForConsignmentCode

        @Secured({"ROLE_WAREHOUSEAGENTGROUP","ROLE_WAREHOUSEMANAGERGROUP","ROLE_WAREHOUSEADMINISTRATORGROUP"})
        @RequestMapping(value="/{code}/sourcing-locations",
                        method=GET)
        @ResponseBody
        public WarehouseSearchPageWsDto getSourcingLocationsForConsignmentCode​(@PathVariable
                                                                               java.lang.String code,
                                                                               @RequestParam(required=false,defaultValue="DEFAULT")
                                                                               java.lang.String fields,
                                                                               @RequestParam(required=false,defaultValue="0")
                                                                               int currentPage,
                                                                               @RequestParam(required=false,defaultValue="10")
                                                                               int pageSize,
                                                                               @RequestParam(required=false,defaultValue="asc")
                                                                               java.lang.String sort)
        Request to get all sourcing locations for the given "code"
        Parameters:
        code - ConsignmentModel.CODE for the requested sourcing location
        fields - defaulted to DEFAULT but can be FULL or BASIC
        currentPage - number of the current page
        pageSize - number of items in a page
        sort - sorting the results ascending or descending
        Returns:
        list of locations compliant to the above conditions
      • getConsignmentsByStatus

        @Secured({"ROLE_WAREHOUSEAGENTGROUP","ROLE_WAREHOUSEMANAGERGROUP","ROLE_WAREHOUSEADMINISTRATORGROUP"})
        @RequestMapping(value="status/{consignmentStatuses}",
                        method=GET)
        @ResponseBody
        public ConsignmentSearchPageWsDto getConsignmentsByStatus​(@PathVariable
                                                                  java.lang.String consignmentStatuses,
                                                                  @RequestParam(required=false,defaultValue="DEFAULT")
                                                                  java.lang.String fields,
                                                                  @RequestParam(required=false,defaultValue="0")
                                                                  int currentPage,
                                                                  @RequestParam(required=false,defaultValue="10")
                                                                  int pageSize,
                                                                  @RequestParam(required=false,defaultValue="asc")
                                                                  java.lang.String sort)
                                                           throws WebserviceValidationException
        Request to get all ConsignmentModel with certain consignment status(es)
        Parameters:
        consignmentStatuses - a list of valid ConsignmentStatus separated by ","
        fields - defaulted to DEFAULT but can be FULL or BASIC
        currentPage - number of the current page
        pageSize - number of items in a page
        sort - sorting the results ascending or descending
        Returns:
        list of ConsignmentModel that complies with conditions above
        Throws:
        WebserviceValidationException - in case of passing a wrong ConsignmentStatus
      • getConsignmentStatuses

        @Secured({"ROLE_WAREHOUSEAGENTGROUP","ROLE_WAREHOUSEMANAGERGROUP","ROLE_WAREHOUSEADMINISTRATORGROUP"})
        @RequestMapping(value="/statuses",
                        method=GET)
        @ResponseBody
        public ConsignmentStatusListWsDTO getConsignmentStatuses()
        Request to get all ConsignmentStatus in the system
        Returns:
        list of ConsignmentStatus
      • getDeclineReasons

        @Secured({"ROLE_WAREHOUSEAGENTGROUP","ROLE_WAREHOUSEMANAGERGROUP","ROLE_WAREHOUSEADMINISTRATORGROUP"})
        @RequestMapping(value="/decline-reasons",
                        method=GET)
        @ResponseBody
        public DeclineReasonListWsDTO getDeclineReasons()
        Request to get all DeclineReason available in the system.
        Returns:
        list of DeclineReason
      • getConsignmentEntriesForConsignmentCode

        @Secured({"ROLE_WAREHOUSEAGENTGROUP","ROLE_WAREHOUSEMANAGERGROUP","ROLE_WAREHOUSEADMINISTRATORGROUP"})
        @RequestMapping(value="/{code}/entries",
                        method=GET)
        @ResponseBody
        public ConsignmentEntrySearchPageWsDto getConsignmentEntriesForConsignmentCode​(@PathVariable
                                                                                       java.lang.String code,
                                                                                       @RequestParam(required=false,defaultValue="DEFAULT")
                                                                                       java.lang.String fields,
                                                                                       @RequestParam(required=false,defaultValue="0")
                                                                                       int currentPage,
                                                                                       @RequestParam(required=false,defaultValue="10")
                                                                                       int pageSize,
                                                                                       @RequestParam(required=false,defaultValue="asc")
                                                                                       java.lang.String sort)
        Request to get all ConsignmentEntryModel for the given "code"
        Parameters:
        code - "code" for the requested consignment entries
        fields - defaulted to DEFAULT but can be FULL or BASIC
        currentPage - number of the current page
        pageSize - number of items in a page
        sort - sorting the results ascending or descending
        Returns:
        list of ConsignmentEntryModel fulfilling the above conditions
      • confirmShipConsignment

        @Secured({"ROLE_WAREHOUSEAGENTGROUP","ROLE_WAREHOUSEMANAGERGROUP","ROLE_WAREHOUSEADMINISTRATORGROUP"})
        @RequestMapping(value="{code}/confirm-shipping",
                        method=POST,
                        consumes={"application/xml","application/json"},
                        produces={"application/json","application/xml"})
        @ResponseStatus(OK)
        public void confirmShipConsignment​(@PathVariable
                                           java.lang.String code)
        Request to confirm ConsignmentModel's shipping
        Parameters:
        code - consignment's code for the requested consignment
      • confirmPickupConsignment

        @Secured({"ROLE_WAREHOUSEAGENTGROUP","ROLE_WAREHOUSEMANAGERGROUP","ROLE_WAREHOUSEADMINISTRATORGROUP"})
        @RequestMapping(value="{code}/confirm-pickup",
                        method=POST,
                        consumes={"application/xml","application/json"},
                        produces={"application/json","application/xml"})
        @ResponseStatus(OK)
        public void confirmPickupConsignment​(@PathVariable
                                             java.lang.String code)
        Request to confirm ConsignmentModel's pickup
        Parameters:
        code - ConsignmentModel.CODE for the requested consignment
      • isConsignmentConfirmable

        @Secured({"ROLE_WAREHOUSEAGENTGROUP","ROLE_WAREHOUSEMANAGERGROUP","ROLE_WAREHOUSEADMINISTRATORGROUP"})
        @RequestMapping(value="{code}/is-confirmable",
                        method=GET)
        @ResponseBody
        public java.lang.Boolean isConsignmentConfirmable​(@PathVariable
                                                          java.lang.String code)
        Request to check if ConsignmentModel can be confirmed
        Parameters:
        code - ConsignmentModel.CODE for the requested consignment
      • getPackagingInfo

        @Secured({"ROLE_WAREHOUSEAGENTGROUP","ROLE_WAREHOUSEMANAGERGROUP","ROLE_WAREHOUSEADMINISTRATORGROUP"})
        @RequestMapping(value="/{code}/packaging-info",
                        method=GET)
        @ResponseBody
        public PackagingInfoWsDTO getPackagingInfo​(@PathVariable @NotNull
                                                   @NotNull java.lang.String code)
        Request to get PackagingInfoWsDTO for the given ConsignmentModel.CODE
        Parameters:
        code - code of the consignment for which to get the packaging information
        Returns:
        the packaging information of the ConsignmentModel
      • updatePackagingInfo

        @Secured({"ROLE_WAREHOUSEAGENTGROUP","ROLE_WAREHOUSEMANAGERGROUP","ROLE_WAREHOUSEADMINISTRATORGROUP"})
        @RequestMapping(value="/{code}/packaging-info",
                        method=PUT,
                        produces={"application/json","application/xml"},
                        consumes={"application/json","application/xml"})
        @ResponseStatus(OK)
        @ResponseBody
        public ConsignmentWsDTO updatePackagingInfo​(@RequestBody
                                                    PackagingInfoWsDTO packagingInfo,
                                                    @PathVariable @NotNull
                                                    @NotNull java.lang.String code,
                                                    @RequestParam(required=false,defaultValue="DEFAULT")
                                                    java.lang.String fields)
        Request to update a ConsignmentModel with a new Packaging information.
        Parameters:
        packagingInfo - the PackagingInfoWsDTO to update the consignment with
        code - ConsignmentModel.CODE for which to update the packaging information
        fields - defaulted to DEFAULT but can be FULL or BASIC
        Returns:
        updated ConsignmentWsDTO
      • reallocateConsignment

        @Secured({"ROLE_WAREHOUSEAGENTGROUP","ROLE_WAREHOUSEMANAGERGROUP","ROLE_WAREHOUSEADMINISTRATORGROUP"})
        @RequestMapping(value="/{code}/reallocate",
                        method=POST,
                        produces={"application/json","application/xml"},
                        consumes={"application/json","application/xml"})
        @ResponseStatus(OK)
        @ResponseBody
        public void reallocateConsignment​(@RequestBody
                                          ConsignmentReallocationWsDTO consignmentReallocationWsDTO,
                                          @PathVariable @NotNull
                                          @NotNull java.lang.String code)
        Request to reallocate a ConsignmentModel to a new warehouse.
        Parameters:
        consignmentReallocationWsDTO - the dto containing entries to be reallocated
        code - ConsignmentModel.CODE to be reallocated
      • pickConsignment

        @Secured({"ROLE_WAREHOUSEAGENTGROUP","ROLE_WAREHOUSEMANAGERGROUP","ROLE_WAREHOUSEADMINISTRATORGROUP"})
        @RequestMapping(value="/{code}/pick",
                        method=POST,
                        produces="*/*")
        @ResponseStatus(OK)
        @ResponseBody
        public java.lang.String pickConsignment​(@PathVariable @NotNull
                                                @NotNull java.lang.String code,
                                                @RequestParam(required=false,defaultValue="true")
                                                boolean printSlip)
        Request to pick a ConsignmentModel and generate its Pick Slip
        Parameters:
        code - ConsignmentModel.CODE for the requested consignment
        printSlip - Flag for backwards compatibility. Used to check if the pick slip will be generated
        Returns:
        the optionally generated html Pick Slip template
      • consolidatedPickConsignments

        @Secured({"ROLE_WAREHOUSEAGENTGROUP","ROLE_WAREHOUSEMANAGERGROUP","ROLE_WAREHOUSEADMINISTRATORGROUP"})
        @RequestMapping(value="/consolidated-pick",
                        method=POST,
                        produces="*/*",
                        consumes={"application/json","application/xml"})
        @ResponseStatus(OK)
        @ResponseBody
        public java.lang.String consolidatedPickConsignments​(@RequestBody
                                                             ConsignmentCodesWsDTO consignmentCodes)
        Request to pick, if applicable, each ConsignmentModel for the provided list of consignment codes and generate a consolidated pick slip.
        Parameters:
        consignmentCodes - a list of consignment codes
        Returns:
        the generated html Consolidated Pick Slip template
      • packConsignment

        @Secured({"ROLE_WAREHOUSEAGENTGROUP","ROLE_WAREHOUSEMANAGERGROUP","ROLE_WAREHOUSEADMINISTRATORGROUP"})
        @RequestMapping(value="/{code}/pack",
                        method=POST,
                        produces="*/*")
        @ResponseStatus(OK)
        @ResponseBody
        public java.lang.String packConsignment​(@PathVariable @NotNull
                                                @NotNull java.lang.String code,
                                                @RequestParam(required=false,defaultValue="true")
                                                boolean printSlip)
        Request to pack a ConsignmentModel and optionally generate its Pack Label
        Parameters:
        code - ConsignmentModel.CODE for the request consignment
        printSlip - Flag for backwards compatibility. Used to check if the pack label will be generated
        Returns:
        the optionally generated html Pack Label template
      • getExportForm

        @Secured({"ROLE_WAREHOUSEAGENTGROUP","ROLE_WAREHOUSEMANAGERGROUP","ROLE_WAREHOUSEADMINISTRATORGROUP"})
        @RequestMapping(value="/{code}/export-form",
                        method=GET,
                        produces="*/*")
        @ResponseBody
        public java.lang.String getExportForm​(@PathVariable @NotNull
                                              @NotNull java.lang.String code)
        Request to get the export form of a ConsignmentModel
        Parameters:
        code - ConsignmentModel.CODE for the request consignment
        Returns:
        the generated html Export Form template
      • getShippingLabel

        @Secured({"ROLE_WAREHOUSEAGENTGROUP","ROLE_WAREHOUSEMANAGERGROUP","ROLE_WAREHOUSEADMINISTRATORGROUP"})
        @RequestMapping(value="/{code}/shipping-label",
                        method=GET,
                        produces="*/*")
        @ResponseBody
        public java.lang.String getShippingLabel​(@PathVariable @NotNull
                                                 @NotNull java.lang.String code)
        Request to get the shipping label of a ConsignmentModel
        Parameters:
        code - ConsignmentModel.CODE for the request consignment
        Returns:
        the generated html Shipping Label template
      • getReturnShippingLabel

        @Secured({"ROLE_WAREHOUSEAGENTGROUP","ROLE_WAREHOUSEMANAGERGROUP","ROLE_WAREHOUSEADMINISTRATORGROUP"})
        @RequestMapping(value="/{code}/return-shipping-label",
                        method=GET,
                        produces="*/*")
        @ResponseBody
        public java.lang.String getReturnShippingLabel​(@PathVariable @NotNull
                                                       @NotNull java.lang.String code)
        Request to get the return shipping label of a Consignment
        Parameters:
        code - consignment's code for the request consignment
        Returns:
        the generated html Return Shipping Label template
      • getReturnForm

        @Secured({"ROLE_WAREHOUSEAGENTGROUP","ROLE_WAREHOUSEMANAGERGROUP","ROLE_WAREHOUSEADMINISTRATORGROUP"})
        @RequestMapping(value="/{code}/return-form",
                        method=GET,
                        produces="*/*")
        @ResponseBody
        public java.lang.String getReturnForm​(@PathVariable @NotNull
                                              @NotNull java.lang.String code)
        Request to get the return form of a ConsignmentModel
        Parameters:
        code - ConsignmentModel.CODE for the request consignment
        Returns:
        the generated html Return Form template
      • takePayment

        @Secured({"ROLE_WAREHOUSEAGENTGROUP","ROLE_WAREHOUSEMANAGERGROUP","ROLE_WAREHOUSEADMINISTRATORGROUP"})
        @RequestMapping(value="/{code}/take-payment",
                        method=POST,
                        produces={"application/json","application/xml"},
                        consumes={"application/json","application/xml"})
        @ResponseStatus(OK)
        @ResponseBody
        public PaymentTransactionEntryWsDTO takePayment​(@PathVariable @NotNull
                                                        @NotNull java.lang.String code,
                                                        @RequestParam(required=false,defaultValue="DEFAULT")
                                                        java.lang.String fields)
        Request to take a payment for a ConsignmentModel
        Parameters:
        code - ConsignmentModel.CODE for the request consignment
        Returns:
        the PaymentTransactionEntryWsDTO
      • manuallyReleasePaymentCapture

        @Secured({"ROLE_WAREHOUSEAGENTGROUP","ROLE_WAREHOUSEMANAGERGROUP","ROLE_WAREHOUSEADMINISTRATORGROUP"})
        @RequestMapping(value="/{code}/manual/capture-payment",
                        method=POST,
                        produces={"application/json","application/xml"},
                        consumes={"application/json","application/xml"})
        @ResponseStatus(OK)
        public void manuallyReleasePaymentCapture​(@PathVariable @NotNull
                                                  @NotNull java.lang.String code)
        Request to manually release ConsignmentModel from the waiting step after the payment capture has failed
        Parameters:
        code - ConsignmentModel.CODE for the request consignment
      • manuallyReleaseTaxCommit

        @Secured({"ROLE_WAREHOUSEAGENTGROUP","ROLE_WAREHOUSEMANAGERGROUP","ROLE_WAREHOUSEADMINISTRATORGROUP"})
        @RequestMapping(value="/{code}/manual/commit-tax",
                        method=POST,
                        produces={"application/json","application/xml"},
                        consumes={"application/json","application/xml"})
        @ResponseStatus(OK)
        public void manuallyReleaseTaxCommit​(@PathVariable @NotNull
                                             @NotNull java.lang.String code)
        Request to manully release ConsignmentModel from the waiting step after a tax commit failure
        Parameters:
        code - ConsignmentModel.CODE for the requested consignment
      • getPackagingInfoDTOValidator

        protected org.springframework.validation.Validator getPackagingInfoDTOValidator()
      • setPackagingInfoDTOValidator

        public void setPackagingInfoDTOValidator​(org.springframework.validation.Validator packagingInfoDTOValidator)
      • getConsignmentReallocationValidator

        protected org.springframework.validation.Validator getConsignmentReallocationValidator()
      • setConsignmentReallocationDTOValidator

        public void setConsignmentReallocationDTOValidator​(org.springframework.validation.Validator consignmentReallocationValidator)