RemoteShipmentPreferenceService.java 1.28 KB
package com.huaheng.config.api;

import com.huaheng.common.core.config.FeignTokenInterceptor;
import com.huaheng.common.core.constant.ServiceNameConstants;
import com.huaheng.config.api.domain.ShipmentPreference;
import com.huaheng.config.api.domain.StatusFlowDetail;
import com.huaheng.config.api.factory.RemoteReceiptTypeFallbackFactory;
import com.huaheng.config.api.factory.RemoteShipmentPreferenceFallFactory;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestParam;

@FeignClient(contextId = "RemoteShipmentPreferenceService", value = ServiceNameConstants.CONFIG_SERVICE,
        fallbackFactory = RemoteShipmentPreferenceFallFactory.class, configuration = FeignTokenInterceptor.class)
public interface RemoteShipmentPreferenceService {

    @GetMapping("/config/shipmentPreference/checkShipmentProcess")
    StatusFlowDetail checkShipmentProcess(@RequestParam(value = "ids") String ids,
                                          @RequestParam(value = "status") Integer status,
                                          @RequestParam(value = "code") String code);

    @GetMapping("/shipmentPreference/getByCode")
    ShipmentPreference getByCode(@RequestParam("code") String code);
}